Chess* Chess::createChess(std::string name, char type, int x, int y,char cname) { auto chess = new Chess(); chess->initChess( name,type, x, y,cname); chess->autorelease(); return chess; }
bool T2::init(){ if(!CCLayer::init()) return false; setTouchEnabled(true); node_array = CCArray::create(); node_array->retain(); initChess(0,15); setupView(); return true; }