commit de5a9bc9e01da6213ab1e07baa8936f4494dc9d8 Author: 欧志刚 Date: Mon Apr 7 17:00:28 2014 +0800 init diff --git a/Classes/AppDelegate.cpp b/Classes/AppDelegate.cpp new file mode 100755 index 0000000..09db5e1 --- /dev/null +++ b/Classes/AppDelegate.cpp @@ -0,0 +1,102 @@ +#include "cocos2d.h" +#include "CCEGLView.h" +#include "AppDelegate.h" +#include "CCLuaEngine.h" +#include "SimpleAudioEngine.h" +#include "Lua_extensions_CCB.h" +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS || CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID || CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) +#include "Lua_web_socket.h" +#endif + +#include "OzgFileUtility.h" +#include "RPGStartSceneLayer.h" + +using namespace CocosDenshion; + +USING_NS_CC; + +AppDelegate::AppDelegate() +{ +} + +AppDelegate::~AppDelegate() +{ + SimpleAudioEngine::end(); +} + +bool AppDelegate::applicationDidFinishLaunching() +{ + // initialize director + CCDirector *pDirector = CCDirector::sharedDirector(); + pDirector->setOpenGLView(CCEGLView::sharedOpenGLView()); + + CCEGLView::sharedOpenGLView()->setDesignResolutionSize(1024, 768, kResolutionShowAll); + + // turn on display FPS + pDirector->setDisplayStats(false); + + // set FPS. the default value is 1.0/60 if you don't call this + pDirector->setAnimationInterval(1.0 / 60); + + // register lua engine +// CCLuaEngine* pEngine = CCLuaEngine::defaultEngine(); +// CCScriptEngineManager::sharedManager()->setScriptEngine(pEngine); +// +// CCLuaStack *pStack = pEngine->getLuaStack(); +// lua_State *tolua_s = pStack->getLuaState(); +// tolua_extensions_ccb_open(tolua_s); +//#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS || CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID || CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) +// pStack = pEngine->getLuaStack(); +// tolua_s = pStack->getLuaState(); +// tolua_web_socket_open(tolua_s); +//#endif +// +//#if (CC_TARGET_PLATFORM == CC_PLATFORM_BLACKBERRY) +// CCFileUtils::sharedFileUtils()->addSearchPath("script"); +//#endif +// +// std::string path = CCFileUtils::sharedFileUtils()->fullPathForFilename("hello.lua"); +// pEngine->executeScriptFile(path.c_str()); + + //将数据库复制到可写目录 + string dbSrc = CCFileUtils::sharedFileUtils()->fullPathForFilename(GAME_SYS_DB); + string dbDes = CCFileUtils::sharedFileUtils()->getWritablePath(); + dbDes.append(GAME_SYS_DB); + + if(!OzgFileUtility::fileExists(dbDes)) + OzgFileUtility::copyFile(dbSrc.c_str(), dbDes.c_str()); + CCLog("%s", dbDes.c_str()); + + //记录检查,如果没有记录则生成 + CppSQLite3DB db; + db.open(dbDes.c_str()); + + CppSQLite3Query query = db.execQuery("select count(id) from save_data"); +// CCLog("%i", query.getIntField(0)); + if(query.getIntField(0) == 0) + db.execDML(GAME_INIT_SQL); + + query.finalize(); + db.close(); + + CCScene *mainScene = RPGStartSceneLayer::scene(); + pDirector->runWithScene(mainScene); + + return true; +} + +// This function will be called when the app is inactive. When comes a phone call,it's be invoked too +void AppDelegate::applicationDidEnterBackground() +{ + CCDirector::sharedDirector()->stopAnimation(); + + SimpleAudioEngine::sharedEngine()->pauseBackgroundMusic(); +} + +// this function will be called when the app is active again +void AppDelegate::applicationWillEnterForeground() +{ + CCDirector::sharedDirector()->startAnimation(); + + SimpleAudioEngine::sharedEngine()->resumeBackgroundMusic(); +} diff --git a/Classes/AppDelegate.h b/Classes/AppDelegate.h new file mode 100755 index 0000000..bcbd54a --- /dev/null +++ b/Classes/AppDelegate.h @@ -0,0 +1,38 @@ +#ifndef __APP_DELEGATE_H__ +#define __APP_DELEGATE_H__ + +#include "cocos2d.h" + +/** +@brief The cocos2d Application. + +The reason for implement as private inheritance is to hide some interface call by CCDirector. +*/ +class AppDelegate : private cocos2d::CCApplication +{ +public: + AppDelegate(); + virtual ~AppDelegate(); + + /** + @brief Implement CCDirector and CCScene init code here. + @return true Initialize success, app continue. + @return false Initialize failed, app terminate. + */ + virtual bool applicationDidFinishLaunching(); + + /** + @brief The function be called when the application enter background + @param the pointer of the application + */ + virtual void applicationDidEnterBackground(); + + /** + @brief The function be called when the application enter foreground + @param the pointer of the application + */ + virtual void applicationWillEnterForeground(); +}; + +#endif // __APP_DELEGATE_H__ + diff --git a/Classes/GameCfg.h b/Classes/GameCfg.h new file mode 100755 index 0000000..bf069d9 --- /dev/null +++ b/Classes/GameCfg.h @@ -0,0 +1,21 @@ +// +// GameCfg.h +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#ifndef OzgGameRPG_GameCfg_h +#define OzgGameRPG_GameCfg_h + +#define GAME_SYS_DB "db.sys" //系统数据库 +#define GAME_SCENE 0.5 //场景切换的时间 + +#define GAME_TMX_ROLE_WIDTH 32.0 +#define GAME_TMX_ROLE_HEIGHT 32.0 +#define GAME_PLAYER_MOVESPEED 0.5 + +#define GAME_INIT_SQL "insert into save_data (map_id, player_to_x, player_to_y, player_direction, items) values(1, 14.5, 9.5, 'down', '[]');" + +#endif diff --git a/Classes/OzgCCScrollBgNode.cpp b/Classes/OzgCCScrollBgNode.cpp new file mode 100755 index 0000000..f22c7ad --- /dev/null +++ b/Classes/OzgCCScrollBgNode.cpp @@ -0,0 +1,59 @@ + +#include "OzgCCScrollBgNode.h" + +#define SCROLL_SPEED -1.0f //滚动速度,负数为向左,正数为向右 + +OzgCCScrollBgNode::~OzgCCScrollBgNode() +{ + this->unscheduleUpdate(); + this->m_bgSprite1->removeFromParentAndCleanup(true); + this->m_bgSprite2->removeFromParentAndCleanup(true); + CCTextureCache::sharedTextureCache()->removeTextureForKey(this->m_bg.c_str()); + +} + +bool OzgCCScrollBgNode::init(const char* bg) +{ + if(CCNode::init()) + { + this->m_bg = string(bg); + this->m_bgSprite1 = CCSprite::create(this->m_bg.c_str()); + this->m_bgSprite1->setAnchorPoint(CCPointZero); + this->m_bgSprite1->setPosition(CCPointZero); + this->addChild(this->m_bgSprite1); + + this->m_bgSprite2 = CCSprite::create(this->m_bg.c_str()); + this->m_bgSprite2->setAnchorPoint(CCPointZero); + this->m_bgSprite2->setPosition(ccp(this->m_bgSprite1->getContentSize().width, 0)); + this->addChild(this->m_bgSprite2); + + this->scheduleUpdate(); + return true; + } + return false; +} + +OzgCCScrollBgNode* OzgCCScrollBgNode::create(const char *bg) +{ + OzgCCScrollBgNode *obj = new OzgCCScrollBgNode(); + if(obj && obj->init(bg)) + { + obj->autorelease(); + return obj; + } + + CC_SAFE_DELETE(obj); + return NULL; +} + +void OzgCCScrollBgNode::update(float delta) +{ + this->m_bgSprite1->setPositionX(this->m_bgSprite1->getPositionX() + SCROLL_SPEED); + this->m_bgSprite2->setPositionX(this->m_bgSprite2->getPositionX() + SCROLL_SPEED); + + if(this->m_bgSprite1->getPositionX() <= -this->m_bgSprite1->getContentSize().width) + this->m_bgSprite1->setPosition(ccp(this->m_bgSprite1->getContentSize().width, 0)); + else if(this->m_bgSprite2->getPositionX() <= -this->m_bgSprite2->getContentSize().width) + this->m_bgSprite2->setPosition(ccp(this->m_bgSprite2->getContentSize().width, 0)); + +} diff --git a/Classes/OzgCCScrollBgNode.h b/Classes/OzgCCScrollBgNode.h new file mode 100755 index 0000000..84b22ee --- /dev/null +++ b/Classes/OzgCCScrollBgNode.h @@ -0,0 +1,29 @@ + +//滚动背景 +//目前之支持左右滚动 + +#ifndef __ozgcc2dxutils__OzgCCScrollBgNode__ +#define __ozgcc2dxutils__OzgCCScrollBgNode__ + +#include "cocos2d.h" +#include + +USING_NS_CC; +using namespace std; + +class OzgCCScrollBgNode : public CCNode +{ +private: + CCSprite* m_bgSprite1; + CCSprite* m_bgSprite2; + string m_bg; + +public: + virtual ~OzgCCScrollBgNode(); + bool init(const char* bg); + static OzgCCScrollBgNode* create(const char* bg); + void update(float delta); + +}; + +#endif /* defined(__ozgcc2dxutils__OzgCCScrollBgNode__) */ diff --git a/Classes/OzgCCUtility.cpp b/Classes/OzgCCUtility.cpp new file mode 100755 index 0000000..f5d3223 --- /dev/null +++ b/Classes/OzgCCUtility.cpp @@ -0,0 +1,503 @@ + +#include "OzgCCUtility.h" + +void OzgCCUtility::ccDrawSolidCircle(const CCPoint& center, float radius, unsigned int segments, ccColor4F color) +{ + const float coef = 2.0f * (float)M_PI / segments; + CCPoint *vertices = (CCPoint*)calloc(segments + 1, sizeof(CCPoint)); + + for(unsigned int i = 0;i <= segments; i++) + { + float rads = i * coef; + GLfloat j = radius * cosf(rads) + center.x; + GLfloat k = radius * sinf(rads) + center.y; + vertices[i].x = j; + vertices[i].y = k; + } + ccDrawSolidPoly(vertices, segments, color); + free(vertices); +} + +void OzgCCUtility::clearAnimate(const char *plist) +{ + CCDictionary *root = CCDictionary::createWithContentsOfFile(plist); + CCArray *frames = (CCArray*)root->objectForKey("frames"); + CCObject *item = NULL; + CCARRAY_FOREACH(frames, item) + { + CCString *itemStr = (CCString*)item; + + CCTextureCache::sharedTextureCache()->removeTextureForKey(itemStr->getCString()); + } +} + +CCActionInterval* OzgCCUtility::createAnimate(const char *plist) +{ + //plist的根节点为Root(CCDictionary) + //plist的结构为frames(CCArray),loop(Number),delay(Number),rect(CCDictionary)里面有x(Number),y(Number),width(Number),height(Number) + + //loop为循环次数,-1为无限次 + //delay为每帧的时间间隔 + //rect帧的范围,一般为0, 0, 图片宽, 图片高 + //frames帧的路径 + + CCArray *spriteFrames = CCArray::create(); + + CCDictionary *root = CCDictionary::createWithContentsOfFile(plist); + + unsigned int loops = ((CCString*)root->objectForKey("loop"))->intValue(); + float delay = ((CCString*)root->objectForKey("delay"))->floatValue(); + CCArray *frames = (CCArray*)root->objectForKey("frames"); + CCDictionary *rectDict = (CCDictionary*)root->objectForKey("rect"); + float rectX = ((CCString*)rectDict->objectForKey("x"))->floatValue(); + float rectY = ((CCString*)rectDict->objectForKey("y"))->floatValue(); + float rectWidth = ((CCString*)rectDict->objectForKey("width"))->floatValue(); + float rectHeight = ((CCString*)rectDict->objectForKey("height"))->floatValue(); + CCRect rect = CCRectMake(rectX, rectY, rectWidth, rectHeight); + + CCObject *item = NULL; + CCARRAY_FOREACH(frames, item) + { + CCString *itemStr = (CCString*)item; + + CCSpriteFrame *spriteFrame = CCSpriteFrame::create(itemStr->getCString(), rect); + spriteFrames->addObject(spriteFrame); + } + + CCAnimation *animation = CCAnimation::createWithSpriteFrames(spriteFrames, delay); + CCAnimate *animate = CCAnimate::create(animation); + + if(loops) + return CCRepeatForever::create(animate); + else + return animate; + +} + +void OzgCCUtility::plistPosition(cocos2d::CCNode *node, const char *plist) +{ + CCDictionary *root = CCDictionary::createWithContentsOfFile(plist); + float positionX = ((CCString*)root->objectForKey("position_x"))->floatValue(); + float positionY = ((CCString*)root->objectForKey("position_y"))->floatValue(); + node->setAnchorPoint(CCPointZero); //强制使用0锚点 + node->setPosition(ccp(positionX, positionY)); + +} + +unsigned int OzgCCUtility::rangeRand(unsigned int min, unsigned int max) +{ +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) + unsigned int x = abs((rand() * time(NULL) % (max - min))); + x += min; + return x; +#else + unsigned int x = abs((int)((random() * time(NULL) % (max - min)))); + x += min; + return x; +#endif +} + +void OzgCCUtility::randomSeed(int seed) +{ + if(!seed) + OzgCCUtilsRandomSeed = time(NULL); + else + OzgCCUtilsRandomSeed = seed; +} + +float OzgCCUtility::randomFloat(float min, float max) +{ + OzgCCUtilsRandomSeed = 214013 * OzgCCUtilsRandomSeed + 2531011; + return min + (OzgCCUtilsRandomSeed >> 16) * (1.0f / 65535.0f) * (max - min); +} + +int OzgCCUtility::atoi(const char *src) +{ + char flag = 0; + int sum = 0; + int i = 0; + int len = (int)strlen(src); + + /*参数的正确性*/ + if(NULL == src) + { + return 0; + } + + /*是否存在符号问题*/ + if(src[i] == '-') + { + flag = '-'; + ++i; + } + + for( ; i < len; ++i) + { + /*判断字符是否合法*/ + if(src[i] < 48 && src[i] > 57) + return 0; + + /*数据求和,注意数值的转换问题src[i] - 48*/ + sum = sum * 10 + src[i] - 48; + } + + /*根据标志位实现返回正确的正负数*/ + if(flag == '-') + return -sum; + else + return sum; +} + +char* OzgCCUtility::itoa(int num, char *str) +{ + //char flag = 0; + int i = 0, count = 0, j = 0; + + /*参数检测*/ + if(NULL == str) + { + return NULL; + } + + /*判断数值的正负,设置对应的符号*/ + if(num < 0) + { + str[i++] = '-'; + + /************************ + 同时要对数值取绝对值 + 保证后面取余整除操作正常 + *************************/ + num = -num; + } + + while(num / 10) + { + /*************************** + count用来保存实际的数字个数, + 便于后期的顺序调换 + ****************************/ + ++count; + /*实际保存的顺序为反序列*/ + str[i++] = num % 10 + 48; + num /= 10; + } + /*判断是*/ + if(num % 10) + { + str[i++] = num %10 + 48; + ++count; + } + /*字符串结束符*/ + str[i] = 0; + + /*实现数据的较好操作*/ + i = 0; + if(str[0] == '-') + { + i = 1; + } + /*实际交换的下标区间为i~j*/ + j = count + i - 1; + + for(; i < j ; ++i, --j) + { + /*数据的较好操作*/ + str[i] = str[i] + str[j]; + str[j] = str[i] - str[j]; + str[i] = str[i] - str[j]; + } + + /*返回实际的字符串*/ + return str; +} + +char* OzgCCUtility::formatTime(const char *format) +{ + return OzgCCUtility::formatTime(format, time(NULL)); +} + +char* OzgCCUtility::formatTime(const char *format, time_t utc_time) +{ + static char str_time[128]; + struct tm *local_time = NULL; + + utc_time = time (NULL); + local_time = localtime(&utc_time); + strftime(str_time, sizeof(str_time), format, local_time); + + return str_time; +} + +char* OzgCCUtility::base64Encode(const char* data, int data_len) +{ + //int data_len = strlen(data); + int prepare = 0; + int ret_len; + int temp = 0; + char *ret = NULL; + char *f = NULL; + int tmp = 0; + char changed[4]; + int i = 0; + ret_len = data_len / 3; + temp = data_len % 3; + if (temp > 0) + { + ret_len += 1; + } + ret_len = ret_len * 4 + 1; + ret = (char *)malloc(ret_len); + + if ( ret == NULL) + { + printf("No enough memory.\n"); + exit(0); + } + memset(ret, 0, ret_len); + f = ret; + while (tmp < data_len) + { + temp = 0; + prepare = 0; + memset(changed, '\0', 4); + while (temp < 3) + { + //printf("tmp = %d\n", tmp); + if (tmp >= data_len) + { + break; + } + prepare = ((prepare << 8) | (data[tmp] & 0xFF)); + tmp++; + temp++; + } + prepare = (prepare << ((3 - temp) * 8)); + //printf("before for : temp = %d, prepare = %d\n", temp, prepare); + for (i = 0; i < 4 ;i++ ) + { + if (temp < i) + { + changed[i] = 0x40; + } + else + { + changed[i] = (prepare>>((3-i)*6)) & 0x3F; + } + *f = OZG_BASE64[changed[i]]; + //printf("%.2X", changed[i]); + f++; + } + } + *f = '\0'; + + return ret; + +} + +char OzgCCUtility::base64FindPos(char ch) +{ + char *ptr = (char*)strrchr(OZG_BASE64, ch);//the last position (the only) in base[] + return (ptr - OZG_BASE64); +} + +char* OzgCCUtility::base64Decode(const char *data, int data_len) +{ + int ret_len = (data_len / 4) * 3; + int equal_count = 0; + char *ret = NULL; + char *f = NULL; + int tmp = 0; + int temp = 0; + char need[3]; + int prepare = 0; + int i = 0; + if (*(data + data_len - 1) == '=') + { + equal_count += 1; + } + if (*(data + data_len - 2) == '=') + { + equal_count += 1; + } + if (*(data + data_len - 3) == '=') + {//seems impossible + equal_count += 1; + } + switch (equal_count) + { + case 0: + ret_len += 4;//3 + 1 [1 for NULL] + break; + case 1: + ret_len += 4;//Ceil((6*3)/8)+1 + break; + case 2: + ret_len += 3;//Ceil((6*2)/8)+1 + break; + case 3: + ret_len += 2;//Ceil((6*1)/8)+1 + break; + } + ret = (char *)malloc(ret_len); + if (ret == NULL) + { + printf("No enough memory.\n"); + exit(0); + } + memset(ret, 0, ret_len); + f = ret; + while (tmp < (data_len - equal_count)) + { + temp = 0; + prepare = 0; + memset(need, 0, 4); + while (temp < 4) + { + if (tmp >= (data_len - equal_count)) + { + break; + } + prepare = (prepare << 6) | (OzgCCUtility::base64FindPos(data[tmp])); + temp++; + tmp++; + } + prepare = prepare << ((4 - temp) * 6); + for (i = 0; i < 3 ;i++ ) + { + if (i == temp) + { + break; + } + *f = (char)((prepare>>((2 - i) * 8)) & 0xFF); + f++; + } + } + *f = '\0'; + return ret; +} + +float OzgCCUtility::roundf(float num) +{ + float num1 = num - floorf(num); + float num2 = ceilf(num) - num; + + if (num1 > num2) + return ceilf(num); + else + return floorf(num); +} + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) +//windows的乱码解决方案 + +//字符转换,使cocos2d-x在win32平台支持中文显示 +int OzgCCUtility::GBKToUTF8(string &gbkStr, const char* toCode, const char* formCode) +{ + iconv_t iconvH; + iconvH = iconv_open(formCode, toCode); + if(iconvH == 0) + { + return -1; + } + + const char* strChar = gbkStr.c_str(); + const char** pin = &strChar; + + size_t strLength = gbkStr.length(); + char* outbuf = (char*)malloc(strLength * 4); + char* pBuff = outbuf; + memset(outbuf, 0, strLength * 4); + size_t outLength = strLength * 4; + if(-1 == iconv(iconvH, pin, &strLength, &outbuf, &outLength)) + { + iconv_close(iconvH); + return -1; + } + + gbkStr = pBuff; + iconv_close(iconvH); + return 0; +} +#endif + +string OzgCCUtility::generalString(std::string &str) +{ +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) + OzgCCUtility::GBKToUTF8(str, "gbk", "utf-8"); //后面两个参数就默认了,免得后面再传参麻烦 + return str; +#else + return str; +#endif + +} + +string OzgCCUtility::generalString(const char* str) +{ + std::string s(str); + return OzgCCUtility::generalString(s); +} + +CCActionInterval* OzgCCUtility::createAnimate(cocos2d::CCTexture2D *texture, int xNum, int yNum, vector frameIndces, float delay, bool loops) +{ + CCArray *frames = OzgCCUtility::createSpriteFrames(texture, xNum, yNum); + + CCArray *useFrames = CCArray::create(); + for (int i = 0; i < (int)frameIndces.size(); i++) + useFrames->addObject(frames->objectAtIndex(frameIndces[i])); + + CCAnimation *animation = CCAnimation::createWithSpriteFrames(useFrames, delay); + animation->setLoops(loops); + CCAnimate *animate = CCAnimate::create(animation); + + if(loops) + return CCRepeatForever::create(animate); + else + return animate; +} + +CCActionInterval* OzgCCUtility::createAnimate(const char *fileimage, int xNum, int yNum, vector frameIndces, float delay, bool loops) +{ + CCArray *frames = OzgCCUtility::createSpriteFrames(fileimage, xNum, yNum); + + CCArray *useFrames = CCArray::create(); + + for (int i = 0; i < (int)frameIndces.size(); i++) + useFrames->addObject(frames->objectAtIndex(frameIndces[i])); + + CCAnimation *animation = CCAnimation::createWithSpriteFrames(useFrames, delay); + CCAnimate *animate = CCAnimate::create(animation); + + if(loops) + return CCRepeatForever::create(animate); + else + return animate; +} + +CCArray* OzgCCUtility::createSpriteFrames(cocos2d::CCTexture2D *texture, int xNum, int yNum) +{ + CCArray *frames = CCArray::create(); + + float itemWidth = texture->getContentSizeInPixels().width / (float)xNum; + float itemHeight = texture->getContentSizeInPixels().height / (float)yNum; + + for (int i = 0; i < yNum; i++) + { + for (int j = 0; j < xNum; j++) + { +// CCLog("%f %f %f %f", (float)j * itemWidth, (float)i * itemHeight, itemWidth, itemHeight); + + CCSpriteFrame *s = CCSpriteFrame::createWithTexture(texture, CCRectMake((float)j * itemWidth, (float)i * itemHeight, itemWidth, itemHeight)); + frames->addObject(s); + + } + + } + + return frames; +} + +CCArray* OzgCCUtility::createSpriteFrames(const char *fileimage, int xNum, int yNum) +{ + return OzgCCUtility::createSpriteFrames(CCTextureCache::sharedTextureCache()->addImage(fileimage), xNum, yNum); +} diff --git a/Classes/OzgCCUtility.h b/Classes/OzgCCUtility.h new file mode 100755 index 0000000..4172d77 --- /dev/null +++ b/Classes/OzgCCUtility.h @@ -0,0 +1,99 @@ + +#ifndef __ozgcc2dxutils__OzgCCUtility__ +#define __ozgcc2dxutils__OzgCCUtility__ + +#include "cocos2d.h" + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) +//(注意:对工程右键-> 属性 -> 连接器 -> 输入 -> 附加依赖项 栏目->后面有个按钮,点击打开,换一行加入libiconv.lib,或者在最后空一格加上libiconv.lib也行) +#include "iconv\iconv.h" +#endif + +#define OZG_BASE64 "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=" + +USING_NS_CC; +using namespace std; + +static unsigned int OzgCCUtilsRandomSeed = 0; + +//string转数字类型 +/* + string str("00801"); + cout << stringToNumber(str) << endl; + */ +template +Type stringToNumber(const string& str) +{ + istringstream iss(str); + Type num; + iss >> num; + return num; +} + +class OzgCCUtility +{ + +public: + + //draw实心圆,参数为:中心点,半径,线段数(越大锯齿就越少),颜色 + static void ccDrawSolidCircle(const CCPoint& center, float radius, unsigned int segments, ccColor4F color); + + static void clearAnimate(const char *plist); //清空plist生成的帧动画 + static CCActionInterval* createAnimate(const char *plist); //利用plist生成帧动画,plist结构在实现文件里面 + + static void plistPosition(CCNode *node, const char *plist); //使用plist来定位 + + static unsigned int rangeRand(unsigned int min, unsigned int max); //范围随机数 + + //随机例子,第一次调用randomFloat的值都是一样的,所以第一次的值可以忽略 +// OzgCCUtils::randomSeed(0); +// for (int i = 0; i < 10; i++) +// { +// CCLog("%f, %f", OzgCCUtils::randomFloat(0.0f, 3.0f), OzgCCUtils::randomFloat(0.0f, 3.0f)); +// sleep(1); +// } + static void randomSeed(int seed); + static float randomFloat(float min, float max); //范围随机float + + static int atoi(const char *src); //atoi的加强版,字符转整数 + static char* itoa(int num, char *str); //整数转字符 + static char* formatTime(const char* format); //返回格式化的时间,参数1 demos:"%Y-%m-%d %H:%M:%S" + static char* formatTime(const char* format, time_t utc_time); + + /* + base64 demo + + const char *t = "this is ozg demo"; + int j = strlen(t); + char *enc = OzgCCUtils::base64Encode(t, j); + int len = strlen(enc); + char *dec = OzgCCUtils::base64Decode(enc, len); + printf("\noriginal: %s\n", t); + printf("\nencoded : %s\n", enc); + printf("\ndecoded : %s\n", dec); + free(enc); + free(dec); + + */ + static char *base64Encode(const char* data, int data_len); + static char base64FindPos(char ch); + static char *base64Decode(const char *data, int data_len); + + static float roundf(float num); //四舍五入到整数 + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) + //windows的乱码解决方案 + static int GBKToUTF8(string &gbkStr,const char* toCode,const char* formCode); +#endif + static string generalString(string &str); //通用的乱码解决方案 + static string generalString(const char* str); + + static CCActionInterval* createAnimate(CCTexture2D* texture, int xNum, int yNum, vector frameIndces, float delay, bool loops); + static CCActionInterval* createAnimate(const char* fileimage, int xNum, int yNum, vector frameIndces, float delay, bool loops); + static CCArray* createSpriteFrames(CCTexture2D* texture, int xNum, int yNum); + static CCArray* createSpriteFrames(const char* fileimage, int xNum, int yNum); + + +}; + +#endif /* defined(__ozgcc2dxutils__OzgCCUtility__) */ diff --git a/Classes/OzgFileUtility.cpp b/Classes/OzgFileUtility.cpp new file mode 100755 index 0000000..072593a --- /dev/null +++ b/Classes/OzgFileUtility.cpp @@ -0,0 +1,347 @@ + +#include "OzgFileUtility.h" + +//私有方法 + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) +//win32 or win8 or winrt +wstring OzgFileUtility::s2ws(const std::string& s) +{ + int len; + int slength = (int)s.length() + 1; + len = MultiByteToWideChar(CP_ACP, 0, s.c_str(), slength, 0, 0); + wchar_t* buf = new wchar_t[len]; + MultiByteToWideChar(CP_ACP, 0, s.c_str(), slength, buf, len); + std::wstring r(buf); + delete[] buf; + return r; +} +#endif + +bool OzgFileUtility::isSpecialDir(const char *path) +{ + return strcmp(path, ".") == 0 || strcmp(path, "..") == 0; +} + +void OzgFileUtility::getFilePath(const char *path, const char *fileName, char *filePath) +{ + strcpy(filePath, path); + if(filePath[strlen(path) - 1] != '/') + strcat(filePath, "/"); + strcat(filePath, fileName); +} + +//获取路径下的所有文件夹和文件 +vector OzgFileUtility::getFoldersAndFile(const string &path, bool showAbsolutePath) +{ + vector items; + +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + + struct dirent* ent = NULL; + DIR* pDir; + pDir = opendir(path.c_str()); + while(NULL != (ent = readdir(pDir))) + { + string fullpath = path + "/" + ent->d_name; + if(strcmp(ent->d_name, ".") != 0 && strcmp(ent->d_name, "..") != 0) + { + string filePath; + + //绝对路径 + if(showAbsolutePath) + filePath.append(path); + + //所在目录的结尾是否有/ + if (path.c_str()[path.size() - 1] != '/') + filePath.append("/"); + + filePath.append(ent->d_name); + items.push_back(filePath); + } + } + closedir(pDir); +#else +//win32 or win8 or winrt + +#endif + + return items; +} + +//获取路径下的所有文件夹 +vector OzgFileUtility::getFolders(const string &path, bool showAbsolutePath) +{ + vector folders; + +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + struct dirent* ent = NULL; + DIR* pDir; + pDir = opendir(path.c_str()); + while(NULL != (ent = readdir(pDir))) + { + string fullpath = path + "/" + ent->d_name; + //if(4 == ent->d_type) //在nfs或xfs下,有的目录d_type也是0 + if(OzgFileUtility::isFolder(fullpath)) + { + if(strcmp(ent->d_name, ".") != 0 && strcmp(ent->d_name, "..") != 0) + { + string filePath; + + //绝对路径 + if(showAbsolutePath) + filePath.append(path); + + //所在目录的结尾是否有/ + if (path.c_str()[path.size() - 1] != '/') + filePath.append("/"); + + filePath.append(ent->d_name); + folders.push_back(filePath); + } + } + } + closedir(pDir); +#else +//win32 or win8 or winrt + +#endif + + return folders; +} + +//获取路径下的所有文件,可指定文件后缀名 +vector OzgFileUtility::getFiles(const string &path, bool showAbsolutePath, const string &postfix) +{ + vector files; + +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + struct dirent* ent = NULL; + DIR* pDir; + pDir = opendir(path.c_str()); + while(NULL != (ent = readdir(pDir))) + { + string fullpath = path + "/" + ent->d_name; + //if(8 == ent->d_type) //在nfs或xfs下,有的文件d_type也是0 + if(OzgFileUtility::isFile(fullpath)) + { + if(postfix == "" || strstr(ent->d_name, postfix.c_str())!=NULL) + { + string filePath; + + //绝对路径 + if(showAbsolutePath) + filePath.append(path); + + //所在目录的结尾是否有/ + if (path.c_str()[path.size() - 1] != '/') + filePath.append("/"); + + filePath.append(ent->d_name); + files.push_back(filePath); + } + } + } + closedir(pDir); +#else +//win32 or win8 or winrt + +#endif + + return files; +} + +//检查文件或目录是否准备好,一定程度上防止数据正在拷贝的时候去读写。 +//方法是检查文件或目录的access time是否在5分钟以前 +bool OzgFileUtility::isPrepared(const string &path) +{ + struct stat st; + stat(path.c_str(), &st); + return time(0) - st.st_ctime >= MAX_DUR; +} + +//判断是否为文件夹,用stat的标志来判断 +bool OzgFileUtility::isFolder(const string &path) +{ +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + struct stat st; + int ret = stat(path.c_str(), &st); + return ret >= 0 && S_ISDIR(st.st_mode); +#else + + return false; +#endif + +} + +//判断是否为文件,用stat的标志来判断 +bool OzgFileUtility::isFile(const string &path) +{ +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + struct stat st; + int ret = stat(path.c_str(), &st); + return ret >= 0 && S_ISREG(st.st_mode); +#else + + return false; +#endif + +} + +//判断文件或文件夹是否存在 +bool OzgFileUtility::fileExists(const string &path) +{ + fstream fs; + fs.open(path.c_str(), ios::in); + if(!fs) + return false; + else + return true; + +} + +void OzgFileUtility::deleteFile(const string &path) +{ +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + DIR *dir; + dirent *dirInfo; + char filePath[PATH_MAX]; + if(OzgFileUtility::isFile(path)) + { + remove(path.c_str()); + return; + } + + if(OzgFileUtility::isFolder(path)) + { + if((dir = opendir(path.c_str())) == NULL) + return; + while((dirInfo = readdir(dir)) != NULL) + { + OzgFileUtility::getFilePath(path.c_str(), dirInfo->d_name, filePath); + if(OzgFileUtility::isSpecialDir(dirInfo->d_name)) + continue; + OzgFileUtility::deleteFile(filePath); + rmdir(filePath); + } + + rmdir(path.c_str()); + } +#else +//win32 or win8 or winrt + +#endif + +} + +bool OzgFileUtility::copyFile(const char *src, const char *des) +{ + FILE * fSrc = fopen(src, "rb"); + if(!fSrc) + { + printf("打开文件`%s`失败", src); + return false; + } + FILE * fDes = fopen(des, "wb"); + if(!fDes) + { + printf("创建文件`%s`失败", des); + return false; + } + + unsigned char * buf; + unsigned int length; + fseek(fSrc, 0, SEEK_END); + length = ftell(fSrc); + buf = new unsigned char[length+1]; + memset(buf, 0, length+1); + fseek(fSrc, 0, SEEK_SET); + fread(buf, length, 1, fSrc); + + fwrite(buf, length, 1, fDes); + + fclose(fSrc); + fclose(fDes); + delete [] buf; + return true; +} + +void OzgFileUtility::copyFolder(const char *src, const char *des) +{ + if(!OzgFileUtility::fileExists(src)) + { + cout << "源文件夹不存在" << endl; + return; + } + + if(OzgFileUtility::fileExists(des)) + //删除旧的版本 + OzgFileUtility::deleteFile(des); + + //建立空文件夹 +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + + mkdir(des, S_IRWXU); +#else + _wmkdir((wchar_t*)des); +#endif + + vector fileList = OzgFileUtility::getFoldersAndFile(src); + vector::iterator fileListIterator = fileList.begin(); + while (fileListIterator != fileList.end()) + { + string targetFileName = *fileListIterator; + targetFileName.replace(0, strlen(src), des); + + if(OzgFileUtility::isFolder(*fileListIterator)) + { +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux + //建立文件夹 + mkdir(targetFileName.c_str(), S_IRWXU); +#else + _wmkdir((wchar_t*)targetFileName.c_str()); +#endif + + vector fileList2 = OzgFileUtility::getFoldersAndFile(*fileListIterator); + vector::iterator fileListIterator2 = fileList2.begin(); + while (fileListIterator2 != fileList2.end()) + { + targetFileName = *fileListIterator2; + targetFileName.replace(0, strlen(src), des); + + if(OzgFileUtility::isFolder(*fileListIterator2)) + { + OzgFileUtility::copyFolder((*fileListIterator2).c_str(), targetFileName.c_str()); + //cout << *fileListIterator2 << endl; + } + else + { + //复制文件 + + OzgFileUtility::copyFile((*fileListIterator2).c_str(), targetFileName.c_str()); + //cout << targetFileName << endl; + } + + fileListIterator2++; + } + + } + else + { + //复制文件 + OzgFileUtility::copyFile((*fileListIterator).c_str(), targetFileName.c_str()); + //cout << targetFileName << endl; + } + + fileListIterator++; + } + +} diff --git a/Classes/OzgFileUtility.h b/Classes/OzgFileUtility.h new file mode 100755 index 0000000..b2ee446 --- /dev/null +++ b/Classes/OzgFileUtility.h @@ -0,0 +1,89 @@ + +/* +demo +vector files = OzgFileUtility::getFoldersAndFile("/"); +vector::iterator filesIterator = files.begin(); +while (filesIterator != files.end()) +{ +cout << *filesIterator << endl; +filesIterator++; +} +*/ + +#ifndef __ozgcc2dxutils__OzgFileUtility__ +#define __ozgcc2dxutils__OzgFileUtility__ + +#include "cocos2d.h" +#include +#include +#include +#include +#include +#include +#include +#include + +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) +//mac or ios or android or linux +#include +#else +//win32 or win8 or winrt +#include +#endif + +using namespace std; + +const int MAX_DUR = 5 * 60; + +class OzgFileUtility +{ + +private: + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN8) || (CC_TARGET_PLATFORM == CC_PLATFORM_WINRT) + static wstring OzgFileUtility::s2ws(const std::string& s); +#endif + + //判断是否是特殊目录 + static bool isSpecialDir(const char *path); + + //生成完整的文件路径 + static void getFilePath(const char *path, const char *fileName, char *filePath); + +public: + + //获取路径下的所有文件夹和文件 + static vector getFoldersAndFile(const string &path, bool showAbsolutePath = true); + + //获取路径下的所有文件夹 + static vector getFolders(const string &path, bool showAbsolutePath = true); + + //获取路径下的所有文件,可指定文件后缀名 + static vector getFiles(const string &path, bool showAbsolutePath = true, const string &postfix = ""); + + //检查文件或目录是否准备好,一定程度上防止数据正在拷贝的时候去读写。 + //方法是检查文件或目录的access time是否在5分钟以前 + static bool isPrepared(const string &path); + + //判断是否为文件夹 + static bool isFolder(const string &path); + + //判断是否为文件 + static bool isFile(const string &path); + + //判断文件或文件夹是否存在 + static bool fileExists(const string &path); + + //删除非空文件夹 + static void deleteFile(const string &path); + + //复制文件 + static bool copyFile(const char *src, const char *des); + + //复制文件夹(des的路径如果存在则直接替换成新的版本) + static void copyFolder(const char *src, const char *des); + +}; + + +#endif /* defined(__ozgcc2dxutils__OzgFileUtility__) */ diff --git a/Classes/OzgJoystickLayer.cpp b/Classes/OzgJoystickLayer.cpp new file mode 100755 index 0000000..bfe00d7 --- /dev/null +++ b/Classes/OzgJoystickLayer.cpp @@ -0,0 +1,197 @@ + +#include "OzgJoystickLayer.h" + +#define STICK_BG_TAG 99999 + +OzgJoystickLayer::OzgJoystickLayer() +{ + +} + +OzgJoystickLayer::~OzgJoystickLayer() +{ + +// CCLog("OzgJoystickLayer 释放"); +} + +OzgJoystickLayer* OzgJoystickLayer::layerActivityJoystick(float aRadius, cocos2d::CCSprite *aJsSprite, cocos2d::CCSprite *aJsBg, bool aIsFollowRole) +{ + OzgJoystickLayer *jstick = new OzgJoystickLayer(); + if(jstick->initWithCenter(CCPointZero, aRadius, aJsSprite, aJsBg, true, aIsFollowRole)) + { + jstick->autorelease(); + return jstick; + } + CC_SAFE_DELETE(jstick); + return NULL; +} + +OzgJoystickLayer* OzgJoystickLayer::layerStaticJoystick(CCPoint aPoint, float aRadius, CCSprite* aJsSprite, CCSprite* aJsBg, bool aIsFollowRole) +{ + OzgJoystickLayer *jstick = new OzgJoystickLayer(); + if(jstick->initWithCenter(aPoint, aRadius, aJsSprite, aJsBg, false, aIsFollowRole)) + { + jstick->autorelease(); + return jstick; + } + CC_SAFE_DELETE(jstick); + return NULL; +} + +OzgJoystickLayer* OzgJoystickLayer::initWithCenter(CCPoint aPoint, float aRadius, CCSprite* aJsSprite, CCSprite* aJsBg, bool aIsActivityJoystick, bool aIsFollowRole) +{ + this->m_trigger = false; //没有触发摇杆 + this->m_isFollowRole = aIsFollowRole; + this->m_active = false; + this->m_radius = aRadius; + if(!aIsFollowRole) + this->m_centerPoint = aPoint; + else + this->m_centerPoint = ccp(0,0); + + this->m_activityJoystick = aIsActivityJoystick; + + this->m_currentPoint = this->m_centerPoint; + this->m_jsSprite = aJsSprite; + this->m_jsSprite->setPosition(this->m_centerPoint); + aJsBg->setPosition(this->m_centerPoint); + aJsBg->setTag(STICK_BG_TAG); + this->addChild(aJsBg); + this->addChild(this->m_jsSprite); + if(this->m_isFollowRole) + this->setVisible(false); + + //活动摇杆 + if(this->m_activityJoystick) + { + this->m_jsSprite->setVisible(false); + aJsBg->setVisible(false); + } + + this->active(); //激活摇杆 + return this; +} + +//启动摇杆 +void OzgJoystickLayer::active() +{ + if (!this->m_active) + { + this->m_active = true; + this->schedule(schedule_selector(OzgJoystickLayer::updatePos)); //添加刷新函数 + CCDirector::sharedDirector()->getTouchDispatcher()->addTargetedDelegate(this, 999, false); //添加触摸委托 + } + // else + // { + // + // } +} + +//解除摇杆 +void OzgJoystickLayer::inactive() +{ + if (this->m_active) + { + this->m_active = false; + this->unschedule(schedule_selector(OzgJoystickLayer::updatePos)); //删除刷新 + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(this); //删除委托 + } + // else + // { + // + // } +} + +//摇杆方位 +CCPoint OzgJoystickLayer::getDirection() +{ + return ccpNormalize(ccpSub(this->m_centerPoint, this->m_currentPoint)); +} + +//摇杆力度 +float OzgJoystickLayer::getVelocity() +{ + return ccpDistance(this->m_centerPoint, this->m_currentPoint); +} + +void OzgJoystickLayer::updatePos(float dt) +{ + this->m_jsSprite->setPosition(ccpAdd(this->m_jsSprite->getPosition(), ccpMult(ccpSub(this->m_currentPoint, this->m_jsSprite->getPosition()), 0.5))); +} + +bool OzgJoystickLayer::ccTouchBegan(CCTouch* touch, CCEvent* event) +{ + if (!this->m_active) + return false; + + this->setVisible(true); + CCPoint touchPoint = touch->getLocation(); + + //活动摇杆 + if(this->m_activityJoystick) + { + this->m_centerPoint = touchPoint; + + this->m_jsSprite->setVisible(true); + this->m_jsSprite->setPosition(this->m_centerPoint); + + CCSprite* aJsBg = (CCSprite*)this->getChildByTag(STICK_BG_TAG); + aJsBg->setPosition(this->m_centerPoint); + aJsBg->setVisible(true); + } + + if(!this->m_isFollowRole) + { + if (ccpDistance(touchPoint, this->m_centerPoint) > this->m_radius) + return false; + + } + + this->m_trigger = true; //正在触发摇杆 + + this->m_currentPoint = touchPoint; + + if(this->m_isFollowRole) + { + this->m_centerPoint = this->m_currentPoint; + this->m_jsSprite->setPosition(this->m_currentPoint); + + this->getChildByTag(STICK_BG_TAG)->setPosition(this->m_currentPoint); + } + return true; +} + +void OzgJoystickLayer::ccTouchMoved(CCTouch* touch, CCEvent* event) +{ + CCPoint touchPoint = touch->getLocation(); + if (ccpDistance(touchPoint, this->m_centerPoint) > this->m_radius) + this->m_currentPoint = ccpAdd(this->m_centerPoint, ccpMult(ccpNormalize(ccpSub(touchPoint, this->m_centerPoint)), this->m_radius)); + else + this->m_currentPoint = touchPoint; + +} + +void OzgJoystickLayer::ccTouchEnded(CCTouch* touch, CCEvent* event) +{ + this->m_currentPoint = this->m_centerPoint; + if(this->m_isFollowRole) + this->setVisible(false); + + this->m_trigger = false; //松开时设置为没有触发摇杆 + + //活动摇杆 + if(this->m_activityJoystick) + { + this->m_jsSprite->setVisible(false); + + CCSprite* aJsBg = (CCSprite*)this->getChildByTag(STICK_BG_TAG); + aJsBg->setPosition(this->m_centerPoint); + aJsBg->setVisible(false); + } + + if(this->m_target) + { + CCCallFunc *endedFunc = CCCallFunc::create(this->m_target, m_endedSelector); + this->runAction(endedFunc); + } +} diff --git a/Classes/OzgJoystickLayer.h b/Classes/OzgJoystickLayer.h new file mode 100755 index 0000000..9d689e9 --- /dev/null +++ b/Classes/OzgJoystickLayer.h @@ -0,0 +1,89 @@ + +#ifndef __ozgcc2dxutils__OzgJoystickLayer__ +#define __ozgcc2dxutils__OzgJoystickLayer__ + +/* + demo + + 释放时需要调用inactive() + + bool HelloWorld::init() + { + if ( !CCLayer::init() ) + { + return false; + } + + CCSprite *spJoystick = CCSprite::createWithSpriteFrameName("joystick01.png"); + CCSprite *joystickBg = CCSprite::createWithSpriteFrameName("joystick02.png"); + // OzgJoystickLayer *joystick = OzgJoystickLayer::layerActivityJoystick(50, spJoystick, joystickBg, false); + OzgJoystickLayer *joystick = OzgJoystickLayer::layerStaticJoystick(ccp(200, 100), 50, spJoystick, joystickBg, false); + joystick->setTag(1); + this->addChild(joystick); + + this->scheduleUpdate(); + + return true; + } + + void HelloWorld::update(float dt) + { + OzgJoystickLayer *joystick = (OzgJoystickLayer*)this->getChildByTag(1); + if(joystick->m_trigger) + CCLog("%f %f %f %f %f", joystick->m_centerPoint.x, joystick->m_centerPoint.y, joystick->m_currentPoint.x, joystick->m_currentPoint.y, dt); + + } + + */ + +#include "cocos2d.h" + +USING_NS_CC; + +class OzgJoystickLayer : public CCLayer +{ + +public: + + CCPoint m_centerPoint; //摇杆中心 + CCPoint m_currentPoint; //摇杆当前位置 + bool m_trigger; //是否正在触发摇杆 + bool m_active; //是否激活摇杆 + float m_radius; //摇杆半径 + CCSprite* m_jsSprite; + + bool m_activityJoystick; //是否为活动摇杆 + + bool m_isFollowRole; //是否跟随用户点击 + + CCObject* m_target; + SEL_CallFunc m_endedSelector; + + OzgJoystickLayer(); + virtual ~OzgJoystickLayer(); + + //初始化 aPoint是摇杆中心 aRadius是摇杆半径 aJsSprite是摇杆控制点 aJsBg是摇杆背景 + static OzgJoystickLayer* layerActivityJoystick(float aRadius, CCSprite* aJsSprite, CCSprite* aJsBg, bool aIsFollowRole); + static OzgJoystickLayer* layerStaticJoystick(CCPoint aPoint, float aRadius, CCSprite* aJsSprite, CCSprite* aJsBg, bool aIsFollowRole); + + OzgJoystickLayer* initWithCenter(CCPoint aPoint, float aRadius, CCSprite* aJsSprite, CCSprite* aJsBg, bool aIsActivityJoystick, bool aIsFollowRole); + + //启动摇杆 + void active(); + + //解除摇杆 + void inactive(); + + CCPoint getDirection(); + float getVelocity(); + void updatePos(float dt); + + CREATE_FUNC(OzgJoystickLayer); + + virtual bool ccTouchBegan(CCTouch *pTouch, CCEvent *pEvent); + virtual void ccTouchMoved(CCTouch *pTouch, CCEvent *pEvent); + virtual void ccTouchEnded(CCTouch *pTouch, CCEvent *pEvent); + +}; + +#endif /* defined(__ozgcc2dxutils__OzgJoystickLayer__) */ diff --git a/Classes/RPGBaseSceneLayer.cpp b/Classes/RPGBaseSceneLayer.cpp new file mode 100755 index 0000000..265a762 --- /dev/null +++ b/Classes/RPGBaseSceneLayer.cpp @@ -0,0 +1,69 @@ +// +// RPGBaseSceneLayer.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#include "RPGBaseSceneLayer.h" + +void addLab(CCNode* parentNode, int tag, CCString* text, CCPoint point) +{ + addLab(parentNode, tag, text, 20, point); +} + +void addLab(CCNode* parentNode, int tag, CCString* text, float fontSize, CCPoint point) +{ + addLab(parentNode, tag, text, fontSize, kCCTextAlignmentLeft, point); +} + +void addLab(CCNode* parentNode, int tag, CCString* text, float fontSize, CCTextAlignment textAlignment, CCPoint point) +{ + CCLabelTTF *textLab = CCLabelTTF::create(text->getCString(), "Arial", fontSize, CCSizeMake(400, 25), textAlignment); + textLab->setPosition(point); + textLab->setTag(tag); + parentNode->addChild(textLab); +} + +void saveData(CppSQLite3DB* db, int mapId, float toX, float toY, string playerDirection) +{ + + db->execDML(CCString::createWithFormat("update save_data set map_id = %i, player_to_x = %f, player_to_y = %f, player_direction = '%s' where id = 1", mapId, toX, toY, playerDirection.c_str())->getCString()); +} + +void savePlayerData(CppSQLite3DB* db, CCArray* playerDataList) +{ + for (int i = 0; i < playerDataList->count(); i++) + { + RPGPlayer *playerData = (RPGPlayer*)playerDataList->objectAtIndex(i); + + CCString *sql = CCString::createWithFormat("update player set max_hp = %i, hp = %i, max_mp = %i, mp = %i, attack = %f, defense = %f, speed = %f, magic_attack = %f, magic_defense = %f, items_id_arms = %i, items_id_armor = %i, level = %i, skill = '%s', next_exp = %i where id = %i", playerData->m_maxHP, playerData->m_HP, playerData->m_maxMP, playerData->m_MP, playerData->m_attack, playerData->m_defense, playerData->m_speed, playerData->m_magicAttack, playerData->m_magicDefense, playerData->m_itemsIdArms, playerData->m_itemsIdArmor, playerData->m_level, playerData->m_skill.c_str(), playerData->m_nextExp, playerData->m_dataId); + db->execDML(sql->getCString()); + } +} + +RPGBaseSceneLayer::RPGBaseSceneLayer() +{ + +} + +RPGBaseSceneLayer::~RPGBaseSceneLayer() +{ + this->m_db.close(); + +} + +bool RPGBaseSceneLayer::init() +{ + if(CCLayer::init()) + { + string dbPath = CCFileUtils::sharedFileUtils()->getWritablePath(); + dbPath.append(GAME_SYS_DB); + this->m_db.open(dbPath.c_str()); + + return true; + } + + return false; +} diff --git a/Classes/RPGBaseSceneLayer.h b/Classes/RPGBaseSceneLayer.h new file mode 100755 index 0000000..ee8afd0 --- /dev/null +++ b/Classes/RPGBaseSceneLayer.h @@ -0,0 +1,52 @@ +// +// RPGBaseSceneLayer.h +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#ifndef __OzgGameRPG__RPGBaseSceneLayer__ +#define __OzgGameRPG__RPGBaseSceneLayer__ + +#include "cocos2d.h" +#include "cocos-ext.h" +#include "JsonBox.h" +#include "SimpleAudioEngine.h" +#include "CppSQLite3.h" +#include "GameCfg.h" +#include "RPGConfirmLayer.h" +#include "RPGData.h" + +USING_NS_CC; +USING_NS_CC_EXT; + +using namespace std; +using namespace CocosDenshion; + +//获取player列表 +#define PLAYER_QUERY "select * from player order by id asc" + +void addLab(CCNode* parentNode, int tag, CCString* text, CCPoint point); //增加状态界面的lab +void addLab(CCNode* parentNode, int tag, CCString* text, float fontSize, CCPoint point); +void addLab(CCNode* parentNode, int tag, CCString* text, float fontSize, CCTextAlignment textAlignment, CCPoint point); + +void saveData(CppSQLite3DB* db, int mapId, float toX, float toY, string playerDirection); +void savePlayerData(CppSQLite3DB* db, CCArray* playerDataList); + +class RPGBaseSceneLayer : public CCLayer +{ + +protected: + CCDictionary *m_stringList; //语言文件的数据 + CppSQLite3DB m_db; + +public: + + RPGBaseSceneLayer(); + virtual ~RPGBaseSceneLayer(); + virtual bool init(); + +}; + +#endif /* defined(__OzgGameRPG__RPGBaseSceneLayer__) */ diff --git a/Classes/RPGBattleMenu.cpp b/Classes/RPGBattleMenu.cpp new file mode 100644 index 0000000..53d557f --- /dev/null +++ b/Classes/RPGBattleMenu.cpp @@ -0,0 +1,172 @@ +// +// RPGBattleMenu.cpp +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-6. +// +// + +#include "RPGBattleMenu.h" + +RPGBattleMenu::RPGBattleMenu() +{ + +} + +RPGBattleMenu::~RPGBattleMenu() +{ + this->m_stringList->release(); + this->m_parentNode->release(); + this->m_playerData->release(); + + CCLog("RPGBattleMenu 释放"); +} + +bool RPGBattleMenu::initWithParentNode(CCDictionary* stringList, CCNode* parentNode, RPGPlayer* playerData) +{ + if(CCMenu::init()) + { + this->m_stringList = stringList; + this->m_stringList->retain(); + + this->m_parentNode = parentNode; + this->m_parentNode->retain(); + + this->m_playerData = playerData; + this->m_playerData->retain(); + + this->setPosition(CCPointZero); + + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->m_parentNode->getChildByTag(kRPGBattleMenuTagBg); + if(!bgLayer) + { + bgLayer = CCTMXTiledMap::create("battle_battlemenu_style1.tmx"); + bgLayer->setPosition(ccp(750, 64)); + bgLayer->setTag(kRPGBattleMenuTagBg); + parentNode->addChild(bgLayer); + } + + CCString *menuAttackStr = (CCString*)this->m_stringList->objectForKey("battle_playermenu_attack"); + this->createMenuItem(830, 250, menuAttackStr, kRPGBattleMenuTagAttack); + + CCString *menuSkillStr = (CCString*)this->m_stringList->objectForKey("battle_playermenu_skill"); + this->createMenuItem(830, 200, menuSkillStr, kRPGBattleMenuTagSkill); + + CCString *menuItemsStr = (CCString*)this->m_stringList->objectForKey("battle_playermenu_items"); + this->createMenuItem(830, 150, menuItemsStr, kRPGBattleMenuTagItems); + + CCString *menuEscapeStr = (CCString*)this->m_stringList->objectForKey("battle_playermenu_escape"); + this->createMenuItem(830, 100, menuEscapeStr, kRPGBattleMenuTagEscape); + + SimpleAudioEngine::sharedEngine()->playEffect("audio_battle_menu.wav"); + + return true; + } + return false; +} + +RPGBattleMenu* RPGBattleMenu::createWithParentNode(CCDictionary* stringList, CCNode* parentNode, RPGPlayer* playerData) +{ + RPGBattleMenu *obj = new RPGBattleMenu(); + if(obj && obj->initWithParentNode(stringList, parentNode, playerData)) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +void RPGBattleMenu::showMenu() +{ + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->getChildByTag(kRPGBattleMenuTagBg); + bgLayer->setVisible(true); + + this->setVisible(true); +} + +void RPGBattleMenu::hideMenu() +{ + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->getChildByTag(kRPGBattleMenuTagBg); + bgLayer->setVisible(false); + + this->setVisible(false); +} + +//private + +void RPGBattleMenu::createMenuItem(float x, float y, CCString *text, RPGBattleMenuTag tag) +{ + CCMenuItemLabel *menuItems = (CCMenuItemLabel*)this->getChildByTag(tag); + if(!menuItems) + { + CCLabelTTF *menuItemsLabel = CCLabelTTF::create(OzgCCUtility::generalString(text->getCString()).c_str(), "Arial", 28, CCSizeMake(120, 30), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + + CCMenuItemLabel *menuItems = CCMenuItemLabel::create(menuItemsLabel, this, menu_selector(RPGBattleMenu::onMenu)); + menuItems->setPosition(ccp(x, y)); + menuItems->setTag(tag); + this->addChild(menuItems); + + } +} + +void RPGBattleMenu::onMenu(cocos2d::CCObject *pObject) +{ + CCMenuItem *menuItem = (CCMenuItem*)pObject; + SimpleAudioEngine::sharedEngine()->playEffect("audio_effect_btn.wav"); + + switch (menuItem->getTag()) + { + case kRPGBattleMenuTagSkill: + { + CCLog("技能"); + + } + break; + case kRPGBattleMenuTagItems: + { + CCLog("道具"); + + } + break; + case kRPGBattleMenuTagEscape: + { +// CCLog("逃跑"); + + float success = CCRANDOM_0_1(); + if(success >= 0.0 && success <= 0.5) + { +// CCLog("逃跑成功"); + + this->setEnabled(false); + this->removeFromParentAndCleanup(true); + + ((RPGBattleSceneLayer*)this->m_parentNode)->goToMap(); + } + else + { + ((RPGBattleSceneLayer*)this->m_parentNode)->showMsg((CCString*)this->m_stringList->objectForKey("escape_fail")); + + //重置进度条 + this->m_playerData->m_progress = 0.0; + CCProgressTimer *battleProgress = (CCProgressTimer*)this->m_parentNode->getChildByTag(kRPGBattleSceneLayerTagPlayerProgress + this->m_playerData->m_dataId); + battleProgress->setPercentage(this->m_playerData->m_progress); + + ((RPGBattleSceneLayer*)this->m_parentNode)->scheduleUpdate(); + + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->m_parentNode->getChildByTag(kRPGBattleMenuTagBg); + bgLayer->removeFromParentAndCleanup(true); + this->removeFromParentAndCleanup(true); + } + + } + break; + default: + { + CCLog("攻击"); + + } + break; + } + +} diff --git a/Classes/RPGBattleMenu.h b/Classes/RPGBattleMenu.h new file mode 100644 index 0000000..087de65 --- /dev/null +++ b/Classes/RPGBattleMenu.h @@ -0,0 +1,52 @@ +// +// RPGBattleMenu.h +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-6. +// +// + +#ifndef __OzgGameRPG__RPGBattleMenu__ +#define __OzgGameRPG__RPGBattleMenu__ + +#include "cocos2d.h" +#include "RPGBattleSceneLayer.h" + +USING_NS_CC; + +enum RPGBattleMenuTag +{ + kRPGBattleMenuTagBg = 99, + kRPGBattleMenuTagAttack = 2, + kRPGBattleMenuTagSkill = 4, + kRPGBattleMenuTagItems = 5, + kRPGBattleMenuTagEscape = 6 + +}; + +class RPGBattleMenu : public CCMenu +{ + +private: + CCNode* m_parentNode; + + CCDictionary* m_stringList; + + RPGPlayer* m_playerData; + + void createMenuItem(float x, float y, CCString *text, RPGBattleMenuTag tag); + void onMenu(CCObject *pObject); + +public: + + RPGBattleMenu(); + virtual ~RPGBattleMenu(); + bool initWithParentNode(CCDictionary* stringList, CCNode* parentNode, RPGPlayer* playerData); + static RPGBattleMenu* createWithParentNode(CCDictionary* stringList, CCNode* parentNode, RPGPlayer* playerData); + + void showMenu(); //显示战斗菜单 + void hideMenu(); //隐藏战斗菜单 + +}; + +#endif /* defined(__OzgGameRPG__RPGBattleMenu__) */ diff --git a/Classes/RPGBattleMonsterSprite.cpp b/Classes/RPGBattleMonsterSprite.cpp new file mode 100644 index 0000000..719306f --- /dev/null +++ b/Classes/RPGBattleMonsterSprite.cpp @@ -0,0 +1,43 @@ +// +// RPGBattleMonsterSprite.cpp +// OzgGameRPG +// +// Created by ozg on 14-4-4. +// +// + +#include "RPGBattleMonsterSprite.h" + +RPGBattleMonsterSprite::RPGBattleMonsterSprite() +{ + +} + +RPGBattleMonsterSprite::~RPGBattleMonsterSprite() +{ + + CCLog("RPGBattleMonsterSprite 释放"); +} + +bool RPGBattleMonsterSprite::initWithMonsterData(RPGMonster* data) +{ + if(CCSprite::initWithSpriteFrameName(data->m_tex.c_str())) + { + this->m_data = data; + + return true; + } + return false; +} + +RPGBattleMonsterSprite* RPGBattleMonsterSprite::createWithMonsterData(RPGMonster* data) +{ + RPGBattleMonsterSprite *obj = new RPGBattleMonsterSprite(); + if(obj && obj->initWithMonsterData(data)) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} diff --git a/Classes/RPGBattleMonsterSprite.h b/Classes/RPGBattleMonsterSprite.h new file mode 100644 index 0000000..79a51fc --- /dev/null +++ b/Classes/RPGBattleMonsterSprite.h @@ -0,0 +1,34 @@ +// +// RPGBattleMonsterSprite.h +// OzgGameRPG +// +// Created by ozg on 14-4-4. +// +// + +#ifndef __OzgGameRPG__RPGBattleMonsterSprite__ +#define __OzgGameRPG__RPGBattleMonsterSprite__ + +#include "cocos2d.h" +#include "RPGData.h" + +USING_NS_CC; +using namespace std; + +class RPGBattleMonsterSprite : public CCSprite +{ + +private: + + RPGMonster* m_data; + +public: + RPGBattleMonsterSprite(); + virtual ~RPGBattleMonsterSprite(); + bool initWithMonsterData(RPGMonster* data); + + static RPGBattleMonsterSprite* createWithMonsterData(RPGMonster* data); + +}; + +#endif /* defined(__OzgGameRPG__RPGBattleMonsterSprite__) */ diff --git a/Classes/RPGBattlePlayerSprite.cpp b/Classes/RPGBattlePlayerSprite.cpp new file mode 100644 index 0000000..2f5b3dc --- /dev/null +++ b/Classes/RPGBattlePlayerSprite.cpp @@ -0,0 +1,128 @@ +// +// RPGBattlePlayerSprite.cpp +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-3. +// +// + +#include "RPGBattlePlayerSprite.h" +#include "OzgCCUtility.h" + +RPGBattlePlayerSprite::RPGBattlePlayerSprite() +{ + +} + +RPGBattlePlayerSprite::~RPGBattlePlayerSprite() +{ + this->m_spriteFramesNormal->release(); + this->m_spriteFramesHurt->release(); + this->m_spriteFramesDying->release(); + this->m_spriteFramesWin->release(); + this->m_spriteFramesAvoid->release(); + this->m_spriteFramesDeath->release(); + this->m_spriteFramesAttack->release(); + this->m_spriteFramesUseItem->release(); + this->m_spriteFramesSpecialAttack->release(); + this->m_spriteFramesChanting->release(); + + CCLog("RPGBattlePlayerSprite 释放"); +} + +bool RPGBattlePlayerSprite::initWithPlayerData(RPGPlayer* data) +{ + CCArray *spriteFrames1 = OzgCCUtility::createSpriteFrames(CCString::createWithFormat("%s_1.png", data->m_texPrefix.c_str())->getCString(), 3, 4); + CCArray *spriteFrames2 = OzgCCUtility::createSpriteFrames(CCString::createWithFormat("%s_2.png", data->m_texPrefix.c_str())->getCString(), 3, 4); + CCArray *spriteFrames3 = OzgCCUtility::createSpriteFrames(CCString::createWithFormat("%s_3.png", data->m_texPrefix.c_str())->getCString(), 3, 4); + + this->m_spriteFramesNormal = new CCArray(); + this->m_spriteFramesNormal->init(); + this->m_spriteFramesNormal->addObject(spriteFrames1->objectAtIndex(0)); + this->m_spriteFramesNormal->addObject(spriteFrames1->objectAtIndex(1)); + this->m_spriteFramesNormal->addObject(spriteFrames1->objectAtIndex(2)); + this->m_spriteFramesNormal->addObject(spriteFrames1->objectAtIndex(1)); + + this->m_spriteFramesHurt = new CCArray(); + this->m_spriteFramesHurt->init(); + this->m_spriteFramesHurt->addObject(spriteFrames1->objectAtIndex(3)); + this->m_spriteFramesHurt->addObject(spriteFrames1->objectAtIndex(4)); + this->m_spriteFramesHurt->addObject(spriteFrames1->objectAtIndex(5)); + + this->m_spriteFramesDying = new CCArray(); + this->m_spriteFramesDying->init(); + this->m_spriteFramesDying->addObject(spriteFrames1->objectAtIndex(6)); + this->m_spriteFramesDying->addObject(spriteFrames1->objectAtIndex(7)); + this->m_spriteFramesDying->addObject(spriteFrames1->objectAtIndex(8)); + this->m_spriteFramesDying->addObject(spriteFrames1->objectAtIndex(7)); + + this->m_spriteFramesWin = new CCArray(); + this->m_spriteFramesWin->init(); + this->m_spriteFramesWin->addObject(spriteFrames2->objectAtIndex(0)); + this->m_spriteFramesWin->addObject(spriteFrames2->objectAtIndex(1)); + this->m_spriteFramesWin->addObject(spriteFrames2->objectAtIndex(2)); + this->m_spriteFramesWin->addObject(spriteFrames2->objectAtIndex(1)); + + this->m_spriteFramesAvoid = new CCArray(); + this->m_spriteFramesAvoid->init(); + this->m_spriteFramesAvoid->addObject(spriteFrames2->objectAtIndex(3)); + this->m_spriteFramesAvoid->addObject(spriteFrames2->objectAtIndex(4)); + this->m_spriteFramesAvoid->addObject(spriteFrames2->objectAtIndex(5)); + + this->m_spriteFramesDeath = new CCArray(); + this->m_spriteFramesDeath->init(); + this->m_spriteFramesDeath->addObject(spriteFrames2->objectAtIndex(9)); + this->m_spriteFramesDeath->addObject(spriteFrames2->objectAtIndex(10)); + this->m_spriteFramesDeath->addObject(spriteFrames2->objectAtIndex(11)); + this->m_spriteFramesDeath->addObject(spriteFrames2->objectAtIndex(10)); + + this->m_spriteFramesAttack = new CCArray(); + this->m_spriteFramesAttack->init(); + this->m_spriteFramesAttack->addObject(spriteFrames3->objectAtIndex(0)); + this->m_spriteFramesAttack->addObject(spriteFrames3->objectAtIndex(1)); + this->m_spriteFramesAttack->addObject(spriteFrames3->objectAtIndex(2)); + + this->m_spriteFramesUseItem = new CCArray(); + this->m_spriteFramesUseItem->init(); + this->m_spriteFramesUseItem->addObject(spriteFrames3->objectAtIndex(3)); + this->m_spriteFramesUseItem->addObject(spriteFrames3->objectAtIndex(4)); + this->m_spriteFramesUseItem->addObject(spriteFrames3->objectAtIndex(5)); + + this->m_spriteFramesSpecialAttack = new CCArray(); + this->m_spriteFramesSpecialAttack->init(); + this->m_spriteFramesSpecialAttack->addObject(spriteFrames3->objectAtIndex(6)); + this->m_spriteFramesSpecialAttack->addObject(spriteFrames3->objectAtIndex(7)); + this->m_spriteFramesSpecialAttack->addObject(spriteFrames3->objectAtIndex(8)); + + this->m_spriteFramesChanting = new CCArray(); + this->m_spriteFramesChanting->init(); + this->m_spriteFramesChanting->addObject(spriteFrames3->objectAtIndex(9)); + this->m_spriteFramesChanting->addObject(spriteFrames3->objectAtIndex(10)); + this->m_spriteFramesChanting->addObject(spriteFrames3->objectAtIndex(11)); + this->m_spriteFramesChanting->addObject(spriteFrames3->objectAtIndex(10)); + + if(CCSprite::initWithSpriteFrame((CCSpriteFrame*)this->m_spriteFramesNormal->objectAtIndex(0))) + { + this->m_data = data; + this->setScale(1.75); + + CCAnimation *animation = CCAnimation::createWithSpriteFrames(this->m_spriteFramesNormal, 0.2); + CCRepeatForever *animate = CCRepeatForever::create(CCAnimate::create(animation)); + this->runAction(animate); + + return true; + } + return false; +} + +RPGBattlePlayerSprite* RPGBattlePlayerSprite::createWithPlayerData(RPGPlayer* data) +{ + RPGBattlePlayerSprite *obj = new RPGBattlePlayerSprite(); + if(obj && obj->initWithPlayerData(data)) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} diff --git a/Classes/RPGBattlePlayerSprite.h b/Classes/RPGBattlePlayerSprite.h new file mode 100644 index 0000000..3578644 --- /dev/null +++ b/Classes/RPGBattlePlayerSprite.h @@ -0,0 +1,44 @@ +// +// RPGBattlePlayerSprite.h +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-3. +// +// + +#ifndef __OzgGameRPG__RPGBattlePlayerSprite__ +#define __OzgGameRPG__RPGBattlePlayerSprite__ + +#include "cocos2d.h" +#include "RPGData.h" + +USING_NS_CC; +using namespace std; + +class RPGBattlePlayerSprite : public CCSprite +{ + +private: + + RPGPlayer* m_data; + CCArray* m_spriteFramesNormal; //通常 + CCArray* m_spriteFramesHurt; //受到攻击 + CCArray* m_spriteFramesDying; //临死 + CCArray* m_spriteFramesWin; //胜利 + CCArray* m_spriteFramesAvoid; //回避 + CCArray* m_spriteFramesDeath; //战斗不能 + CCArray* m_spriteFramesAttack; //一般攻击 + CCArray* m_spriteFramesUseItem; //使用道具 + CCArray* m_spriteFramesSpecialAttack; //特殊攻击 + CCArray* m_spriteFramesChanting; //咏唱 + +public: + + RPGBattlePlayerSprite(); + virtual ~RPGBattlePlayerSprite(); + bool initWithPlayerData(RPGPlayer* data); + static RPGBattlePlayerSprite* createWithPlayerData(RPGPlayer* data); + +}; + +#endif /* defined(__OzgGameRPG__RPGBattlePlayerSprite__) */ diff --git a/Classes/RPGBattleSceneLayer.cpp b/Classes/RPGBattleSceneLayer.cpp new file mode 100755 index 0000000..ddb77e4 --- /dev/null +++ b/Classes/RPGBattleSceneLayer.cpp @@ -0,0 +1,528 @@ +// +// RPGBattleSceneLayer.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#include "RPGBattleSceneLayer.h" +#include "RPGLoadingSceneLayer.h" + +#define MONSTER_QUERY "select * from monster where map_id = %i order by random() limit 1" + +RPGBattleSceneLayer::RPGBattleSceneLayer() +{ + +} + +RPGBattleSceneLayer::~RPGBattleSceneLayer() +{ + this->m_playerDataList->release(); + this->m_monsterDataList->release(); + this->m_playerList->release(); + this->m_monsterList->release(); + + CCSpriteFrameCache::sharedSpriteFrameCache()->removeSpriteFramesFromFile("monsters.plist"); + + CCLog("RPGBattleSceneLayer 释放"); +} + +bool RPGBattleSceneLayer::init() +{ + if(RPGBaseSceneLayer::init()) + { + CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile("monsters.plist"); + + //加载语言文件 + string languageFile = CCFileUtils::sharedFileUtils()->fullPathForFilename("scene_battle_cns.plist"); + this->m_stringList = CCDictionary::createWithContentsOfFileThreadSafe(languageFile.c_str()); + this->m_stringList->retain(); + + CCSprite *bg = CCSprite::create("battle_bg.png"); + bg->setPosition(ccp(CCDirector::sharedDirector()->getWinSize().width / 2, CCDirector::sharedDirector()->getWinSize().height / 2)); + bg->setTag(kRPGBattleSceneLayerTagBg); + this->addChild(bg); + + //背景音乐 + if(SimpleAudioEngine::sharedEngine()->isBackgroundMusicPlaying()) + { + SimpleAudioEngine::sharedEngine()->stopBackgroundMusic(true); + SimpleAudioEngine::sharedEngine()->playBackgroundMusic("audio_battle.mp3", true); + } + + //下面的菜单 + CCTMXTiledMap *menuLayer = CCTMXTiledMap::create("battle_menu_style1.tmx"); + menuLayer->setTag(kRPGBattleSceneLayerTagMenuBg); + menuLayer->setPosition(ccp((CCDirector::sharedDirector()->getWinSize().width - menuLayer->getContentSize().width) / 2.0, (CCDirector::sharedDirector()->getWinSize().height - bg->getContentSize().height) / 2)); + this->addChild(menuLayer); + + this->m_playerDataList = new CCArray(); + this->m_playerDataList->init(); + + this->m_monsterDataList = new CCArray(); + this->m_monsterDataList->init(); + + this->m_playerList = new CCArray(); + this->m_playerList->init(); + + this->m_monsterList = new CCArray(); + this->m_monsterList->init(); + + this->m_speedTotal = 0; //速度总值的初始化 + + //player + float playerY = 620; + float separateY = 197; + float playerLabY = 215; + float progressY = 217; + + int i = 0; + + this->m_playerDataList->removeAllObjects(); + CppSQLite3Query query = this->m_db.execQuery(PLAYER_QUERY); + while(!query.eof()) + { + RPGPlayer *playerData = RPGPlayer::create(); + playerData->m_dataId = query.getIntField("id"); + playerData->m_maxHP = query.getIntField("max_hp"); + playerData->m_HP = query.getIntField("hp"); + playerData->m_maxMP = query.getIntField("max_mp"); + playerData->m_MP = query.getIntField("mp"); + playerData->m_attack = query.getFloatField("attack"); + playerData->m_defense = query.getFloatField("defense"); + playerData->m_speed = query.getFloatField("speed"); + playerData->m_magicAttack = query.getFloatField("magic_attack"); + playerData->m_magicDefense = query.getFloatField("magic_defense"); + playerData->m_level = query.getIntField("level"); + playerData->m_name = query.getStringField("name_cns"); + playerData->m_nextExp = query.getIntField("next_exp"); + playerData->m_itemsIdArmor = query.getIntField("items_id_armor"); + playerData->m_itemsIdArms = query.getIntField("items_id_arms"); + playerData->m_skill = query.getStringField("skill"); + playerData->m_texPrefix = query.getStringField("tex_prefix"); + playerData->m_progress = 0.0; //computingProgress方法会重新计算这个值 + + playerData->m_speed = this->computingFloat(playerData->m_speed); + this->m_speedTotal += playerData->m_speed; //累加速度总值 + + this->m_playerDataList->addObject(playerData); + + //角色 + RPGBattlePlayerSprite *player = RPGBattlePlayerSprite::createWithPlayerData(playerData); + player->setPosition(ccp(880, playerY)); + player->setTag(kRPGBattleSceneLayerTagPlayer + playerData->m_dataId); + this->addChild(player); + + this->m_playerList->addObject(player); + + //分隔线 + if(i > 0) + { + CCSprite *separate = CCSprite::createWithSpriteFrameName("separate.png"); + separate->setPosition(ccp(665, separateY)); + separate->setScaleX(1.4); + this->addChild(separate); + + separateY -= 40; + } + + //名字 + addLab(this, kRPGBattleSceneLayerTagPlayerNameLab + playerData->m_dataId, CCString::create(playerData->m_name), 18, ccp(575, playerLabY)); + + //进度条 + CCSprite *battleProgressBg = CCSprite::createWithSpriteFrameName("gui_battle_progress_bar01_a.png"); + battleProgressBg->setTag(kRPGBattleSceneLayerTagPlayerProgressBg + playerData->m_dataId); + battleProgressBg->setPosition(ccp(880, progressY)); + battleProgressBg->setScaleX(0.4); + battleProgressBg->setScaleY(0.5); + this->addChild(battleProgressBg); + + CCProgressTimer *battleProgress = CCProgressTimer::create(CCSprite::createWithSpriteFrameName("gui_battle_progress_bar01_b.png")); + battleProgress->setBarChangeRate(ccp(1, 0)); //设置进度条的长度和高度开始变化的大小 + battleProgress->setType(kCCProgressTimerTypeBar); //设置进度条为水平 + battleProgress->setMidpoint(ccp(0, 0)); + battleProgress->setPosition(ccp(880, progressY)); + battleProgress->setScaleX(0.4); + battleProgress->setScaleY(0.5); + battleProgress->setTag(kRPGBattleSceneLayerTagPlayerProgress + playerData->m_dataId); + this->addChild(battleProgress); + + //初始化进度条的进度 +// float progress = this->m_roleListWithInitProgress[role->dataId] * 100; +// battleProgress->setPercentage(50); + //CCLog("%f", progress); + + //HP + addLab(this, kRPGBattleSceneLayerTagPlayerHP + playerData->m_dataId, CCString::createWithFormat("%04i / %04i", playerData->m_HP, playerData->m_maxHP), 18, kCCTextAlignmentRight, ccp(420, playerLabY)); + + //MP + addLab(this, kRPGBattleSceneLayerTagPlayerMP + playerData->m_dataId, CCString::createWithFormat("%03i / %03i", playerData->m_MP, playerData->m_maxMP), 15, kCCTextAlignmentRight, ccp(535, playerLabY - 3)); + + playerY -= 100; + playerLabY -= 40; + progressY -= 40; + + i++; + query.nextRow(); + } + query.finalize(); + + //怪物部分 + + //第一次调用randomFloat的结果都是一样的,所以不需要 + OzgCCUtility::randomSeed(0); + OzgCCUtility::randomFloat(0.0f, 1.0f); + + //生成怪物数据部分 + int mapId = CCUserDefault::sharedUserDefault()->getIntegerForKey("map_id"); + + OzgCCUtility::rangeRand(1, 10); + int monsterCount = OzgCCUtility::rangeRand(1, 4); //最多出现1到4种怪物 + while (monsterCount > 0) + { + //随机查询一个怪物 + CCString *sql = CCString::createWithFormat(MONSTER_QUERY, mapId); + + CppSQLite3Query query = this->m_db.execQuery(sql->getCString()); + while(!query.eof()) + { + RPGMonster *monsterData = RPGMonster::create(); + monsterData->m_dataId = query.getIntField("id"); + monsterData->m_name = query.getStringField("name_cns"); + monsterData->m_maxHP = query.getIntField("max_hp"); + monsterData->m_HP = query.getIntField("max_hp"); //跟上面的一样 + monsterData->m_attack = query.getFloatField("attack"); + monsterData->m_defense = query.getFloatField("defense"); + monsterData->m_speed = query.getFloatField("speed"); + monsterData->m_magicAttack = query.getFloatField("magic_attack"); + monsterData->m_magicDefense = query.getFloatField("magic_defense"); + monsterData->m_exp = query.getIntField("exp"); + monsterData->m_skill = query.getStringField("skill"); + monsterData->m_tex = query.getStringField("tex"); + monsterData->m_progress = 0.0; //computingProgress方法会重新计算这个值 + + monsterData->m_speed = this->computingFloat(monsterData->m_speed); + this->m_speedTotal += monsterData->m_speed; //累加速度总值 + + CCArray *monsters = this->monsterDataListWithDataId(monsterData->m_dataId); + if(monsters->count() > 0) + { + do + { + monsterData->m_tag = kRPGBattleSceneLayerTagMonster + OzgCCUtility::rangeRand(0, 9999); + } + while (this->monsterDataListExistWithTag(monsterData->m_tag)); + + monsters->addObject(monsterData); + +// CCLog("产生无重复的tag"); + } + else + { + monsterData->m_tag = kRPGBattleSceneLayerTagMonster + OzgCCUtility::rangeRand(0, 9999); + + monsters->addObject(monsterData); + this->m_monsterDataList->addObject(monsters); + +// CCLog("如果不存在对应的怪物则直接插入到怪物数组"); + } + +// CCLog("产生敌人:%i", monsterData->m_tag); + + query.nextRow(); + } + query.finalize(); + + monsterCount--; + } + + //怪物显示部分 + float monsterNameLabY = 220; + + this->m_addedMonsters.clear(); + + for (i = 0; i < this->m_monsterDataList->count(); i++) + { + CCArray *monsters = (CCArray*)this->m_monsterDataList->objectAtIndex(i); + for (int j = 0; j < monsters->count(); j++) + { + RPGMonster *monsterData = (RPGMonster*)monsters->objectAtIndex(j); + RPGBattleMonsterSprite *monster = RPGBattleMonsterSprite::createWithMonsterData(monsterData); + this->setMonsterPosition(monster); + monster->setTag(monsterData->m_tag); + this->addChild(monster); + + this->m_addedMonsters.push_back(monster->getTag()); + + this->m_monsterList->addObject(monster); + + //左下角的怪物名称 + if(j == 0) + { + addLab(this, kRPGBattleSceneLayerTagMonsterNameLab + monsterData->m_dataId, CCString::createWithFormat("%s x %i", monsterData->m_name.c_str(), (int)monsters->count()), 18, ccp(270, monsterNameLabY)); + + monsterNameLabY -= 40; + } + } + + } + + //怪物部分结束 + + this->computingProgress(); + + this->scheduleUpdate(); + return true; + } + return false; +} + +CCScene* RPGBattleSceneLayer::scene() +{ + CCScene* s = CCScene::create(); + RPGBattleSceneLayer *layer = RPGBattleSceneLayer::create(); + s->addChild(layer); + return s; +} + +void RPGBattleSceneLayer::update(float delta) +{ + float progressSpeed = 0.5; + + //更新player进度条 + for (int i = 0; i < this->m_playerDataList->count(); i++) + { + RPGPlayer *playerData = (RPGPlayer*)this->m_playerDataList->objectAtIndex(i); + playerData->m_progress += progressSpeed; + + if(playerData->m_progress > 100) + playerData->m_progress = 100; + + CCProgressTimer *battleProgress = (CCProgressTimer*)this->getChildByTag(kRPGBattleSceneLayerTagPlayerProgress + playerData->m_dataId); + battleProgress->setPercentage(playerData->m_progress); + + if(playerData->m_progress >= 100) + { + CCLog("显示player菜单"); + + RPGBattleMenu *battleMenu = (RPGBattleMenu*)this->getChildByTag(kRPGBattleSceneLayerTagBattleMenu); + if(battleMenu) + battleMenu->removeFromParentAndCleanup(true); + + battleMenu = RPGBattleMenu::createWithParentNode(this->m_stringList, this, playerData); + battleMenu->setTag(kRPGBattleSceneLayerTagBattleMenu); + this->addChild(battleMenu); + + this->unscheduleUpdate(); + return; + } + + } + + //更新怪物的进度 + for (int i = 0; i < this->m_monsterDataList->count(); i++) + { + CCArray *monsters = (CCArray*)this->m_monsterDataList->objectAtIndex(i); + for (int j = 0; j < monsters->count(); j++) + { + RPGMonster *monsterData = (RPGMonster*)monsters->objectAtIndex(j); +// RPGBattleMonsterSprite *monster = (RPGBattleMonsterSprite*)this->getChildByTag(monsterData->m_tag); + + monsterData->m_progress += progressSpeed; + + if(monsterData->m_progress > 100) + monsterData->m_progress = 100; + + if(monsterData->m_progress >= 100) + { + CCLog("怪物攻击"); + + this->unscheduleUpdate(); + return; + } + } + } + +// CCLog("%f", delta); +} + +void RPGBattleSceneLayer::showMsg(cocos2d::CCString *msgText) +{ + this->showMsg(msgText, true); +} + +void RPGBattleSceneLayer::showMsg(cocos2d::CCString *msgText, bool autoRelease) +{ + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->getChildByTag(kRPGBattleSceneLayerTagMsg); + + //之前已经存在了msg框就先释放 + if(bgLayer) + bgLayer->removeFromParentAndCleanup(true); + + //如果正在执行自动释放msg就先停止 + if(this->m_autoReleaseMsg) + { + this->m_autoReleaseMsg = false; + this->unschedule(schedule_selector(RPGBattleSceneLayer::hideMsg)); + } + + bgLayer = CCTMXTiledMap::create("battle_msg_style1.tmx"); + bgLayer->setPosition(ccp((CCDirector::sharedDirector()->getWinSize().width - bgLayer->getContentSize().width) / 2, 657)); + bgLayer->setTag(kRPGBattleSceneLayerTagMsg); + this->addChild(bgLayer); + + CCLabelTTF *textLab = CCLabelTTF::create(msgText->getCString(), "Arial", 17, CCSizeMake(400, 25), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + textLab->setPosition(ccp(bgLayer->getContentSize().width / 2, bgLayer->getContentSize().height / 2)); + bgLayer->addChild(textLab); + + if(autoRelease) + { + this->m_autoReleaseMsg = true; + this->scheduleOnce(schedule_selector(RPGBattleSceneLayer::hideMsg), 3.0); + } + else + this->m_autoReleaseMsg = false; +} + +void RPGBattleSceneLayer::hideMsg() +{ + this->hideMsg(0); +} + +void RPGBattleSceneLayer::hideMsg(float dt) +{ + CCTMXTiledMap *bgLayer = (CCTMXTiledMap*)this->getChildByTag(kRPGBattleSceneLayerTagMsg); + + if(bgLayer) + bgLayer->removeFromParentAndCleanup(true); + + this->m_autoReleaseMsg = false; +} + +void RPGBattleSceneLayer::goToMap() +{ + //保存player的数据 + savePlayerData(&this->m_db, this->m_playerDataList); + + CCArray *loadTextures = CCArray::create(); + loadTextures->addObject(CCString::create("map.png")); + loadTextures->addObject(CCString::create("joystick.png")); + loadTextures->addObject(CCString::create("actor4_0.png")); + loadTextures->addObject(CCString::create("actor111.png")); + loadTextures->addObject(CCString::create("actor113.png")); + loadTextures->addObject(CCString::create("actor114.png")); + loadTextures->addObject(CCString::create("actor115.png")); + loadTextures->addObject(CCString::create("actor117.png")); + loadTextures->addObject(CCString::create("actor120.png")); + + CCArray *releaseTextures = CCArray::create(); + releaseTextures->addObject(CCString::create("monsters.png")); + releaseTextures->addObject(CCString::create("battle_bg.png")); + + CCScene *s = RPGLoadingSceneLayer::scene(loadTextures, releaseTextures, "single_map"); + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); +} + +//private + +bool RPGBattleSceneLayer::monsterDataListExistWithTag(int tag) +{ + for (int i = 0; i < this->m_monsterDataList->count(); i++) + { + CCArray *monsters = (CCArray*)this->m_monsterDataList->objectAtIndex(i); + + for (int j = 0; j < monsters->count(); j++) + { + RPGMonster *monster = (RPGMonster*)monsters->objectAtIndex(j); + if(monster->m_tag == tag) + return true; + } + } + + return false; +} + +CCArray* RPGBattleSceneLayer::monsterDataListWithDataId(int dataId) +{ + for (int i = 0; i < this->m_monsterDataList->count(); i++) + { + RPGMonster *monster = (RPGMonster*)((CCArray*)this->m_monsterDataList->objectAtIndex(i))->objectAtIndex(0); + if(monster->m_dataId == dataId) + return (CCArray*)this->m_monsterDataList->objectAtIndex(i); + } + + return CCArray::create(); +} + +void RPGBattleSceneLayer::setMonsterPosition(RPGBattleMonsterSprite* monster) +{ +// CCLayerColor *l = CCLayerColor::create(ccc4(200, 200, 200, 200), 700, 420); +// l->setPosition(ccp(50, 270)); +// this->addChild(l); + + bool overlap; //是否重叠 + do + { + overlap = false; + + float x = OzgCCUtility::randomFloat(50 + (monster->getContentSize().width * monster->getAnchorPoint().x), 750 - ((monster->getContentSize().width * monster->getAnchorPoint().x))); + float y = OzgCCUtility::randomFloat(270 + (monster->getContentSize().height * monster->getAnchorPoint().y), 690 - (monster->getContentSize().height * monster->getAnchorPoint().y)); + + monster->setPosition(ccp(x, y)); + + for (int i = 0; i < (int)this->m_addedMonsters.size(); i++) + { + RPGBattleMonsterSprite *addedMonster = (RPGBattleMonsterSprite*)this->getChildByTag(this->m_addedMonsters[i]); + + if(addedMonster->boundingBox().intersectsRect(monster->boundingBox())) + { + overlap = true; +// CCLog("重新计算怪物的显示位置"); + break; + } + } + + } + while (overlap); + +} + +void RPGBattleSceneLayer::computingProgress() +{ +// CCLog("%f", this->m_speedTotal); + + //player + for (int i = 0; i < this->m_playerDataList->count(); i++) + { + RPGPlayer *playerData = (RPGPlayer*)this->m_playerDataList->objectAtIndex(i); + + CCProgressTimer *battleProgress = (CCProgressTimer*)this->getChildByTag(kRPGBattleSceneLayerTagPlayerProgress + playerData->m_dataId); + + float val = playerData->m_speed / this->m_speedTotal * 100.0; + playerData->m_progress = val; + battleProgress->setPercentage(playerData->m_progress); + } + + //monster +// for (int i = 0; i < this->m_monsterDataList->count(); i++) +// { +// CCArray *monsters = (CCArray*)this->m_monsterDataList->objectAtIndex(i); +// for (int j = 0; j < monsters->count(); j++) +// { +// RPGMonster *monsterData = (RPGMonster*)monsters->objectAtIndex(j); +// +// float val = monsterData->m_speed / this->m_speedTotal * 100.0; +// monsterData->m_progress = val; +// } +// } + +} + +float RPGBattleSceneLayer::computingFloat(float val) +{ + float min = val - (val * 0.1); + float max = val + (val * 0.1); + return OzgCCUtility::randomFloat(min, max); +} diff --git a/Classes/RPGBattleSceneLayer.h b/Classes/RPGBattleSceneLayer.h new file mode 100755 index 0000000..9367512 --- /dev/null +++ b/Classes/RPGBattleSceneLayer.h @@ -0,0 +1,84 @@ +// +// RPGBattleSceneLayer.h +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#ifndef __OzgGameRPG__RPGBattleSceneLayer__ +#define __OzgGameRPG__RPGBattleSceneLayer__ + +#include "RPGBaseSceneLayer.h" +#include "RPGBattlePlayerSprite.h" +#include "RPGBattleMonsterSprite.h" +#include "RPGBattleMenu.h" +#include "OzgCCUtility.h" + +enum RPGBattleSceneLayerTag +{ + kRPGBattleSceneLayerTagBg = 1, + kRPGBattleSceneLayerTagMenuBg = 2, + kRPGBattleSceneLayerTagBattleMenu = 3, + kRPGBattleSceneLayerTagMsg = 98, + kRPGBattleSceneLayerTagPlayer = 100, + kRPGBattleSceneLayerTagPlayerNameLab = 200, + kRPGBattleSceneLayerTagPlayerProgress = 300, + kRPGBattleSceneLayerTagPlayerProgressBg = 400, + kRPGBattleSceneLayerTagPlayerHP = 500, + kRPGBattleSceneLayerTagPlayerMP = 600, + kRPGBattleSceneLayerTagMonster = 10000, + kRPGBattleSceneLayerTagMonsterNameLab = 20000 + +}; + +class RPGBattleSceneLayer : public RPGBaseSceneLayer +{ + +private: + CCArray* m_playerDataList; + CCArray* m_monsterDataList; //因为同一个怪物会有N个,所以这个对象是二维的 + + CCArray* m_playerList; + CCArray* m_monsterList; //同m_monsterDataList + + vector m_addedMonsters; //已显示的怪物tag,主要用在setMonsterPosition + + float m_speedTotal; //所有战斗对象的速度加起来的总值,主要用在computingProgress + + bool m_autoReleaseMsg; //是否正在执行自动释放msg框 + + //对应的怪物的tag是否存在m_monsterDataList + bool monsterDataListExistWithTag(int tag); + + //获取对应怪物id的一组怪物,如果不存在则返回一个新的空数组 + CCArray* monsterDataListWithDataId(int dataId); + + void setMonsterPosition(RPGBattleMonsterSprite* monster); + + void computingProgress(); //计算战斗画面中的所有战斗对象的进度条 + float computingFloat(float val); //计算浮动值 + + + +public: + + RPGBattleSceneLayer(); + virtual ~RPGBattleSceneLayer(); + virtual bool init(); + CREATE_FUNC(RPGBattleSceneLayer); + + static CCScene* scene(); + + virtual void update(float delta); + + void showMsg(CCString* msgText); //显示msg + void showMsg(CCString* msgText, bool autoRelease); + void hideMsg(); + void hideMsg(float dt); + + void goToMap(); + +}; + +#endif /* defined(__OzgGameRPG__RPGBattleSceneLayer__) */ diff --git a/Classes/RPGConfirmLayer.cpp b/Classes/RPGConfirmLayer.cpp new file mode 100644 index 0000000..ed7383f --- /dev/null +++ b/Classes/RPGConfirmLayer.cpp @@ -0,0 +1,73 @@ +// +// RPGConfirmLayer.cpp +// OzgGameRPG +// +// Created by 欧志刚 on 14-3-30. +// +// + +#include "RPGConfirmLayer.h" +#include "OzgCCUtility.h" + +RPGConfirmLayer::RPGConfirmLayer() +{ + +} + +RPGConfirmLayer::~RPGConfirmLayer() +{ + +} + +bool RPGConfirmLayer::init(string titleStr, string menuOKStr, int menuItemOKTag, string menuCancelStr, int menuItemCancelTag, float width, float height, CCObject* target, SEL_MenuHandler seletor) +{ + if(CCLayerColor::initWithColor(ccc4(0, 0, 0, 200), width, height)) + { + CCTMXTiledMap *mainBg = CCTMXTiledMap::create("alert_style1.tmx"); + float x = (CCDirector::sharedDirector()->getWinSize().width - mainBg->getContentSize().width) / 2.0f; + float y = (CCDirector::sharedDirector()->getWinSize().height - mainBg->getContentSize().height) / 2.0f; + mainBg->setPosition(ccp(x, y)); + this->addChild(mainBg); + + CCLabelTTF *titleLab = CCLabelTTF::create(titleStr.c_str(), "Arial", 25, CCSizeMake(mainBg->getContentSize().width, 25), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + titleLab->setPosition(ccp(190, 135)); + titleLab->setColor(ccc3(255, 255, 255)); + mainBg->addChild(titleLab); + + CCMenu *menu = CCMenu::create(); + menu->setAnchorPoint(CCPointZero); + menu->setPosition(CCPointZero); + mainBg->addChild(menu); + + CCLabelTTF *menuOKLab = CCLabelTTF::create(OzgCCUtility::generalString(CCString::create(menuOKStr)->getCString()).c_str(), "Arial", 20, CCSizeMake(120, 25), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + menuOKLab->setColor(ccc3(160, 160, 160)); + CCMenuItemLabel *menuOK = CCMenuItemLabel::create(menuOKLab, target, seletor); + menuOK->setTag(menuItemOKTag); + menuOK->setPosition(ccp(100, 60)); + menu->addChild(menuOK); + + CCLabelTTF *menuCancelLab = CCLabelTTF::create(OzgCCUtility::generalString(CCString::create(menuCancelStr)->getCString()).c_str(), "Arial", 20, CCSizeMake(120, 25), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + menuCancelLab->setColor(ccc3(160, 160, 160)); + CCMenuItemLabel *menuCancel = CCMenuItemLabel::create(menuCancelLab, target, seletor); + menuCancel->setTag(menuItemCancelTag); + menuCancel->setPosition(ccp(280, 60)); + menu->addChild(menuCancel); + + return true; + } + + return false; +} + +RPGConfirmLayer* RPGConfirmLayer::create(string titleStr, string menuOKStr, int menuItemOKTag, string menuCancelStr, int menuItemCancelTag, float width, float height, CCObject* target, SEL_MenuHandler seletor) +{ + RPGConfirmLayer *layer = new RPGConfirmLayer(); + if(layer && layer->init(titleStr, menuOKStr, menuItemOKTag, menuCancelStr, menuItemCancelTag, width, height, target, seletor)) + { + layer->autorelease(); + + return layer; + } + CC_SAFE_DELETE(layer); + return NULL; +} diff --git a/Classes/RPGConfirmLayer.h b/Classes/RPGConfirmLayer.h new file mode 100644 index 0000000..1eeba58 --- /dev/null +++ b/Classes/RPGConfirmLayer.h @@ -0,0 +1,29 @@ +// +// RPGAlertLayer.h +// OzgGameRPG +// +// Created by 欧志刚 on 14-3-30. +// +// + +#ifndef __OzgGameRPG__RPGAlertLayer__ +#define __OzgGameRPG__RPGAlertLayer__ + +#include "cocos2d.h" + +USING_NS_CC; +using namespace std; + +class RPGConfirmLayer : public CCLayerColor +{ + +public: + + RPGConfirmLayer(); + virtual ~RPGConfirmLayer(); + bool init(string titleStr, string menuOKStr, int menuItemOKTag, string menuCancelStr, int menuItemCancelTag, float width, float height, CCObject* target, SEL_MenuHandler seletor); + static RPGConfirmLayer* create(string titleStr, string menuOKStr, int menuItemOKTag, string menuCancelStr, int menuItemCancelTag, float width, float height, CCObject* target, SEL_MenuHandler seletor); + +}; + +#endif /* defined(__OzgGameRPG__RPGAlertLayer__) */ diff --git a/Classes/RPGData.cpp b/Classes/RPGData.cpp new file mode 100644 index 0000000..1c172c0 --- /dev/null +++ b/Classes/RPGData.cpp @@ -0,0 +1,84 @@ +// +// RPGData.cpp +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-5. +// +// + +#include "RPGData.h" + +RPGPlayer::RPGPlayer() +{ + +} + +RPGPlayer::~RPGPlayer() +{ + CCLog("RPGPlayer 释放"); + +} + +RPGPlayer* RPGPlayer::create() +{ + RPGPlayer *obj = new RPGPlayer(); + if(obj) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +//RPGPlayer end + +RPGMonster::RPGMonster() +{ + +} + +RPGMonster::~RPGMonster() +{ + CCLog("RPGMonster 释放"); + +} + +RPGMonster* RPGMonster::create() +{ + RPGMonster *obj = new RPGMonster(); + if(obj) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +//RPGMonster end + +RPGSkill::RPGSkill() +{ + +} + +RPGSkill::~RPGSkill() +{ +// CCLog("RPGSkill 释放"); + +} + +RPGSkill* RPGSkill::create() +{ + RPGSkill *obj = new RPGSkill(); + if(obj) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +//RPGSkill end diff --git a/Classes/RPGData.h b/Classes/RPGData.h new file mode 100644 index 0000000..7e0cd6b --- /dev/null +++ b/Classes/RPGData.h @@ -0,0 +1,91 @@ +// +// RPGData.h +// OzgGameRPG +// +// Created by 欧志刚 on 14-4-5. +// +// + +#ifndef __OzgGameRPG__RPGData__ +#define __OzgGameRPG__RPGData__ + +#include "cocos2d.h" + +USING_NS_CC; +using namespace std; + +class RPGPlayer : public CCObject +{ + +public: + + int m_dataId; + string m_name; + int m_maxHP; + int m_HP; + int m_maxMP; + int m_MP; + float m_attack; + float m_defense; + float m_speed; + float m_magicAttack; + float m_magicDefense; + int m_itemsIdArms; + int m_itemsIdArmor; + int m_level; + string m_skill; + int m_nextExp; + string m_texPrefix; + + float m_progress; + + RPGPlayer(); + virtual ~RPGPlayer(); + + static RPGPlayer* create(); + +}; + +class RPGMonster : public CCObject +{ + +public: + + int m_dataId; + string m_name; + int m_maxHP; + int m_HP; //数据库里面没有这个字段 + float m_attack; + float m_defense; + float m_speed; + float m_magicAttack; + float m_magicDefense; + int m_exp; + string m_skill; + string m_tex; + + int m_tag; //格式为 enum tag + 0到999的无重复数(就算同一个怪物也不能重复) + + float m_progress; + + RPGMonster(); + virtual ~RPGMonster(); + + static RPGMonster* create(); + +}; + +class RPGSkill : public CCObject +{ + +public: + string m_name; + int m_mp; + + RPGSkill(); + virtual ~RPGSkill(); + + static RPGSkill* create(); +}; + +#endif /* defined(__OzgGameRPG__RPGData__) */ diff --git a/Classes/RPGLoadingSceneLayer.cpp b/Classes/RPGLoadingSceneLayer.cpp new file mode 100755 index 0000000..c4e5f26 --- /dev/null +++ b/Classes/RPGLoadingSceneLayer.cpp @@ -0,0 +1,140 @@ +// +// RPGLoadingSceneLayer.cpp +// RPG +// +// Created by 欧志刚 on 14-1-5. +// +// + +#include "RPGLoadingSceneLayer.h" +#include "RPGMapSceneLayer.h" +#include "RPGBattleSceneLayer.h" +#include "OzgCCUtility.h" + +RPGLoadingSceneLayer::~RPGLoadingSceneLayer() +{ + if(this->m_loadTextures) this->m_loadTextures->release(); + if(this->m_releaseTextures) this->m_releaseTextures->release(); + +// CCTextureCache::sharedTextureCache()->dumpCachedTextureInfo(); +} + +bool RPGLoadingSceneLayer::init(CCArray* loadTextures, CCArray* releaseTextures, string nextScene) +{ + if(RPGBaseSceneLayer::init()) + { + this->m_loadTextures = loadTextures; + this->m_releaseTextures = releaseTextures; + this->m_nextScene = nextScene; + + if(this->m_loadTextures) this->m_loadTextures->retain(); + if(this->m_releaseTextures) this->m_releaseTextures->retain(); + + //加载语言文件 + string languageFile = CCFileUtils::sharedFileUtils()->fullPathForFilename("scene_loading_cns.plist"); + + this->m_stringList = CCDictionary::createWithContentsOfFileThreadSafe(languageFile.c_str()); + + CCString *loadingStr = (CCString*)this->m_stringList->objectForKey("loading"); + CCLabelTTF *loadingLabel = CCLabelTTF::create(OzgCCUtility::generalString(loadingStr->getCString()).c_str(), "FZCuYuan-M03S", 20, CCSizeMake(CCDirector::sharedDirector()->getWinSize().width, 30), kCCTextAlignmentCenter); + + loadingLabel->setColor(ccc3(255, 255, 255)); + loadingLabel->setPosition(ccp(CCDirector::sharedDirector()->getWinSize().width / 2, 100)); + this->addChild(loadingLabel); + + if(!this->m_loadTextures) + this->scheduleOnce(schedule_selector(RPGLoadingSceneLayer::goToNextScene), GAME_SCENE + 0.5); + else + this->scheduleOnce(schedule_selector(RPGLoadingSceneLayer::executeLoading), GAME_SCENE + 0.5); + + return true; + } + return false; +} + +RPGLoadingSceneLayer* RPGLoadingSceneLayer::create(CCArray* loadTextures, CCArray* releaseTextures, string nextScene) +{ + RPGLoadingSceneLayer* layer = new RPGLoadingSceneLayer(); + if(layer && layer->init(loadTextures, releaseTextures, nextScene)) + { + layer->autorelease(); + return layer; + } + CC_SAFE_DELETE(layer); + return NULL; +} + +CCScene* RPGLoadingSceneLayer::scene(CCArray* loadTextures, CCArray* releaseTextures, string nextScene) +{ + CCScene *scene = CCScene::create(); + RPGLoadingSceneLayer *layer = RPGLoadingSceneLayer::create(loadTextures, releaseTextures, nextScene); + scene->addChild(layer); + return scene; +} + +void RPGLoadingSceneLayer::executeLoading(float delay) +{ + //释放旧纹理 + if(this->m_releaseTextures) + { + CCObject *item = NULL; + CCARRAY_FOREACH(this->m_releaseTextures, item) + { + CCString *releaseTexture = (CCString*)item; + CCTextureCache::sharedTextureCache()->removeTextureForKey(releaseTexture->getCString()); + + } + + } + + //读取新纹理 + if(this->m_loadTextures) + { + this->m_loadingIndex = 0; + CCString *loadTexture = (CCString*)this->m_loadTextures->objectAtIndex(this->m_loadingIndex); + CCTextureCache::sharedTextureCache()->addImageAsync(loadTexture->getCString(), this, callfuncO_selector(RPGLoadingSceneLayer::loadCallBack)); + } + else + this->goToNextScene(); + +} + +void RPGLoadingSceneLayer::loadCallBack(cocos2d::CCObject *sender) +{ + this->m_loadingIndex++; + if(this->m_loadingIndex >= this->m_loadTextures->count()) + { + //完毕 + //CCLog("loading 100%%"); + this->goToNextScene(); + } + else + { + //往下一个读取 + //int val = (int)((float)this->m_loadingIndex / (float)this->m_loadTextures->count() * 100.0f); + //CCLog("loading %i%%", val); + + CCString *loadTexture = (CCString*)this->m_loadTextures->objectAtIndex(this->m_loadingIndex); + CCTextureCache::sharedTextureCache()->addImageAsync(loadTexture->getCString(), this, callfuncO_selector(RPGLoadingSceneLayer::loadCallBack)); + } + +} + +void RPGLoadingSceneLayer::goToNextScene() +{ + //CCTextureCache::sharedTextureCache()->dumpCachedTextureInfo(); + CCScene *s = NULL; + + //跳转到目标场景 + if(this->m_nextScene.compare("single_map") == 0) + s = RPGMapSceneLayer::scene(); + else if(this->m_nextScene.compare("single_battle") == 0) + s = RPGBattleSceneLayer::scene(); + + if(s) + { + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); + } + +} diff --git a/Classes/RPGLoadingSceneLayer.h b/Classes/RPGLoadingSceneLayer.h new file mode 100755 index 0000000..86d6cf1 --- /dev/null +++ b/Classes/RPGLoadingSceneLayer.h @@ -0,0 +1,37 @@ +// +// RPGLoadingSceneLayer.h +// FantasyRPG +// +// Created by 欧志刚 on 14-1-5. +// +// + +#ifndef __FantasyRPG__RPGLoadingSceneLayer__ +#define __FantasyRPG__RPGLoadingSceneLayer__ + +#include "RPGBaseSceneLayer.h" + +USING_NS_CC; + +class RPGLoadingSceneLayer : public RPGBaseSceneLayer +{ + +private: + int m_loadingIndex; + CCArray* m_loadTextures; + CCArray* m_releaseTextures; + string m_nextScene; + +public: + virtual ~RPGLoadingSceneLayer(); + bool init(CCArray* loadTextures, CCArray* releaseTextures, string nextScene); + + static RPGLoadingSceneLayer* create(CCArray* loadTextures, CCArray* releaseTextures, string nextScene); + static CCScene* scene(CCArray* loadTextures, CCArray* releaseTextures, string nextScene); + + void executeLoading(float delay); + void loadCallBack(CCObject* sender); + void goToNextScene(); +}; + +#endif /* defined(__FantasyRPG__RPGLoadingSceneLayer__) */ diff --git a/Classes/RPGMapDialogLayer.cpp b/Classes/RPGMapDialogLayer.cpp new file mode 100644 index 0000000..6de658a --- /dev/null +++ b/Classes/RPGMapDialogLayer.cpp @@ -0,0 +1,85 @@ +// +// RPGMapDialogLayer.cpp +// OzgGameRPG +// +// Created by 欧志刚 on 14-3-31. +// +// + +#include "RPGMapDialogLayer.h" +#include "RPGMapSceneLayer.h" + +RPGMapDialogLayer::RPGMapDialogLayer() +{ + +} + +RPGMapDialogLayer::~RPGMapDialogLayer() +{ + this->m_npc->startAutoMove(); //继续执行自动移动 + this->m_npc->release(); + +// CCLog("RPGMapDialogLayer 释放"); +} + +bool RPGMapDialogLayer::init(RPGMapNPCRoleSprite* npc) +{ + if(CCLayer::init()) + { + this->m_npc = npc; + this->m_npc->retain(); + + CCTMXTiledMap *mainBg = CCTMXTiledMap::create("dialog_style1.tmx"); + float x = (CCDirector::sharedDirector()->getWinSize().width - mainBg->getContentSize().width) / 2.0f; + float y = 40; + mainBg->setPosition(ccp(x, y)); + this->addChild(mainBg); + + string text = " "; + text.append(npc->m_content->getCString()); + + CCLabelTTF *contentLab = CCLabelTTF::create(text.c_str(), "Arial", 25, CCSizeMake(mainBg->getContentSize().width - 20.0f, mainBg->getContentSize().height - 40.0f), kCCTextAlignmentLeft, kCCVerticalTextAlignmentTop); + contentLab->setPosition(ccp(mainBg->getContentSize().width / 2.0f + 35.0f, 125)); + this->addChild(contentLab); + + CCDirector::sharedDirector()->getTouchDispatcher()->addTargetedDelegate(this, 0, true); + + return true; + } + + return false; +} + +RPGMapDialogLayer* RPGMapDialogLayer::create(RPGMapNPCRoleSprite* npc) +{ + RPGMapDialogLayer *layer = new RPGMapDialogLayer(); + if(layer && layer->init(npc)) + { + layer->autorelease(); + + return layer; + } + return NULL; +} + +bool RPGMapDialogLayer::ccTouchBegan(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent) +{ + + return true; +} + +void RPGMapDialogLayer::ccTouchMoved(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent) +{ + +} + +void RPGMapDialogLayer::ccTouchEnded(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent) +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getParent()->getChildByTag(kRPGMapSceneLayerTagBgMap); + + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setVisible(true); + + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(this); + this->removeFromParentAndCleanup(true); +} diff --git a/Classes/RPGMapDialogLayer.h b/Classes/RPGMapDialogLayer.h new file mode 100644 index 0000000..ae7f0e2 --- /dev/null +++ b/Classes/RPGMapDialogLayer.h @@ -0,0 +1,37 @@ +// +// RPGMapDialogLayer.h +// OzgGameRPG +// +// Created by 欧志刚 on 14-3-31. +// +// + +#ifndef __OzgGameRPG__RPGMapDialogLayer__ +#define __OzgGameRPG__RPGMapDialogLayer__ + +#include "cocos2d.h" +#include "RPGMapNPCRoleSprite.h" + +USING_NS_CC; +using namespace std; + +class RPGMapDialogLayer : public CCLayer +{ + +private: + RPGMapNPCRoleSprite* m_npc; + +public: + + RPGMapDialogLayer(); + virtual ~RPGMapDialogLayer(); + bool init(RPGMapNPCRoleSprite* npc); + static RPGMapDialogLayer* create(RPGMapNPCRoleSprite* npc); + + bool ccTouchBegan(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent); + void ccTouchMoved(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent); + void ccTouchEnded(cocos2d::CCTouch *pTouch, cocos2d::CCEvent *pEvent); + +}; + +#endif /* defined(__OzgGameRPG__RPGMapDialogLayer__) */ diff --git a/Classes/RPGMapMenuLayer.cpp b/Classes/RPGMapMenuLayer.cpp new file mode 100755 index 0000000..0b739e9 --- /dev/null +++ b/Classes/RPGMapMenuLayer.cpp @@ -0,0 +1,625 @@ +// +// RPGMapMenuLayer.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#include "RPGMapMenuLayer.h" +#include "RPGMapSceneLayer.h" +#include "RPGConfirmLayer.h" +#include "RPGStartSceneLayer.h" +#include "JsonBox.h" +#include "OzgCCUtility.h" + +//获取一个player的详细数据 +#define PLAYER_QUERY_DETAIL "select p.*, arms.name_cns as arms_name, armor.name_cns as armor_name from player as p left join items as arms on p.items_id_arms = arms.id left join items as armor on p.items_id_armor = armor.id where p.id = %i" + +//查询一个角色的技能 +#define SKILL_QUERY "select * from skill where id in(%s)" + +RPGMapMenuLayer::RPGMapMenuLayer() +{ + +} + +RPGMapMenuLayer::~RPGMapMenuLayer() +{ + this->m_stringList->release(); + this->m_skillList->release(); + +// CCTextureCache::sharedTextureCache()->dumpCachedTextureInfo(); + +// CCLog("RPGMapMenuLayer释放"); +} + +bool RPGMapMenuLayer::init(CCDictionary* stringList, CppSQLite3DB* db, float width, float height) +{ + if(CCLayerColor::initWithColor(ccc4(0, 0, 0, 200), width, height)) + { + this->m_stringList = stringList; + this->m_stringList->retain(); + + this->m_skillList = new CCArray(); + this->m_skillList->init(); + + this->m_db = db; + + this->m_width = width; + this->m_height = height; + + this->m_statusIsDefault = true; + +// CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile("main.plist"); + + CCMenu *mainMenu = CCMenu::create(); + mainMenu->setTag(kRPGMapMenuLayerTagMainMenu); + mainMenu->setAnchorPoint(CCPointZero); + mainMenu->setPosition(CCPointZero); + this->addChild(mainMenu); + + this->setMainMenuDefault(); + + CCTMXTiledMap *mainBg = CCTMXTiledMap::create("map_menu1_style1.tmx"); + mainBg->setPosition(CCPointZero); + mainBg->setTag(kRPGMapMenuLayerTagMainBg); + this->addChild(mainBg); + + this->setDefaultInterface(); + + return true; + } + return false; +} + +RPGMapMenuLayer* RPGMapMenuLayer::create(CCDictionary* stringList, CppSQLite3DB* db, float width, float height) +{ + RPGMapMenuLayer *obj = new RPGMapMenuLayer(); + if(obj && obj->init(stringList, db, width, height)) + { + obj->autorelease(); + return obj; + } + + CC_SAFE_DELETE(obj); + return NULL; +} + +//private +void RPGMapMenuLayer::onMenu(cocos2d::CCObject *pObject) +{ + CCMenuItem *menuItem = (CCMenuItem*)pObject; + + //除默认显示角色数据之外,其他所有的点击都有效果音 + if(!(this->m_statusIsDefault && menuItem->getTag() == kRPGMapMenuLayerTagMainMenuPlayerStatus + 1)) + SimpleAudioEngine::sharedEngine()->playEffect("audio_effect_btn.wav"); + + switch (menuItem->getTag()) + { + case kRPGMapMenuLayerTagMainMenuEquip: + { + CCLog("装备"); + + } + break; + case kRPGMapMenuLayerTagMainMenuSkill: + { + CCLog("技能"); + + } + break; + case kRPGMapMenuLayerTagMainMenuStatus: + { +// CCLog("状态"); + this->m_statusIsDefault = true; + + this->removeDefaultInterface(); + this->removeChildByTag(kRPGMapMenuLayerTagMainBg, true); + + this->setMainMenuStatus(); + + CCTMXTiledMap *mainBg = CCTMXTiledMap::create("map_menu4_style1.tmx"); + mainBg->setPosition(CCPointZero); + mainBg->setTag(kRPGMapMenuLayerTagMainBg); + this->addChild(mainBg); + + this->setStatusInterface(); + } + break; + case kRPGMapMenuLayerTagMainMenuClose: + { +// CCLog("关闭"); + + RPGMapSceneLayer *mapSceneLayer = (RPGMapSceneLayer*)this->getParent(); + mapSceneLayer->enabledControl(true); + + this->removeFromParentAndCleanup(true); + + } + break; + case kRPGMapMenuLayerTagMainMenuExit: + { + //退出 + RPGConfirmLayer *confirm = RPGConfirmLayer::create(((CCString*)this->m_stringList->objectForKey("confirm_exit"))->getCString(), ((CCString*)this->m_stringList->objectForKey("confirm_exit_ok"))->getCString(), kRPGMapMenuLayerTagConfirmExitOK, ((CCString*)this->m_stringList->objectForKey("confirm_cancel"))->getCString(), kRPGMapMenuLayerTagConfirmCancel, this->m_width, this->m_height, this, menu_selector(RPGMapMenuLayer::onMenu)); + confirm->setTag(kRPGMapMenuLayerTagConfirm); + this->addChild(confirm); + + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + mainMenu->setEnabled(false); + + } + break; + case kRPGMapMenuLayerTagMainMenuStatusBack: + { + //在状态界面中按后退 + this->removeChildByTag(kRPGMapMenuLayerTagMainBg, true); + + this->setMainMenuDefault(); + this->setDefaultInterface(); + + CCTMXTiledMap *mainBg = CCTMXTiledMap::create("map_menu1_style1.tmx"); + mainBg->setPosition(CCPointZero); + mainBg->setTag(kRPGMapMenuLayerTagMainBg); + this->addChild(mainBg); + + //清理上面的4个角色 + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + CppSQLite3Query query = this->m_db->execQuery(PLAYER_QUERY); + while(!query.eof()) + { + CCMenuItemSprite *player = (CCMenuItemSprite*)mainMenu->getChildByTag(kRPGMapMenuLayerTagMainMenuPlayerStatus + query.getIntField("id")); + if(player) + player->removeFromParentAndCleanup(true); + + CCTextureCache::sharedTextureCache()->removeTextureForKey(CCString::createWithFormat("%s_0.png", query.getStringField("tex_prefix"))->getCString()); + + query.nextRow(); + } + query.finalize(); + + //清理各个lab部分 + this->removeAllStatusPlayerLab(); + + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerSkillTable, true); + this->m_skillList->removeAllObjects(); + + //清理光标 + this->removeChildByTag(kRPGMapMenuLayerTagHandCursor, true); + } + break; + case kRPGMapMenuLayerTagConfirmExitOK: + { + //确定退出 + RPGMapSceneLayer *mapSceneLayer = (RPGMapSceneLayer*)this->getParent(); + mapSceneLayer->m_releaseTexture = true; + + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(mapSceneLayer); + mapSceneLayer->unscheduleUpdate(); + + SimpleAudioEngine::sharedEngine()->stopBackgroundMusic(true); + + CCScene *s = RPGStartSceneLayer::scene(); + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); + } + break; + case kRPGMapMenuLayerTagConfirmCancel: + { + this->removeChildByTag(kRPGMapMenuLayerTagConfirm, true); + + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + mainMenu->setEnabled(true); + } + break; + case kRPGMapMenuLayerTagMainMenuItems: + { + CCLog("道具"); + + } + break; + } + + //player status + if(menuItem->getTag() >= kRPGMapMenuLayerTagMainMenuPlayerStatus && menuItem->getTag() <= kRPGMapMenuLayerTagMainMenuPlayerStatus + 99) + { + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + + CppSQLite3Query query = this->m_db->execQuery(PLAYER_QUERY); + while(!query.eof()) + { + if(menuItem->getTag() == kRPGMapMenuLayerTagMainMenuPlayerStatus + query.getIntField("id")) + { + this->removeAllStatusPlayerLab(); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerSkillTable)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerSkillTable, true); + this->m_skillList->removeAllObjects(); + + this->m_statusIsDefault = false; + +// CCLog("选中了id为%i的角色", query.getIntField("id")); + int dataId = query.getIntField("id"); + this->setStatusPlayer(dataId); + CCMenuItemSprite *player = (CCMenuItemSprite*)mainMenu->getChildByTag(kRPGMapMenuLayerTagMainMenuPlayerStatus + dataId); + + //光标的位置 + CCSprite *handCursor = (CCSprite*)this->getChildByTag(kRPGMapMenuLayerTagHandCursor); + if(!handCursor) + { + handCursor = CCSprite::createWithSpriteFrameName("gui_hand.png"); + handCursor->setScale(0.3); + handCursor->setTag(kRPGMapMenuLayerTagHandCursor); + this->addChild(handCursor); + } + handCursor->setPosition(ccp(player->getPositionX() + 60, 555)); + + break; + } + query.nextRow(); + } + query.finalize(); + } + +} + +void RPGMapMenuLayer::createMenuItem(float x, float y, CCString *text, RPGMapMenuLayerTag tag) +{ + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + + CCMenuItemLabel *menuItems = (CCMenuItemLabel*)mainMenu->getChildByTag(tag); + if(!menuItems) + { + CCLabelTTF *menuItemsLabel = CCLabelTTF::create(OzgCCUtility::generalString(text->getCString()).c_str(), "FZCuYuan-M03S", 25, CCSizeMake(120, 40), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + + CCMenuItemLabel *menuItems = CCMenuItemLabel::create(menuItemsLabel, this, menu_selector(RPGMapMenuLayer::onMenu)); + menuItems->setPosition(ccp(x, y)); + menuItems->setTag(tag); + mainMenu->addChild(menuItems); + + } +} + +void RPGMapMenuLayer::setMainMenuDefault() +{ + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + + CCString *menuItemsStr = (CCString*)this->m_stringList->objectForKey("menu_items"); + this->createMenuItem(835, 570, menuItemsStr, kRPGMapMenuLayerTagMainMenuItems); + + CCString *menuEquipStr = (CCString*)this->m_stringList->objectForKey("menu_equip"); + this->createMenuItem(835, 500, menuEquipStr, kRPGMapMenuLayerTagMainMenuEquip); + + CCString *menuSkillStr = (CCString*)this->m_stringList->objectForKey("menu_skill"); + this->createMenuItem(835, 430, menuSkillStr, kRPGMapMenuLayerTagMainMenuSkill); + + CCString *menuStatusStr = (CCString*)this->m_stringList->objectForKey("menu_status"); + this->createMenuItem(835, 360, menuStatusStr, kRPGMapMenuLayerTagMainMenuStatus); + + CCString *menuCloseStr = (CCString*)this->m_stringList->objectForKey("menu_close"); + this->createMenuItem(835, 290, menuCloseStr, kRPGMapMenuLayerTagMainMenuClose); + + CCString *menuExitStr = (CCString*)this->m_stringList->objectForKey("menu_exit"); + this->createMenuItem(835, 220, menuExitStr, kRPGMapMenuLayerTagMainMenuExit); + + CCObject *item = NULL; + CCARRAY_FOREACH(mainMenu->getChildren(), item) + { + CCMenuItem *menuItem = (CCMenuItem*)item; + + if(menuItem->getTag() == kRPGMapMenuLayerTagMainMenuItems || + menuItem->getTag() == kRPGMapMenuLayerTagMainMenuEquip || + menuItem->getTag() == kRPGMapMenuLayerTagMainMenuSkill || + menuItem->getTag() == kRPGMapMenuLayerTagMainMenuStatus || + menuItem->getTag() == kRPGMapMenuLayerTagMainMenuClose || + menuItem->getTag() == kRPGMapMenuLayerTagMainMenuExit) + menuItem->setVisible(true); + else + menuItem->setVisible(false); + + } +} + +void RPGMapMenuLayer::setMainMenuStatus() +{ + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + + CCMenuItemSprite *menuBack = (CCMenuItemSprite*)mainMenu->getChildByTag(kRPGMapMenuLayerTagMainMenuStatusBack); + if(!menuBack) + { + menuBack = CCMenuItemSprite::create(CCSprite::createWithSpriteFrameName("commons_btn_back_04.png"), CCSprite::createWithSpriteFrameName("commons_btn_back_04.png"), this, menu_selector(RPGMapMenuLayer::onMenu)); + menuBack->setPosition(ccp(40, 600)); + menuBack->setTag(kRPGMapMenuLayerTagMainMenuStatusBack); + menuBack->setScale(0.5); + mainMenu->addChild(menuBack); + + } + + CCObject *item = NULL; + CCARRAY_FOREACH(mainMenu->getChildren(), item) + { + CCMenuItem *menuItem = (CCMenuItem*)item; + + if(menuItem->getTag() == kRPGMapMenuLayerTagMainMenuStatusBack) + menuItem->setVisible(true); + else + menuItem->setVisible(false); + + } +} + +void RPGMapMenuLayer::setDefaultInterface() +{ + + //显示上面的4个角色 + float playerY = 550; + float nameY = 547; + float levelY = 568; + float hpY = 543; + float mpY = 523; + + CppSQLite3Query query = this->m_db->execQuery(PLAYER_QUERY); + while(!query.eof()) + { + CCArray *frames = OzgCCUtility::createSpriteFrames(CCString::createWithFormat("%s_0.png", query.getStringField("tex_prefix"))->getCString(), 3, 4); + + CCSprite *playerSprite = CCSprite::createWithSpriteFrame((CCSpriteFrame*)frames->objectAtIndex(1)); + playerSprite->setPosition(ccp(150, playerY)); + playerSprite->setScale(2); + playerSprite->setTag(kRPGMapMenuLayerTagDefualtPlayerTex + query.getIntField("id")); + this->addChild(playerSprite); + + addLab(this, kRPGMapMenuLayerTagDefualtPlayerName + query.getIntField("id"), CCString::create(query.getStringField("name_cns")), 22, ccp(410, nameY)); + + addLab(this, kRPGMapMenuLayerTagDefualtPlayerLevel + query.getIntField("id"), CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_level"))->getCString(), query.getIntField("level"), query.getIntField("next_exp")), 18, ccp(580, levelY)); + + addLab(this, kRPGMapMenuLayerTagDefualtPlayerHP + query.getIntField("id"), CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_hp"))->getCString(), query.getIntField("hp"), query.getIntField("max_hp")), 16, ccp(601, hpY)); + + addLab(this, kRPGMapMenuLayerTagDefualtPlayerMP + query.getIntField("id"), CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_mp"))->getCString(), query.getIntField("mp"), query.getIntField("max_mp")), 16, ccp(599, mpY)); + + playerY -= 150; + nameY -= 150; + levelY -= 150; + hpY -= 150; + mpY -= 150; + + query.nextRow(); + } + query.finalize(); + +} + +void RPGMapMenuLayer::removeDefaultInterface() +{ + CppSQLite3Query query = this->m_db->execQuery(PLAYER_QUERY); + while(!query.eof()) + { + + CCSprite *playerSprite = (CCSprite*)this->getChildByTag(kRPGMapMenuLayerTagDefualtPlayerTex + query.getIntField("id")); + if(playerSprite) + playerSprite->removeFromParentAndCleanup(true); + + CCLabelTTF *nameLab = (CCLabelTTF*)this->getChildByTag(kRPGMapMenuLayerTagDefualtPlayerName + query.getIntField("id")); + if(nameLab) + nameLab->removeFromParentAndCleanup(true); + + CCLabelTTF *levelLab = (CCLabelTTF*)this->getChildByTag(kRPGMapMenuLayerTagDefualtPlayerLevel + query.getIntField("id")); + if(levelLab) + levelLab->removeFromParentAndCleanup(true); + + CCLabelTTF *hpLab = (CCLabelTTF*)this->getChildByTag(kRPGMapMenuLayerTagDefualtPlayerHP + query.getIntField("id")); + if(hpLab) + hpLab->removeFromParentAndCleanup(true); + + CCLabelTTF *mpLab = (CCLabelTTF*)this->getChildByTag(kRPGMapMenuLayerTagDefualtPlayerMP + query.getIntField("id")); + if(mpLab) + mpLab->removeFromParentAndCleanup(true); + + query.nextRow(); + } + query.finalize(); + +} + +void RPGMapMenuLayer::setStatusInterface() +{ + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGMapMenuLayerTagMainMenu); + + //显示上面的4个角色 + float playerX = 200; + CppSQLite3Query query = this->m_db->execQuery(PLAYER_QUERY); + while(!query.eof()) + { + CCArray *frames = OzgCCUtility::createSpriteFrames(CCString::createWithFormat("%s_0.png", query.getStringField("tex_prefix"))->getCString(), 3, 4); + + CCSprite *playerSprite = CCSprite::createWithSpriteFrame((CCSpriteFrame*)frames->objectAtIndex(1)); + CCMenuItemSprite *player = (CCMenuItemSprite*)mainMenu->getChildByTag(kRPGMapMenuLayerTagMainMenuPlayerStatus + query.getIntField("id")); + if(!player) + { + player = CCMenuItemSprite::create(playerSprite, playerSprite, this, menu_selector(RPGMapMenuLayer::onMenu)); + player->cocos2d::CCNode::setPosition(ccp(playerX, 560)); + player->setScale(2); + player->setTag(kRPGMapMenuLayerTagMainMenuPlayerStatus + query.getIntField("id")); + mainMenu->addChild(player); + } + + playerX += 200; + query.nextRow(); + } + query.finalize(); + + //默认选中第一个 + this->onMenu(mainMenu->getChildByTag(kRPGMapMenuLayerTagMainMenuPlayerStatus + 1)); +} + +void RPGMapMenuLayer::setStatusPlayer(int dataId) +{ + CppSQLite3Query query = this->m_db->execQuery(CCString::createWithFormat(PLAYER_QUERY_DETAIL, dataId)->getCString()); + while(!query.eof()) + { + //左边 + addLab(this, kRPGMapMenuLayerTagStatusPlayerName, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_name"))->getCString(), query.getStringField("name_cns")), ccp(250, 410)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerLevel, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_level"))->getCString(), query.getIntField("level"), query.getIntField("next_exp")), ccp(243, 370)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerHP, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_hp"))->getCString(), query.getIntField("hp"), query.getIntField("max_hp")), ccp(262, 330)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerMP, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_mp"))->getCString(), query.getIntField("mp"), query.getIntField("max_mp")), ccp(259, 290)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerAttack, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_attack"))->getCString(), query.getIntField("attack")), ccp(249, 250)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerDefense, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_defense"))->getCString(), query.getIntField("defense")), ccp(249, 210)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerSpeed, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_speed"))->getCString(), query.getIntField("speed")), ccp(249, 170)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerMagicAttack, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_magic_attack"))->getCString(), query.getIntField("magic_attack")), ccp(249, 130)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerMagicDefense, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_magic_defense"))->getCString(), query.getIntField("magic_defense")), ccp(249, 90)); + + //右边装备部分 + addLab(this, kRPGMapMenuLayerTagStatusPlayerEquipArms, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_equip_arms"))->getCString(), query.getStringField("arms_name")), ccp(570, 410)); + addLab(this, kRPGMapMenuLayerTagStatusPlayerEquipArmor, CCString::createWithFormat(((CCString*)this->m_stringList->objectForKey("status_equip_armor"))->getCString(), query.getStringField("armor_name")), ccp(570, 370)); + + //右边技能部分 + + //数据处理部分 + this->m_skillList->removeAllObjects(); + string wq = ""; + JsonBox::Value json; + json.loadFromString(query.getStringField("skill")); + JsonBox::Array jsonArr = json.getArray(); + for (int i = 0; i < jsonArr.size(); i++) + { + char* str = (char*)malloc(10 * sizeof(char)); + OzgCCUtility::itoa(jsonArr[i].getInt(), str); + wq.append(str); + + if(i + 1 < jsonArr.size()) + wq.append(", "); + + free(str); + } + if((int)wq.length() > 0) + { + CppSQLite3Query skillQuery = this->m_db->execQuery(CCString::createWithFormat(SKILL_QUERY, wq.c_str())->getCString()); + while(!skillQuery.eof()) + { + RPGSkill *skill = RPGSkill::create(); + skill->m_name = skillQuery.getStringField("name_cns"); + skill->m_mp = skillQuery.getIntField("mp"); + + this->m_skillList->addObject(skill); + + skillQuery.nextRow(); + } + skillQuery.finalize(); + } + + CCTableView *tableView = CCTableView::create(this, CCSizeMake(600, 265)); + tableView->setDirection(kCCScrollViewDirectionVertical); + tableView->setPosition(ccp(340, 20)); + tableView->setDelegate(this); + tableView->setVerticalFillOrder(kCCTableViewFillTopDown); + tableView->setTag(kRPGMapMenuLayerTagStatusPlayerSkillTable); + this->addChild(tableView); + tableView->reloadData(); + + query.nextRow(); + } + query.finalize(); + +} + +void RPGMapMenuLayer::removeAllStatusPlayerLab() +{ + //清理各个lab部分 + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerName)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerName, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerLevel)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerLevel, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerHP)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerHP, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerMP)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerMP, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerAttack)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerAttack, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerDefense)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerDefense, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerSpeed)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerSpeed, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerMagicAttack)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerMagicAttack, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerMagicDefense)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerMagicDefense, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerEquipArms)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerEquipArms, true); + + if(this->getChildByTag(kRPGMapMenuLayerTagStatusPlayerEquipArmor)) + this->removeChildByTag(kRPGMapMenuLayerTagStatusPlayerEquipArmor, true); +} + +//CCTableView +void RPGMapMenuLayer::scrollViewDidScroll(CCScrollView *scrollView) +{ + +} + +void RPGMapMenuLayer::scrollViewDidZoom(CCScrollView *scrollView) +{ + +} + +void RPGMapMenuLayer::tableCellTouched(CCTableView *tableView, CCTableViewCell *cell) +{ + +} + +CCSize RPGMapMenuLayer::cellSizeForTable(CCTableView *tableView) +{ + return CCSizeMake(tableView->getContentSize().width, 80); +} + +CCTableViewCell* RPGMapMenuLayer::tableCellAtIndex(CCTableView *tableView, unsigned int idx) +{ + CCTableViewCell *cell = tableView->dequeueCell(); + if (!cell) + { + cell = new CCTableViewCell(); + cell->autorelease(); + } + else + cell->removeAllChildrenWithCleanup(true); + + float x = 150; + for (int i = 0; i < 3; i++) + { + int index = idx * 3 + i; + + if(index >= this->m_skillList->count()) + break; + + RPGSkill *skillData = (RPGSkill*)this->m_skillList->objectAtIndex(index); + + CCLabelTTF *textLab = CCLabelTTF::create(CCString::createWithFormat("%s (%i)", skillData->m_name.c_str(), skillData->m_mp)->getCString(), "Arial", 20, CCSizeMake(200, 25), kCCTextAlignmentLeft); + textLab->setPosition(ccp(x, 0)); + cell->addChild(textLab); + + x += 200; + } + + return cell; +} + +unsigned int RPGMapMenuLayer::numberOfCellsInTableView(CCTableView *tableView) +{ + int rowItemCount = 3; + int size = this->m_skillList->count(); + + if(size % rowItemCount == 0) + return size / rowItemCount; + else + return size / rowItemCount + 1; +} + +//CCTableView end diff --git a/Classes/RPGMapMenuLayer.h b/Classes/RPGMapMenuLayer.h new file mode 100755 index 0000000..8827591 --- /dev/null +++ b/Classes/RPGMapMenuLayer.h @@ -0,0 +1,108 @@ +// +// RPGMapMenuLayer.h +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#ifndef __OzgGameRPG__RPGMapMenuLayer__ +#define __OzgGameRPG__RPGMapMenuLayer__ + +#include "cocos2d.h" +#include "cocos-ext.h" +#include "CppSQLite3.h" +#include "JsonBox.h" +#include "RPGMapRoleSprite.h" +#include "RPGBaseSceneLayer.h" + +USING_NS_CC; +USING_NS_CC_EXT; + +enum RPGMapMenuLayerTag +{ + kRPGMapMenuLayerTagMainBg = 1, + kRPGMapMenuLayerTagMainMenu = 2, + kRPGMapMenuLayerTagMainMenuItems = 3, + kRPGMapMenuLayerTagMainMenuEquip = 4, + kRPGMapMenuLayerTagMainMenuSkill = 5, + kRPGMapMenuLayerTagMainMenuStatus = 6, + kRPGMapMenuLayerTagMainMenuClose = 7, + kRPGMapMenuLayerTagMainMenuExit = 8, + kRPGMapMenuLayerTagMainMenuStatusBack = 12, + kRPGMapMenuLayerTagMainMenuPlayerStatus = 100, + kRPGMapMenuLayerTagHandCursor = 22, + kRPGMapMenuLayerTagConfirmExitOK = 9, + kRPGMapMenuLayerTagConfirmCancel = 10, + kRPGMapMenuLayerTagConfirm = 11, + kRPGMapMenuLayerTagStatusPlayerName = 13, + kRPGMapMenuLayerTagStatusPlayerLevel = 14, + kRPGMapMenuLayerTagStatusPlayerHP = 15, + kRPGMapMenuLayerTagStatusPlayerMP = 16, + kRPGMapMenuLayerTagStatusPlayerAttack = 17, + kRPGMapMenuLayerTagStatusPlayerDefense = 18, + kRPGMapMenuLayerTagStatusPlayerSpeed = 19, + kRPGMapMenuLayerTagStatusPlayerMagicAttack = 20, + kRPGMapMenuLayerTagStatusPlayerMagicDefense = 21, + kRPGMapMenuLayerTagStatusPlayerEquipArms = 23, + kRPGMapMenuLayerTagStatusPlayerEquipArmor = 24, + kRPGMapMenuLayerTagStatusPlayerSkillTable = 25, + kRPGMapMenuLayerTagDefualtPlayerTex = 200, + kRPGMapMenuLayerTagDefualtPlayerName = 300, + kRPGMapMenuLayerTagDefualtPlayerLevel = 400, + kRPGMapMenuLayerTagDefualtPlayerHP = 500, + kRPGMapMenuLayerTagDefualtPlayerMP = 600 + +}; + +class RPGMapMenuLayer : public CCLayerColor, public CCTableViewDelegate, public CCTableViewDataSource +{ + +private: + + CCArray* m_skillList; //状态界面的技能列表 + + CCDictionary* m_stringList; + CppSQLite3DB* m_db; + + float m_width; + float m_height; + + bool m_statusIsDefault; //是否为第一次进入状态界面,如果是的话就不播放效果音了 + + void onMenu(CCObject *pObject); + void createMenuItem(float x, float y, CCString *text, RPGMapMenuLayerTag tag); + + void setMainMenuDefault(); //默认 + void setMainMenuStatus(); //状态 + + void setDefaultInterface(); //显示默认界面 + void removeDefaultInterface(); //清理默认界面 + + void setStatusInterface(); //显示状态界面 + void setStatusPlayer(int dataId); //显示状态界面的player数据部分 + void removeAllStatusPlayerLab(); //清理所有状态界面的lab + +public: + + RPGMapMenuLayer(); + virtual ~RPGMapMenuLayer(); + bool init(CCDictionary* stringList, CppSQLite3DB* db, float width, float height); + static RPGMapMenuLayer* create(CCDictionary* stringList, CppSQLite3DB* db, float width, float height); + + //CCTableViewDelegate继承自CCScrollViewDelegate + virtual void scrollViewDidScroll(CCScrollView* scrollView); + virtual void scrollViewDidZoom(CCScrollView* scrollView); + + //点击哪个cell + virtual void tableCellTouched(CCTableView* tableView, CCTableViewCell* cell); + //每个cell的size + virtual CCSize cellSizeForTable(CCTableView *tableView); + //生成cell + virtual CCTableViewCell* tableCellAtIndex(CCTableView *tableView, unsigned int idx); + //cell的数量 + virtual unsigned int numberOfCellsInTableView(CCTableView *tableView); + +}; + +#endif /* defined(__OzgGameRPG__RPGMapMenuLayer__) */ diff --git a/Classes/RPGMapNPCRoleSprite.cpp b/Classes/RPGMapNPCRoleSprite.cpp new file mode 100755 index 0000000..e0f34be --- /dev/null +++ b/Classes/RPGMapNPCRoleSprite.cpp @@ -0,0 +1,151 @@ +// +// RPGMapNPCRoleSprite.cpp +// FantasyRPG +// +// Created by 欧志刚 on 14-1-17. +// +// + +#include "RPGMapNPCRoleSprite.h" +#include "OzgCCUtility.h" +#include "GameCfg.h" + +RPGMapNPCRoleSprite::~RPGMapNPCRoleSprite() +{ + this->m_content->release(); + +// CCLog("RPGMapNPCRoleSprite 释放"); +} + +bool RPGMapNPCRoleSprite::init(CCString *roleTexture, CCString* headTexture, CCString* name, CCString* content, int defaultSpriteFrameIndex, bool autoMove) +{ + if(RPGMapRoleSprite::init(roleTexture, name, false, defaultSpriteFrameIndex)) + { + this->m_autoMove = autoMove; + + this->m_content = content; + this->m_content->retain(); + + this->startAutoMove(); + + this->m_type = kRPGMapRoleSpriteTypeNPC; + + return true; + } + return false; +} + +//static +RPGMapNPCRoleSprite* RPGMapNPCRoleSprite::create(CCString *roleTexture, CCString* headTexture, CCString* name, CCString* content, int defaultSpriteFrameIndex, bool autoMove) +{ + RPGMapNPCRoleSprite *obj = new RPGMapNPCRoleSprite(); + if(obj && obj->init(roleTexture, headTexture, name, content, defaultSpriteFrameIndex, autoMove)) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +//private +void RPGMapNPCRoleSprite::autoMove(float delay) +{ + //这里的逻辑跟RPGSingleModeMapSceneLayer::doMoving类似 + + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getParent(); + CCTMXObjectGroup *obstaclesObjects = bgMap->objectGroupNamed("obstacles"); + + bool doMoving; + CCPoint point; + + //每一次重新将doMoving改为true,然后执行各个判断逻辑,直到doMoving不会改变为false为止 + + do + { + doMoving = true; + + float val = CCRANDOM_0_1(); + if(val >= 0.0 && val <= 0.25) + { + this->startMoveUp(); + point = ccp(0, GAME_TMX_ROLE_HEIGHT); + } + else if(val > 0.25 && val <= 0.5) + { + this->startMoveDown(); + point = ccp(0, -GAME_TMX_ROLE_HEIGHT); + } + else if(val > 0.5 && val <= 0.75) + { + this->startMoveLeft(); + point = ccp(-GAME_TMX_ROLE_WIDTH, 0); + } + else + { + this->startMoveRight(); + point = ccp(GAME_TMX_ROLE_WIDTH, 0); + } + + CCPoint targetPoint = ccpAdd(this->getPosition(), point); + + //地图上的障碍物 + for (int i = 0; i < obstaclesObjects->getObjects()->count(); i++) + { + CCDictionary *obstaclesObject = (CCDictionary*)obstaclesObjects->getObjects()->objectAtIndex(i); + const CCString *x = obstaclesObject->valueForKey("x"); + const CCString *y = obstaclesObject->valueForKey("y"); + const CCString *width = obstaclesObject->valueForKey("width"); + const CCString *height = obstaclesObject->valueForKey("height"); + + CCRect obstaclesRect = CCRectMake(stringToNumber(x->getCString()), stringToNumber(y->getCString()), stringToNumber(width->getCString()), stringToNumber(height->getCString())); + + if(obstaclesRect.containsPoint(targetPoint)) + doMoving = false; + + } + + //NPC或Player + for (int i = 0; i < bgMap->getChildren()->count(); i++) + { + CCObject *item = bgMap->getChildren()->objectAtIndex(i); + if(dynamic_cast(item) != NULL) + { + //如果为非自己的对象才会执行里面的判断 + if(item != this) + { + if(((RPGMapRoleSprite*)item)->boundingBox().containsPoint(targetPoint)) + doMoving = false; + } + } + } + + } + while (!doMoving); + + this->runAction(CCSequence::createWithTwoActions(CCMoveBy::create(0.5, point), CCCallFunc::create(this, callfunc_selector(RPGMapNPCRoleSprite::autoMoveEnd)))); + +} + +void RPGMapNPCRoleSprite::stopAutoMove() +{ + + this->unschedule(schedule_selector(RPGMapNPCRoleSprite::autoMove)); +} + +void RPGMapNPCRoleSprite::startAutoMove() +{ + if(this->m_autoMove) + { + float audoMoveTime = OzgCCUtility::randomFloat(1.0, 5.0); + this->scheduleOnce(schedule_selector(RPGMapNPCRoleSprite::autoMove), audoMoveTime); + } +} + +//private +void RPGMapNPCRoleSprite::autoMoveEnd() +{ + this->stopMove(); + + this->startAutoMove(); +} diff --git a/Classes/RPGMapNPCRoleSprite.h b/Classes/RPGMapNPCRoleSprite.h new file mode 100755 index 0000000..02ce380 --- /dev/null +++ b/Classes/RPGMapNPCRoleSprite.h @@ -0,0 +1,36 @@ +// +// RPGMapNPCRoleSprite.h +// FantasyRPG +// +// Created by 欧志刚 on 14-1-17. +// +// + +#ifndef __FantasyRPG__RPGMapNPCRoleSprite__ +#define __FantasyRPG__RPGMapNPCRoleSprite__ + +#include "RPGMapRoleSprite.h" + +class RPGMapNPCRoleSprite : public RPGMapRoleSprite +{ + +private: + bool m_autoMove = false; + + void autoMove(float delay); + void autoMoveEnd(); + +public: + + CCString* m_content; + + virtual ~RPGMapNPCRoleSprite(); + virtual bool init(CCString *roleTexture, CCString* headTexture, CCString* name, CCString* content, int defaultSpriteFrameIndex, bool autoMove); + static RPGMapNPCRoleSprite* create(CCString *roleTexture, CCString* headTexture, CCString* name, CCString* content, int defaultSpriteFrameIndex, bool autoMove); + + void stopAutoMove(); + void startAutoMove(); + +}; + +#endif /* defined(__FantasyRPG__RPGMapNPCRoleSprite__) */ diff --git a/Classes/RPGMapRoleSprite.cpp b/Classes/RPGMapRoleSprite.cpp new file mode 100755 index 0000000..406638d --- /dev/null +++ b/Classes/RPGMapRoleSprite.cpp @@ -0,0 +1,220 @@ +// +// RPGMapRoleSprite.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#include "RPGMapRoleSprite.h" +#include "OzgCCUtility.h" + +#define MOVE_ACT 0.25 //行走动画的下一帧时间 + +RPGMapRoleSprite::~RPGMapRoleSprite() +{ + if(this->m_roleSpriteFrames) this->m_roleSpriteFrames->release(); + this->m_name->release(); + + CCLog("RPGMapRoleSprite 释放"); +} + +bool RPGMapRoleSprite::init(CCString *roleTexture, CCString* name, bool isPlayer, int defaultSpriteFrameIndex) +{ + this->m_roleSpriteFrames = OzgCCUtility::createSpriteFrames(roleTexture->getCString(), 3, 4); + this->m_roleSpriteFrames->retain(); + + this->m_name = name; + this->m_name->retain(); + + this->m_isPlayer = isPlayer; + + if(CCSprite::initWithSpriteFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(defaultSpriteFrameIndex))) + { + CCLabelTTF *nameLab = CCLabelTTF::create(this->m_name->getCString(), "Arial", 15, CCSizeMake(this->getContentSize().width * 2.0, 20), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + nameLab->setPosition(ccp(15, 45)); + + if(this->m_isPlayer) + nameLab->setColor(ccc3(255, 50, 40)); + else + nameLab->setColor(ccc3(0, 0, 0)); + + this->addChild(nameLab); + + this->m_direction = kRPGMapRoleSpriteDirectionNone; + + return true; + } + + this->m_roleSpriteFrames->release(); + return false; +} + +//static +RPGMapRoleSprite* RPGMapRoleSprite::create(CCString *roleTexture, CCString* name, bool isPlayer, int defaultSpriteFrameIndex) +{ + RPGMapRoleSprite *obj = new RPGMapRoleSprite(); + if(obj && obj->init(roleTexture, name, isPlayer, defaultSpriteFrameIndex)) + { + obj->autorelease(); + return obj; + } + CC_SAFE_DELETE(obj); + return NULL; +} + +////private +void RPGMapRoleSprite::startMove(RPGMapRoleSpriteMoveActTag actTag) +{ + if(this->m_isMoving && this->m_currMoveActTag != actTag) + { + this->stopActionByTag(this->m_currMoveActTag); + this->m_isMoving = false; + } + + if(!this->m_isMoving) + { + CCArray *spriteFrames = CCArray::create(); + + switch (actTag) + { + case kRPGMapRoleSpriteMoveActTagUp: + { + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(9)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(10)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(11)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(10)); + + this->m_direction = kRPGMapRoleSpriteDirectionUp; + } + break; + case kRPGMapRoleSpriteMoveActTagDown: + { + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(0)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(1)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(2)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(1)); + + this->m_direction = kRPGMapRoleSpriteDirectionDown; + } + break; + case kRPGMapRoleSpriteMoveActTagLeft: + { + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(3)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(4)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(5)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(4)); + + this->m_direction = kRPGMapRoleSpriteDirectionLeft; + } + break; + case kRPGMapRoleSpriteMoveActTagRight: + { + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(6)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(7)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(8)); + spriteFrames->addObject(this->m_roleSpriteFrames->objectAtIndex(7)); + + this->m_direction = kRPGMapRoleSpriteDirectionRight; + } + break; + default: + break; + } + + CCAnimation *animation = CCAnimation::createWithSpriteFrames(spriteFrames, MOVE_ACT); + CCRepeatForever *animate = CCRepeatForever::create(CCAnimate::create(animation)); + animate->setTag(actTag); + this->m_currMoveActTag = actTag; + + this->runAction(animate); + + this->m_isMoving = true; + } +} + +void RPGMapRoleSprite::startMoveUp() +{ + this->startMove(kRPGMapRoleSpriteMoveActTagUp); + +} + +void RPGMapRoleSprite::startMoveDown() +{ + this->startMove(kRPGMapRoleSpriteMoveActTagDown); + +} + +void RPGMapRoleSprite::startMoveLeft() +{ + this->startMove(kRPGMapRoleSpriteMoveActTagLeft); + +} + +void RPGMapRoleSprite::startMoveRight() +{ + this->startMove(kRPGMapRoleSpriteMoveActTagRight); + +} + +void RPGMapRoleSprite::stopMove() +{ + if(!this->m_isMoving) + return; + + switch (this->m_currMoveActTag) + { + case kRPGMapRoleSpriteMoveActTagUp: + { + this->stopActionByTag(kRPGMapRoleSpriteMoveActTagUp); + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(10)); + } + break; + case kRPGMapRoleSpriteMoveActTagDown: + { + this->stopActionByTag(kRPGMapRoleSpriteMoveActTagDown); + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(1)); + } + break; + case kRPGMapRoleSpriteMoveActTagLeft: + { + this->stopActionByTag(kRPGMapRoleSpriteMoveActTagLeft); + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(4)); + } + break; + case kRPGMapRoleSpriteMoveActTagRight: + { + this->stopActionByTag(kRPGMapRoleSpriteMoveActTagRight); + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(7)); + } + break; + default: + break; + } + + this->m_isMoving = false; +} + +void RPGMapRoleSprite::setDirection(RPGMapRoleSpriteDirection direction) +{ + this->m_direction = direction; + + switch (this->m_direction) + { + case kRPGMapRoleSpriteDirectionUp: + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(10)); + break; + case kRPGMapRoleSpriteDirectionDown: + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(1)); + break; + case kRPGMapRoleSpriteDirectionLeft: + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(4)); + break; + case kRPGMapRoleSpriteDirectionRight: + this->setDisplayFrame((CCSpriteFrame*)this->m_roleSpriteFrames->objectAtIndex(7)); + break; + default: + break; + } + +} diff --git a/Classes/RPGMapRoleSprite.h b/Classes/RPGMapRoleSprite.h new file mode 100755 index 0000000..c636594 --- /dev/null +++ b/Classes/RPGMapRoleSprite.h @@ -0,0 +1,73 @@ +// +// RPGMapRoleSprite.h +// OzgGameRPG +// +// Created by ozg on 14-3-18. +// +// + +#ifndef __OzgGameRPG__RPGMapRoleSprite__ +#define __OzgGameRPG__RPGMapRoleSprite__ + +#include "cocos2d.h" + +USING_NS_CC; +using namespace std; + +enum RPGMapRoleSpriteMoveActTag +{ + kRPGMapRoleSpriteMoveActTagUp = 1, + kRPGMapRoleSpriteMoveActTagDown = 2, + kRPGMapRoleSpriteMoveActTagLeft = 3, + kRPGMapRoleSpriteMoveActTagRight = 4 +}; + +enum RPGMapRoleSpriteDirection +{ + kRPGMapRoleSpriteDirectionNone = 0, + kRPGMapRoleSpriteDirectionUp = 1, + kRPGMapRoleSpriteDirectionDown = 2, + kRPGMapRoleSpriteDirectionLeft = 3, + kRPGMapRoleSpriteDirectionRight = 4 +}; + +enum RPGMapRoleSpriteType +{ + kRPGMapRoleSpriteTypePlayer = 1, + kRPGMapRoleSpriteTypeNPC = 2 +}; + +class RPGMapRoleSprite : public CCSprite +{ + +private: + + RPGMapRoleSpriteMoveActTag m_currMoveActTag; + CCArray* m_roleSpriteFrames; + bool m_isMoving; + CCString* m_name; + + void startMove(RPGMapRoleSpriteMoveActTag actTag); + +public: + + RPGMapRoleSpriteDirection m_direction; //该对象向着哪个方向 + + RPGMapRoleSpriteType m_type; + bool m_isPlayer; + + virtual ~RPGMapRoleSprite(); + bool init(CCString *roleTexture, CCString* name, bool isPlayer, int defaultSpriteFrameIndex); + static RPGMapRoleSprite* create(CCString *roleTexture, CCString* name, bool isPlayer, int defaultSpriteFrameIndex); + + void startMoveUp(); + void startMoveDown(); + void startMoveLeft(); + void startMoveRight(); + + void stopMove(); + + void setDirection(RPGMapRoleSpriteDirection direction); +}; + +#endif /* defined(__OzgGameRPG__RPGMapRoleSprite__) */ diff --git a/Classes/RPGMapSceneLayer.cpp b/Classes/RPGMapSceneLayer.cpp new file mode 100755 index 0000000..ff4aba7 --- /dev/null +++ b/Classes/RPGMapSceneLayer.cpp @@ -0,0 +1,720 @@ +// +// RPGMapSceneLayer.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#include "RPGMapSceneLayer.h" +#include "OzgCCUtility.h" +#include "OzgJoystickLayer.h" +#include "RPGMapRoleSprite.h" +#include "RPGMapMenuLayer.h" +#include "RPGMapDialogLayer.h" +#include "RPGLoadingSceneLayer.h" + +RPGMapSceneLayer::RPGMapSceneLayer() +{ + +// CCLog("RPGMapSceneLayer实例化"); +} + +RPGMapSceneLayer::~RPGMapSceneLayer() +{ + OzgJoystickLayer *joystick = (OzgJoystickLayer*)this->getChildByTag(kRPGMapSceneLayerTagJoystick); + joystick->m_target = NULL; + joystick->inactive(); + + this->removeAllChildrenWithCleanup(true); + CCSpriteFrameCache::sharedSpriteFrameCache()->removeSpriteFramesFromFile("joystick.plist"); + + if(this->m_stringList) + { + this->m_stringList->release(); //释放语言数据 + this->m_stringList = NULL; + } + + if(this->m_releaseTexture) + { + CCTextureCache::sharedTextureCache()->removeTextureForKey("map.png"); + CCTextureCache::sharedTextureCache()->removeTextureForKey("main.png"); + + //数据库部分,释放npc的纹理 + CppSQLite3Query query = this->m_db.execQuery("select * from npc order by id desc"); + while(!query.eof()) + { + CCTextureCache::sharedTextureCache()->removeTextureForKey(query.getStringField("map_texture")); + query.nextRow(); + } + query.finalize(); + + //player部分 + CCTextureCache::sharedTextureCache()->removeTextureForKey("actor4_0.png"); + CCTextureCache::sharedTextureCache()->removeTextureForKey("joystick.png"); + + } + +// CCLog("RPGMapSceneLayer释放"); +} + +bool RPGMapSceneLayer::init(float showObjectTime) +{ + if(RPGBaseSceneLayer::init()) + { + CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile("joystick.plist"); + CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile("main.plist"); + + //加载语言文件 + string languageFile = CCFileUtils::sharedFileUtils()->fullPathForFilename("scene_map_cns.plist"); + this->m_stringList = CCDictionary::createWithContentsOfFileThreadSafe(languageFile.c_str()); + this->m_stringList->retain(); + + //数据库部分,读取进度记录 + CppSQLite3Query query = this->m_db.execQuery("select m.name as map_name, sd.map_id, m.has_enemy, m.bg_audio, sd.player_to_x, sd.player_to_y, sd.player_direction from save_data as sd inner join map as m on sd.map_id = m.id where sd.id = 1"); + this->m_mapData.mapId = query.getIntField("map_id"); + this->m_mapData.mapName = query.getStringField("map_name"); + this->m_mapData.hasEnemy = query.getIntField("has_enemy") == 1 ? true : false; + this->m_mapData.bgAudio = query.getStringField("bg_audio"); + this->m_mapData.playerToX = query.getFloatField("player_to_x"); + this->m_mapData.playerToY = query.getFloatField("player_to_y"); + this->m_mapData.playerDirection = query.getStringField("player_direction"); + query.finalize(); + + CCTMXTiledMap *bgMap = CCTMXTiledMap::create(this->m_mapData.mapName.c_str()); + bgMap->setTag(kRPGMapSceneLayerTagBgMap); + bgMap->setPosition(ccp((CCDirector::sharedDirector()->getWinSize().width - bgMap->getContentSize().width) / 2.0, (CCDirector::sharedDirector()->getWinSize().height - bgMap->getContentSize().height) / 2.0)); + this->addChild(bgMap); + + //背景音乐 + if(SimpleAudioEngine::sharedEngine()->isBackgroundMusicPlaying()) + { + SimpleAudioEngine::sharedEngine()->stopBackgroundMusic(true); + SimpleAudioEngine::sharedEngine()->playBackgroundMusic(this->m_mapData.bgAudio.c_str(), true); + } + + this->m_playerMoveAct = NULL; + this->m_playerMoveSpeed = GAME_PLAYER_MOVESPEED; + this->m_touchedDialogNPC = NULL; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionNone; + + this->m_hasEnemy = this->m_mapData.hasEnemy; //是否会遇敌 + this->m_releaseTexture = false; //是否在释构方法里面释放占用纹理 + + this->scheduleOnce(schedule_selector(RPGMapSceneLayer::startPlay), showObjectTime); + + return true; + } + return false; +} + +RPGMapSceneLayer* RPGMapSceneLayer::create(float showObjectTime) +{ + RPGMapSceneLayer *layer = new RPGMapSceneLayer(); + if(layer && layer->init(showObjectTime)) + { + layer->autorelease(); + return layer; + } + CC_SAFE_DELETE(layer); + return NULL; +} + +CCScene* RPGMapSceneLayer::scene() +{ + return RPGMapSceneLayer::scene(GAME_SCENE); +} + +CCScene* RPGMapSceneLayer::scene(float showObjectTime) +{ + CCScene* s = CCScene::create(); + RPGMapSceneLayer *layer = RPGMapSceneLayer::create(showObjectTime); + s->addChild(layer); + return s; +} + +void RPGMapSceneLayer::update(float dt) +{ + OzgJoystickLayer *joystick = (OzgJoystickLayer*)this->getChildByTag(kRPGMapSceneLayerTagJoystick); + if(!this->m_playerMoveAct && joystick && joystick->m_trigger) + { + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + + float dx = joystick->m_currentPoint.x - joystick->m_centerPoint.x; + float dy = joystick->m_currentPoint.y - joystick->m_centerPoint.y; + + //CCLog("%f %f", dx, dy); + if(dx > 0 && dy > 0) + { + if(fabsf(dx) > fabsf(dy)) + { + CCPoint targetPoint = ccp(GAME_TMX_ROLE_WIDTH, 0); + player->startMoveRight(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + else + { + CCPoint targetPoint = ccp(0, GAME_TMX_ROLE_HEIGHT); + player->startMoveUp(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + // CCLog("右上"); + } + else if(dx > 0 && dy < 0) + { + if(fabsf(dx) > fabsf(dy)) + { + CCPoint targetPoint = ccp(GAME_TMX_ROLE_WIDTH, 0); + player->startMoveRight(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + else + { + CCPoint targetPoint = ccp(0, -GAME_TMX_ROLE_HEIGHT); + player->startMoveDown(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + // CCLog("右下"); + } + else if(dx < 0 && dy < 0) + { + if(fabsf(dx) > fabsf(dy)) + { + CCPoint targetPoint = ccp(-GAME_TMX_ROLE_WIDTH, 0); + player->startMoveLeft(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + else + { + CCPoint targetPoint = ccp(0, -GAME_TMX_ROLE_HEIGHT); + player->startMoveDown(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + // CCLog("左下"); + } + else if(dx < 0 && dy > 0) + { + if(fabsf(dx) > fabsf(dy)) + { + CCPoint targetPoint = ccp(-GAME_TMX_ROLE_WIDTH, 0); + player->startMoveLeft(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + else + { + CCPoint targetPoint = ccp(0, GAME_TMX_ROLE_HEIGHT); + player->startMoveUp(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + } + // CCLog("左上"); + } + else if(dx == 0 && dy > 0) + { + CCPoint targetPoint = ccp(0, GAME_TMX_ROLE_HEIGHT); + player->startMoveUp(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + // CCLog("上"); + } + else if(dx == 0 && dy < 0) + { + CCPoint targetPoint = ccp(0, -GAME_TMX_ROLE_HEIGHT); + player->startMoveDown(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + // CCLog("下"); + } + else if(dx < 0 && dy == 0) + { + CCPoint targetPoint = ccp(-GAME_TMX_ROLE_WIDTH, 0); + player->startMoveLeft(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + // CCLog("左"); + } + else if(dx > 0 && dy == 0) + { + CCPoint targetPoint = ccp(GAME_TMX_ROLE_WIDTH, 0); + player->startMoveRight(); + + if(this->doMoving(targetPoint)) + this->m_playerMoveAct = CCMoveBy::create(this->m_playerMoveSpeed, targetPoint); + // CCLog("右"); + + } + + if(this->m_playerMoveAct) + { + this->m_playerMoveAct->setTag(kRPGMapSceneLayerActTagPlayerMove); + player->runAction(CCSequence::createWithTwoActions(this->m_playerMoveAct, CCCallFunc::create(this, callfunc_selector(RPGMapSceneLayer::playerMoveEnd)))); + } + + } + +} + +bool RPGMapSceneLayer::ccTouchBegan(CCTouch* touch, CCEvent* event) +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + + //循环判断点击了哪一个NPC,如果有点中则m_isTouchedNPC为true + for (int i = 0; i < bgMap->getChildren()->count(); i++) + { + CCObject *item = bgMap->getChildren()->objectAtIndex(i); + if(dynamic_cast(item) != NULL) + { + RPGMapNPCRoleSprite *npc = (RPGMapNPCRoleSprite*)item; + if(npc->m_type == kRPGMapRoleSpriteTypeNPC) + { + //判断player是否存在该NPC的四个方向(距离为一格),存在则为true + bool exist = false; + + if(player->getPosition().equals(ccpAdd(npc->getPosition(), ccp(0, GAME_TMX_ROLE_HEIGHT)))) + { + //上 + exist = true; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionUp; + } + else if(player->getPosition().equals(ccpAdd(npc->getPosition(), ccp(0, -GAME_TMX_ROLE_HEIGHT)))) + { + //下 + exist = true; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionDown; + } + else if(player->getPosition().equals(ccpAdd(npc->getPosition(), ccp(-GAME_TMX_ROLE_WIDTH, 0)))) + { + //左 + exist = true; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionLeft; + } + else if(player->getPosition().equals(ccpAdd(npc->getPosition(), ccp(GAME_TMX_ROLE_WIDTH, 0)))) + { + //右 + exist = true; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionRight; + } + + if(exist) + { + CCPoint point = touch->getLocation(); + point = bgMap->convertToNodeSpace(point); + if(npc->boundingBox().containsPoint(point)) + { + this->m_touchedDialogNPC = npc; + break; + } + } + + } + } + } + + //如果是点中了NPC则进入ccTouchEnded的处理 + if(this->m_touchedDialogNPC) + return true; + else + { + //传入到摇杆的事件处理 + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setVisible(false); + return false; + } + +} + +void RPGMapSceneLayer::ccTouchMoved(CCTouch* touch, CCEvent* event) +{ + +} + +void RPGMapSceneLayer::ccTouchEnded(CCTouch* touch, CCEvent* event) +{ + if(this->m_touchedDialogNPC) + { + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + + CCPoint point = touch->getLocation(); + point = bgMap->convertToNodeSpace(point); + + if(this->m_touchedDialogNPC->boundingBox().containsPoint(point)) + { + this->m_touchedDialogNPC->stopAutoMove(); //暂时停止自动移动 + + string content = this->m_touchedDialogNPC->m_content->getCString(); + RPGMapDialogLayer *dialogLayer = RPGMapDialogLayer::create(this->m_touchedDialogNPC); + this->addChild(dialogLayer); + + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setVisible(false); + + //player和NPC互相对着 + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + switch (this->m_dialogDirection) + { + case kRPGMapSceneLayerDialogDirectionUp: + { + player->setDirection(kRPGMapRoleSpriteDirectionDown); + this->m_touchedDialogNPC->setDirection(kRPGMapRoleSpriteDirectionUp); + } + break; + case kRPGMapSceneLayerDialogDirectionDown: + { + player->setDirection(kRPGMapRoleSpriteDirectionUp); + this->m_touchedDialogNPC->setDirection(kRPGMapRoleSpriteDirectionDown); + } + break; + case kRPGMapSceneLayerDialogDirectionLeft: + { + player->setDirection(kRPGMapRoleSpriteDirectionRight); + this->m_touchedDialogNPC->setDirection(kRPGMapRoleSpriteDirectionLeft); + } + break; + case kRPGMapSceneLayerDialogDirectionRight: + { + player->setDirection(kRPGMapRoleSpriteDirectionLeft); + this->m_touchedDialogNPC->setDirection(kRPGMapRoleSpriteDirectionRight); + } + break; + default: + break; + } + + } + } + + this->m_touchedDialogNPC = NULL; + this->m_dialogDirection = kRPGMapSceneLayerDialogDirectionNone; +} + +void RPGMapSceneLayer::enabledControl(bool enabled) +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + + OzgJoystickLayer *joystick = (OzgJoystickLayer*)this->getChildByTag(kRPGMapSceneLayerTagJoystick); + + if(enabled) + { + CCDirector::sharedDirector()->getTouchDispatcher()->addTargetedDelegate(this, 1, true); + + joystick->active(); + mainMenu->setVisible(true); + + } + else + { + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(this); + + joystick->inactive(); + mainMenu->setVisible(false); + + } +} + +void RPGMapSceneLayer::joystickEndedFunc() +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setVisible(true); + + player->stopMove(); +} + +//private +void RPGMapSceneLayer::startPlay(float delay) +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + + //数据库部分,读取npc数据 + CppSQLite3Query query = this->m_db.execQuery(CCString::createWithFormat("select * from npc where map_id = %i order by id desc", this->m_mapData.mapId)->getCString()); + while(!query.eof()) + { + float x = (stringToNumber(query.getStringField("tmx_x")) + 0.5) * GAME_TMX_ROLE_WIDTH; + float y = (stringToNumber(query.getStringField("tmx_y")) + 0.5) * GAME_TMX_ROLE_HEIGHT; + bool autoMove = query.getIntField("auto_move") == 1 ? true : false; + + RPGMapNPCRoleSprite *npc = RPGMapNPCRoleSprite::create(CCString::create(query.getStringField("map_texture")), CCString::create("head_texture"), CCString::create(query.getStringField("name_cns")), CCString::create(query.getStringField("content_cns")), 1, autoMove); + npc->setTag(kRPGMapSceneLayerTagNPC + query.getIntField("id")); + npc->setPosition(ccp(x, y)); + bgMap->addChild(npc); + + query.nextRow(); + } + query.finalize(); + + //player + int defaultSpriteFrameIndex = 1; //默认为向下 + if(this->m_mapData.playerDirection.compare("up") == 0) + { + defaultSpriteFrameIndex = 10; + } + else if(this->m_mapData.playerDirection.compare("left") == 0) + { + defaultSpriteFrameIndex = 4; + } + else if(this->m_mapData.playerDirection.compare("right") == 0) + { + defaultSpriteFrameIndex = 7; + } + RPGMapRoleSprite *player = RPGMapRoleSprite::create(CCString::create("actor4_0.png"), CCString::create("Player"), true, defaultSpriteFrameIndex); + player->setPosition(ccp(this->m_mapData.playerToX * GAME_TMX_ROLE_WIDTH, this->m_mapData.playerToY * GAME_TMX_ROLE_HEIGHT)); + player->setTag(kRPGMapSceneLayerTagPlayer); + player->m_type = kRPGMapRoleSpriteTypePlayer; + bgMap->addChild(player); + + CCSprite *spJoystick = CCSprite::createWithSpriteFrameName("Ball.png"); + CCSprite *joystickBg = CCSprite::createWithSpriteFrameName("Dock.png"); + OzgJoystickLayer *joystick = OzgJoystickLayer::layerActivityJoystick(50, spJoystick, joystickBg, false); + joystick->setTag(kRPGMapSceneLayerTagJoystick); + joystick->m_target = this; + joystick->m_endedSelector = callfunc_selector(RPGMapSceneLayer::joystickEndedFunc); + this->addChild(joystick); + + //menu + CCMenu *mainMenu = CCMenu::create(); + mainMenu->setTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setAnchorPoint(ccp(0.5, 0.5)); + mainMenu->setPosition(CCPointZero); + mainMenu->setContentSize(bgMap->getContentSize()); + bgMap->addChild(mainMenu); + + CCMenuItemSprite *menuCommand = CCMenuItemSprite::create(CCSprite::createWithSpriteFrameName("commons_btn_back_04.png"), CCSprite::createWithSpriteFrameName("commons_btn_back_04.png"), this, menu_selector(RPGMapSceneLayer::onMenu)); + menuCommand->setPosition(ccp(mainMenu->getContentSize().width - 35, mainMenu->getContentSize().height - 35)); + menuCommand->setTag(kRPGMapSceneLayerTagMainMenuCommand); + menuCommand->setRotation(180); + menuCommand->setScale(0.75); + mainMenu->addChild(menuCommand); + +// CCTextureCache::sharedTextureCache()->dumpCachedTextureInfo(); + CCDirector::sharedDirector()->getTouchDispatcher()->addTargetedDelegate(this, 1, true); + this->scheduleUpdate(); + +} + +//private +void RPGMapSceneLayer::onMenu(CCObject *pObject) +{ + SimpleAudioEngine::sharedEngine()->playEffect("audio_effect_btn.wav"); + + switch (((CCMenuItem*)pObject)->getTag()) + { + default: + { + //点击了右上角的菜单按钮 +// SimpleAudioEngine::sharedEngine()->playEffect("effect_btn.wav", false); + + RPGMapMenuLayer *menuLayer = (RPGMapMenuLayer*)this->getChildByTag(kRPGMapSceneLayerTagMenuLayer); + if(!menuLayer) + { + this->enabledControl(false); + + //因为动态获取地图的大小会导致了菜单层显示错位,所以定死了 + float width = 960; + float height = 640; + + menuLayer = RPGMapMenuLayer::create(this->m_stringList, &this->m_db, width, height); + menuLayer->setPosition(ccp((CCDirector::sharedDirector()->getWinSize().width - width) / 2.0, (CCDirector::sharedDirector()->getWinSize().height - height) / 2.0)); + menuLayer->setTag(kRPGMapSceneLayerTagMenuLayer); + this->addChild(menuLayer); + } + + } + break; + } + +} + +void RPGMapSceneLayer::playerMoveEnd() +{ + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + player->stopMove(); + + player->stopActionByTag(kRPGMapSceneLayerActTagPlayerMove); + + this->m_playerMoveAct = NULL; + + //地图切换点的判断 + CCTMXObjectGroup *transitionsObjects = bgMap->objectGroupNamed("transitions"); + for (int i = 0; i < transitionsObjects->getObjects()->count(); i++) + { + CCDictionary *transitionsObject = (CCDictionary*)transitionsObjects->getObjects()->objectAtIndex(i); + const CCString *x = transitionsObject->valueForKey("x"); + const CCString *y = transitionsObject->valueForKey("y"); + const CCString *width = transitionsObject->valueForKey("width"); + const CCString *height = transitionsObject->valueForKey("height"); + + const CCString *mapId = transitionsObject->valueForKey("map_id"); + const CCString *playerToX = transitionsObject->valueForKey("player_to_x"); + const CCString *playerToY = transitionsObject->valueForKey("player_to_y"); + const CCString *playerDirection = transitionsObject->valueForKey("player_direction"); + + CCRect transitionsRect = CCRectMake(stringToNumber(x->getCString()), stringToNumber(y->getCString()), stringToNumber(width->getCString()), stringToNumber(height->getCString())); + + if(transitionsRect.containsPoint(player->getPosition())) + { +// CCLog("切换场景%s", mapId->getCString()); + + //数据库部分,更新进度记录 + + //修正偏差位置,因为无法得知下一个地图的大小,所以目前只能在tmx上面定死 + float toX = stringToNumber(playerToX->getCString()) + 0.5; + float toY = stringToNumber(playerToY->getCString()) + 0.5; + + //保存数据 + saveData(&this->m_db, stringToNumber(mapId->getCString()), toX, toY, playerDirection->getCString()); + + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(this); + this->unscheduleUpdate(); + + CCScene *s = RPGMapSceneLayer::scene(0.0); + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); + return; + } + + } + + //遇敌处理 +// this->m_hasEnemy = true; //test + if(this->m_hasEnemy) + { + float val = CCRANDOM_0_1(); + val = CCRANDOM_0_1(); + if(val >= 0.0 && val <= 0.5) + { +// CCLog("遇敌!"); + CCDirector::sharedDirector()->getTouchDispatcher()->removeDelegate(this); + this->unscheduleUpdate(); + + //保存进度 + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + float toX = player->getPositionX(); + float toY = player->getPositionY(); + toX = toX / GAME_TMX_ROLE_WIDTH; + toY = toY / GAME_TMX_ROLE_HEIGHT; + + string playerDirection; + switch (player->m_direction) + { + case kRPGMapRoleSpriteDirectionDown: + playerDirection = "down"; + + break; + case kRPGMapRoleSpriteDirectionLeft: + playerDirection = "left"; + + break; + case kRPGMapRoleSpriteDirectionRight: + playerDirection = "right"; + + break; + default: + //kRPGMapRoleSpriteDirectionUp + playerDirection = "up"; + + break; + } + + saveData(&this->m_db, this->m_mapData.mapId, toX, toY, playerDirection); + + //保存进度结束 + + CCArray *loadTextures = CCArray::create(); + loadTextures->addObject(CCString::create("monsters.png")); + loadTextures->addObject(CCString::create("battle_bg.png")); + + CCArray *releaseTextures = CCArray::create(); + releaseTextures->addObject(CCString::create("map.png")); + releaseTextures->addObject(CCString::create("joystick.png")); + releaseTextures->addObject(CCString::create("actor4_0.png")); + releaseTextures->addObject(CCString::create("actor111.png")); + releaseTextures->addObject(CCString::create("actor113.png")); + releaseTextures->addObject(CCString::create("actor114.png")); + releaseTextures->addObject(CCString::create("actor115.png")); + releaseTextures->addObject(CCString::create("actor117.png")); + releaseTextures->addObject(CCString::create("actor120.png")); + + CCMenu *mainMenu = (CCMenu*)bgMap->getChildByTag(kRPGMapSceneLayerTagMainMenu); + mainMenu->setEnabled(false); + + SimpleAudioEngine::sharedEngine()->playEffect("audio_battle_start.wav"); + +// CCLog("%i", this->m_saveData.mapId); + CCUserDefault::sharedUserDefault()->setIntegerForKey("map_id", this->m_mapData.mapId); + + CCScene *s = RPGLoadingSceneLayer::scene(loadTextures, releaseTextures, "single_battle"); + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); + } + } + +} + +bool RPGMapSceneLayer::doMoving(cocos2d::CCPoint targetPoint) +{ + //这里的逻辑跟RPGMapNPCRoleSprite::autoMove类似 + + CCTMXTiledMap *bgMap = (CCTMXTiledMap*)this->getChildByTag(kRPGMapSceneLayerTagBgMap); + RPGMapRoleSprite *player = (RPGMapRoleSprite*)bgMap->getChildByTag(kRPGMapSceneLayerTagPlayer); + CCTMXObjectGroup *obstaclesObjects = bgMap->objectGroupNamed("obstacles"); + + targetPoint = ccpAdd(player->getPosition(), targetPoint); + + //地图上的障碍物 + for (int i = 0; i < obstaclesObjects->getObjects()->count(); i++) + { + CCDictionary *obstaclesObject = (CCDictionary*)obstaclesObjects->getObjects()->objectAtIndex(i); + const CCString *x = obstaclesObject->valueForKey("x"); + const CCString *y = obstaclesObject->valueForKey("y"); + const CCString *width = obstaclesObject->valueForKey("width"); + const CCString *height = obstaclesObject->valueForKey("height"); + + CCRect obstaclesRect = CCRectMake(stringToNumber(x->getCString()), stringToNumber(y->getCString()), stringToNumber(width->getCString()), stringToNumber(height->getCString())); + + if(obstaclesRect.containsPoint(targetPoint)) + return false; + } + + //NPC或Player + for (int i = 0; i < bgMap->getChildren()->count(); i++) + { + CCObject *item = bgMap->getChildren()->objectAtIndex(i); + if(dynamic_cast(item) != NULL) + { + //如果为非player的对象才会执行里面的判断 + if(item != player) + { + if(((RPGMapRoleSprite*)item)->boundingBox().containsPoint(targetPoint)) + return false; + } + } + } + + return true; +} diff --git a/Classes/RPGMapSceneLayer.h b/Classes/RPGMapSceneLayer.h new file mode 100755 index 0000000..dbc82d8 --- /dev/null +++ b/Classes/RPGMapSceneLayer.h @@ -0,0 +1,96 @@ +// +// RPGMapSceneLayer.h +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#ifndef __OzgGameRPG__RPGMapSceneLayer__ +#define __OzgGameRPG__RPGMapSceneLayer__ + +#include "RPGBaseSceneLayer.h" +#include "RPGMapNPCRoleSprite.h" + +enum RPGMapSceneLayerTag +{ + kRPGMapSceneLayerTagBgMap = 1, + kRPGMapSceneLayerTagJoystick = 2, + kRPGMapSceneLayerTagMainMenu = 3, + kRPGMapSceneLayerTagMainMenuCommand = 4, + kRPGMapSceneLayerTagMenuLayer = 5, + kRPGMapSceneLayerTagPlayer = 1999, + kRPGMapSceneLayerTagNPC = 2000 + +}; + +enum RPGMapSceneLayerActTag +{ + kRPGMapSceneLayerActTagPlayerMove = 20 + +}; + +enum RPGMapSceneLayerDialogDirection +{ + kRPGMapSceneLayerDialogDirectionNone = 0, + kRPGMapSceneLayerDialogDirectionUp = 1, + kRPGMapSceneLayerDialogDirectionDown = 2, + kRPGMapSceneLayerDialogDirectionLeft = 3, + kRPGMapSceneLayerDialogDirectionRight = 4 +}; + +struct RPGMapData +{ + int mapId; + string mapName; + bool hasEnemy; + string bgAudio; + float playerToX; + float playerToY; + string playerDirection; +}; + +class RPGMapSceneLayer : public RPGBaseSceneLayer +{ + +private: + + CCMoveBy *m_playerMoveAct; + float m_playerMoveSpeed; //player移动的速度 + + RPGMapData m_mapData; //地图场景的公用数据 + + RPGMapNPCRoleSprite* m_touchedDialogNPC; //点中了可对话的NPC,player存在NPC的四个方向才可以点中,如果不存在即使点中了也是为NULL + RPGMapSceneLayerDialogDirection m_dialogDirection; //跟NPC对话时,player在NPC的哪个方向 + + void startPlay(float delay); + void onMenu(CCObject *pObject); + void playerMoveEnd(); + + bool doMoving(CCPoint targetPoint); + +public: + bool m_hasEnemy; + bool m_releaseTexture; + + RPGMapSceneLayer(); + virtual ~RPGMapSceneLayer(); + bool init(float showObjectTime); + static RPGMapSceneLayer* create(float showObjectTime); + + static CCScene* scene(); + static CCScene* scene(float showObjectTime); + + void update(float dt); + + virtual bool ccTouchBegan(CCTouch *pTouch, CCEvent *pEvent); + virtual void ccTouchMoved(CCTouch *pTouch, CCEvent *pEvent); + virtual void ccTouchEnded(CCTouch *pTouch, CCEvent *pEvent); + + void enabledControl(bool enabled); + + void joystickEndedFunc(); //摇杆事件的结束回调 + +}; + +#endif /* defined(__OzgGameRPG__RPGMapSceneLayer__) */ diff --git a/Classes/RPGStartSceneLayer.cpp b/Classes/RPGStartSceneLayer.cpp new file mode 100755 index 0000000..2b4526b --- /dev/null +++ b/Classes/RPGStartSceneLayer.cpp @@ -0,0 +1,157 @@ +// +// RPGStartSceneLayer.cpp +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#include "RPGStartSceneLayer.h" +#include "OzgCCScrollBgNode.h" +#include "OzgCCUtility.h" +#include "OzgFileUtility.h" +#include "RPGLoadingSceneLayer.h" +#include "RPGMapSceneLayer.h" + +RPGStartSceneLayer::RPGStartSceneLayer() +{ + +} + +RPGStartSceneLayer::~RPGStartSceneLayer() +{ + this->removeAllChildrenWithCleanup(true); + + if(this->m_stringList) + { + this->m_stringList->release(); //释放语言数据 + this->m_stringList = NULL; + } + + //CCTextureCache::sharedTextureCache()->dumpCachedTextureInfo(); +} + +bool RPGStartSceneLayer::init() +{ + if(RPGBaseSceneLayer::init()) + { + //加载语言文件 + string languageFile = CCFileUtils::sharedFileUtils()->fullPathForFilename("scene_start_cns.plist"); + this->m_stringList = CCDictionary::createWithContentsOfFileThreadSafe(languageFile.c_str()); + this->m_stringList->retain(); + + CCTextureCache::sharedTextureCache()->addImage("Window_b_00.png"); + + //背景 + OzgCCScrollBgNode *bg = OzgCCScrollBgNode::create("start_bg.png"); + bg->setAnchorPoint(CCPointZero); + bg->setPosition(CCPointZero); + bg->setTag(kRPGStartSceneLayerTagBg); + this->addChild(bg); + + CCMenu *mainMenu = CCMenu::create(); + mainMenu->setAnchorPoint(CCPointZero); + mainMenu->setPosition(CCPointZero); + mainMenu->setTag(kRPGStartSceneLayerTagMenu); + this->addChild(mainMenu); + + CCString *menuItemSingleModeStr = (CCString*)this->m_stringList->objectForKey("menuitem_start"); + CCLabelTTF *menuItemSingleModeLabel = CCLabelTTF::create(OzgCCUtility::generalString(menuItemSingleModeStr->getCString()).c_str(), "FZCuYuan-M03S", 28, CCSizeMake(120, 40), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + + CCString *menuItemOnLineModeStr = (CCString*)this->m_stringList->objectForKey("menuitem_delete"); + CCLabelTTF *menuItemOnLineModeLabel = CCLabelTTF::create(OzgCCUtility::generalString(menuItemOnLineModeStr->getCString()).c_str(), "FZCuYuan-M03S", 28, CCSizeMake(120, 40), kCCTextAlignmentCenter, kCCVerticalTextAlignmentCenter); + + CCMenuItemLabel *menuItemSingleMode = CCMenuItemLabel::create(menuItemSingleModeLabel, this, menu_selector(RPGStartSceneLayer::onMenu)); + menuItemSingleMode->setPosition(ccp(CCDirector::sharedDirector()->getWinSize().width / 2, 170)); + menuItemSingleMode->setTag(kRPGStartSceneLayerTagMenuItemStart); + mainMenu->addChild(menuItemSingleMode); + + CCMenuItemLabel *menuItemOnLineMode = CCMenuItemLabel::create(menuItemOnLineModeLabel, this, menu_selector(RPGStartSceneLayer::onMenu)); + menuItemOnLineMode->setPosition(ccp(CCDirector::sharedDirector()->getWinSize().width / 2, 110)); + menuItemOnLineMode->setTag(kRPGStartSceneLayerTagMenuItemDelete); + mainMenu->addChild(menuItemOnLineMode); + + //背景音乐 + if(!SimpleAudioEngine::sharedEngine()->isBackgroundMusicPlaying()) + SimpleAudioEngine::sharedEngine()->playBackgroundMusic("audio_start.mp3", true); + + return true; + } + return false; +} + +CCScene* RPGStartSceneLayer::scene() +{ + CCScene* s = CCScene::create(); + RPGStartSceneLayer *layer = RPGStartSceneLayer::create(); + s->addChild(layer); + return s; +} + +void RPGStartSceneLayer::onMenu(cocos2d::CCObject *pObject) +{ + SimpleAudioEngine::sharedEngine()->playEffect("audio_effect_btn.wav"); + + CCMenuItem *menuItem = (CCMenuItem*)pObject; + + switch (menuItem->getTag()) + { + case kRPGStartSceneLayerTagMenuItemDelete: + { + CCSize winSize = CCDirector::sharedDirector()->getWinSize(); + + RPGConfirmLayer *confirm = RPGConfirmLayer::create(((CCString*)this->m_stringList->objectForKey("confirm_delete"))->getCString(), ((CCString*)this->m_stringList->objectForKey("confirm_ok"))->getCString(), kRPGStartSceneLayerTagMenuItemConfirmOK, ((CCString*)this->m_stringList->objectForKey("confirm_cancel"))->getCString(), kRPGStartSceneLayerTagMenuItemConfirmCancel, winSize.width, winSize.height, this, menu_selector(RPGStartSceneLayer::onMenu)); + confirm->setTag(kRPGStartSceneLayerTagConfirm); + this->addChild(confirm); + + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGStartSceneLayerTagMenu); + mainMenu->setEnabled(false); + } + break; + case kRPGStartSceneLayerTagMenuItemConfirmOK: + { + this->m_db.execDML("delete from save_data; delete from player;"); + this->m_db.execDML(GAME_INIT_SQL); + + this->goToMapScene(); + } + break; + case kRPGStartSceneLayerTagMenuItemConfirmCancel: + { + this->removeChildByTag(kRPGStartSceneLayerTagConfirm, true); + + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGStartSceneLayerTagMenu); + mainMenu->setEnabled(true); + } + break; + default: + { + //kRPGStartSceneLayerTagMenuItemStart + this->goToMapScene(); + } + break; + } + +} + +void RPGStartSceneLayer::goToMapScene() +{ + CCArray *loadTextures = CCArray::create(); + loadTextures->addObject(CCString::create("map.png")); + loadTextures->addObject(CCString::create("main.png")); + loadTextures->addObject(CCString::create("joystick.png")); + loadTextures->addObject(CCString::create("actor4_0.png")); + loadTextures->addObject(CCString::create("actor111.png")); + loadTextures->addObject(CCString::create("actor113.png")); + loadTextures->addObject(CCString::create("actor114.png")); + loadTextures->addObject(CCString::create("actor115.png")); + loadTextures->addObject(CCString::create("actor117.png")); + loadTextures->addObject(CCString::create("actor120.png")); + + CCMenu *mainMenu = (CCMenu*)this->getChildByTag(kRPGStartSceneLayerTagMenu); + mainMenu->setEnabled(false); + + CCScene *s = RPGLoadingSceneLayer::scene(loadTextures, NULL, "single_map"); + CCTransitionFade *t = CCTransitionFade::create(GAME_SCENE, s); + CCDirector::sharedDirector()->replaceScene(t); +} diff --git a/Classes/RPGStartSceneLayer.h b/Classes/RPGStartSceneLayer.h new file mode 100755 index 0000000..f16c9e3 --- /dev/null +++ b/Classes/RPGStartSceneLayer.h @@ -0,0 +1,45 @@ +// +// RPGStartSceneLayer.h +// OzgGameRPG +// +// Created by ozg on 14-3-17. +// +// + +#ifndef __OzgGameRPG__RPGStartSceneLayer__ +#define __OzgGameRPG__RPGStartSceneLayer__ + +#include "RPGBaseSceneLayer.h" + +//各个显示对象的tag +enum RPGStartSceneLayerTag +{ + kRPGStartSceneLayerTagBg = 1, + kRPGStartSceneLayerTagMenu = 2, + kRPGStartSceneLayerTagMenuItemStart = 3, + kRPGStartSceneLayerTagMenuItemDelete = 4, + kRPGStartSceneLayerTagMenuItemConfirmOK = 5, + kRPGStartSceneLayerTagMenuItemConfirmCancel = 6, + kRPGStartSceneLayerTagConfirm = 7 +}; + +class RPGStartSceneLayer : public RPGBaseSceneLayer +{ + +private: + void onMenu(CCObject *pObject); + +public: + + RPGStartSceneLayer(); + virtual ~RPGStartSceneLayer(); + virtual bool init(); + CREATE_FUNC(RPGStartSceneLayer); + + static CCScene* scene(); + + void goToMapScene(); + +}; + +#endif /* defined(__OzgGameRPG__RPGStartSceneLayer__) */ diff --git a/README.md b/README.md new file mode 100644 index 0000000..a649036 --- /dev/null +++ b/README.md @@ -0,0 +1,18 @@ +ozg game — RPG +================ + +本游戏主要用于技术的研究和积累 + + +游戏中所用的一部分图片来自 http://www.66rpg.com/type.php?t=17 另一部分图片来自 http://usui.moo.jp/rpg_tukuru.html + +所用声音文件来自 http://www.66rpg.com/type.php?t=17 + + +目前只在iOS平台下进行测试 + +![](https://raw.github.com/ouzhigang/OzgGameRPG/master/screenshot1.png) + +![](https://raw.github.com/ouzhigang/OzgGameRPG/master/screenshot2.png) + +![](https://raw.github.com/ouzhigang/OzgGameRPG/master/screenshot3.png) diff --git a/Resources/Window_b_00.png b/Resources/Window_b_00.png new file mode 100755 index 0000000..a0a3e3a Binary files /dev/null and b/Resources/Window_b_00.png differ diff --git a/Resources/actor111.png b/Resources/actor111.png new file mode 100755 index 0000000..efbe0d9 Binary files /dev/null and b/Resources/actor111.png differ diff --git a/Resources/actor113.png b/Resources/actor113.png new file mode 100755 index 0000000..bd918f3 Binary files /dev/null and b/Resources/actor113.png differ diff --git a/Resources/actor114.png b/Resources/actor114.png new file mode 100755 index 0000000..0385956 Binary files /dev/null and b/Resources/actor114.png differ diff --git a/Resources/actor115.png b/Resources/actor115.png new file mode 100755 index 0000000..a48d54e Binary files /dev/null and b/Resources/actor115.png differ diff --git a/Resources/actor117.png b/Resources/actor117.png new file mode 100755 index 0000000..60fef65 Binary files /dev/null and b/Resources/actor117.png differ diff --git a/Resources/actor120.png b/Resources/actor120.png new file mode 100755 index 0000000..baf33f9 Binary files /dev/null and b/Resources/actor120.png differ diff --git a/Resources/actor4_0.png b/Resources/actor4_0.png new file mode 100755 index 0000000..9c9dd82 Binary files /dev/null and b/Resources/actor4_0.png differ diff --git a/Resources/actor4_1.png b/Resources/actor4_1.png new file mode 100755 index 0000000..d067b9f Binary files /dev/null and b/Resources/actor4_1.png differ diff --git a/Resources/actor4_2.png b/Resources/actor4_2.png new file mode 100755 index 0000000..c33f88c Binary files /dev/null and b/Resources/actor4_2.png differ diff --git a/Resources/actor4_3.png b/Resources/actor4_3.png new file mode 100755 index 0000000..1ed8471 Binary files /dev/null and b/Resources/actor4_3.png differ diff --git a/Resources/actor4_4.png b/Resources/actor4_4.png new file mode 100755 index 0000000..6ac9743 Binary files /dev/null and b/Resources/actor4_4.png differ diff --git a/Resources/actor5_0.png b/Resources/actor5_0.png new file mode 100755 index 0000000..0726c75 Binary files /dev/null and b/Resources/actor5_0.png differ diff --git a/Resources/actor5_1.png b/Resources/actor5_1.png new file mode 100755 index 0000000..9515577 Binary files /dev/null and b/Resources/actor5_1.png differ diff --git a/Resources/actor5_2.png b/Resources/actor5_2.png new file mode 100755 index 0000000..78e9611 Binary files /dev/null and b/Resources/actor5_2.png differ diff --git a/Resources/actor5_3.png b/Resources/actor5_3.png new file mode 100755 index 0000000..6709645 Binary files /dev/null and b/Resources/actor5_3.png differ diff --git a/Resources/actor5_4.png b/Resources/actor5_4.png new file mode 100755 index 0000000..fb48688 Binary files /dev/null and b/Resources/actor5_4.png differ diff --git a/Resources/actor7_0.png b/Resources/actor7_0.png new file mode 100755 index 0000000..c313fa3 Binary files /dev/null and b/Resources/actor7_0.png differ diff --git a/Resources/actor7_1.png b/Resources/actor7_1.png new file mode 100755 index 0000000..44049cf Binary files /dev/null and b/Resources/actor7_1.png differ diff --git a/Resources/actor7_2.png b/Resources/actor7_2.png new file mode 100755 index 0000000..8819490 Binary files /dev/null and b/Resources/actor7_2.png differ diff --git a/Resources/actor7_3.png b/Resources/actor7_3.png new file mode 100755 index 0000000..fbaa20a Binary files /dev/null and b/Resources/actor7_3.png differ diff --git a/Resources/actor7_4.png b/Resources/actor7_4.png new file mode 100755 index 0000000..eca7814 Binary files /dev/null and b/Resources/actor7_4.png differ diff --git a/Resources/actor8_0.png b/Resources/actor8_0.png new file mode 100755 index 0000000..2147e5e Binary files /dev/null and b/Resources/actor8_0.png differ diff --git a/Resources/actor8_1.png b/Resources/actor8_1.png new file mode 100755 index 0000000..c544cb5 Binary files /dev/null and b/Resources/actor8_1.png differ diff --git a/Resources/actor8_2.png b/Resources/actor8_2.png new file mode 100755 index 0000000..62159a1 Binary files /dev/null and b/Resources/actor8_2.png differ diff --git a/Resources/actor8_3.png b/Resources/actor8_3.png new file mode 100755 index 0000000..75ea360 Binary files /dev/null and b/Resources/actor8_3.png differ diff --git a/Resources/actor8_4.png b/Resources/actor8_4.png new file mode 100755 index 0000000..78597c0 Binary files /dev/null and b/Resources/actor8_4.png differ diff --git a/Resources/alert_style1.tmx b/Resources/alert_style1.tmx new file mode 100755 index 0000000..a289342 --- /dev/null +++ b/Resources/alert_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJzTYmBg0KIAqxDAlJg9av6o+ZTaQ6z5o3hgMACa9Ct1 + + + + + eJxjZWBgYKMR5gBiXgbaAYFR8wfcfNFR84e1+bJALE8jrADEAMynBMM= + + + diff --git a/Resources/app.icf b/Resources/app.icf new file mode 100755 index 0000000..a793d49 --- /dev/null +++ b/Resources/app.icf @@ -0,0 +1,22 @@ +# This file is for configuration settings for your +# application. +# +# The syntax is similar to windows .ini files ie +# +# [GroupName] +# Setting = Value +# +# Which can be read by your application using +# e.g s3eConfigGetString("GroupName", "Setting", string) +# +# All settings must be documented in .config.txt files. +# New settings specific to this application should be +# documented in app.config.txt +# +# Some conditional operations are also permitted, see the +# S3E documentation for details. +[S3E] +MemSize = 100000000 +# Sample only compatible with 480x320 display resolution +WinWidth=480 +WinHeight=320 diff --git a/Resources/audio_battle.mp3 b/Resources/audio_battle.mp3 new file mode 100755 index 0000000..8100017 Binary files /dev/null and b/Resources/audio_battle.mp3 differ diff --git a/Resources/audio_battle_end.mp3 b/Resources/audio_battle_end.mp3 new file mode 100755 index 0000000..96e6485 Binary files /dev/null and b/Resources/audio_battle_end.mp3 differ diff --git a/Resources/audio_battle_menu.wav b/Resources/audio_battle_menu.wav new file mode 100755 index 0000000..e348f85 Binary files /dev/null and b/Resources/audio_battle_menu.wav differ diff --git a/Resources/audio_battle_start.wav b/Resources/audio_battle_start.wav new file mode 100755 index 0000000..1a4c4e0 Binary files /dev/null and b/Resources/audio_battle_start.wav differ diff --git a/Resources/audio_effect_btn.wav b/Resources/audio_effect_btn.wav new file mode 100755 index 0000000..049f909 Binary files /dev/null and b/Resources/audio_effect_btn.wav differ diff --git a/Resources/audio_map_01.mp3 b/Resources/audio_map_01.mp3 new file mode 100755 index 0000000..844f577 Binary files /dev/null and b/Resources/audio_map_01.mp3 differ diff --git a/Resources/audio_map_02.mp3 b/Resources/audio_map_02.mp3 new file mode 100755 index 0000000..146d719 Binary files /dev/null and b/Resources/audio_map_02.mp3 differ diff --git a/Resources/audio_map_03.mp3 b/Resources/audio_map_03.mp3 new file mode 100755 index 0000000..3c89a22 Binary files /dev/null and b/Resources/audio_map_03.mp3 differ diff --git a/Resources/audio_start.mp3 b/Resources/audio_start.mp3 new file mode 100755 index 0000000..5e9a9d2 Binary files /dev/null and b/Resources/audio_start.mp3 differ diff --git a/Resources/battle_battlemenu_style1.tmx b/Resources/battle_battlemenu_style1.tmx new file mode 100644 index 0000000..5ee1fe9 --- /dev/null +++ b/Resources/battle_battlemenu_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJwTZmBgEB7FgwYLUqhOkMYYAGltCjE= + + + + + eJxjZWBgYCOAOYCYl4EwEBiB6kSJUCcxBNTJArE8AawAxABGxgMf + + + diff --git a/Resources/battle_bg.png b/Resources/battle_bg.png new file mode 100644 index 0000000..fe5383b Binary files /dev/null and b/Resources/battle_bg.png differ diff --git a/Resources/battle_menu_style1.tmx b/Resources/battle_menu_style1.tmx new file mode 100644 index 0000000..db009e7 --- /dev/null +++ b/Resources/battle_menu_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJztwwENAAAMw6AKmX+dt3ABkLBqqqrq6wG6tU7B + + + + + eJztjzEKACAMA7tUXAQXR9H/v9L2CzaFDgnceuRURBqAbijIlYV/XILZNAbIlTX/yN5/F3trjb0xF3trjb0xF3trzT9u4wC4QFcW/vEBkFcLQQ== + + + diff --git a/Resources/battle_msg_style1.tmx b/Resources/battle_msg_style1.tmx new file mode 100644 index 0000000..7db2b56 --- /dev/null +++ b/Resources/battle_msg_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJzjYmBg4BrFNMcAgV4DhQ== + + + + + eJxjZWBgYKMz5gBiUQb6AwEglgVieTpjBSAGANIPBHw= + + + diff --git a/Resources/db.sys b/Resources/db.sys new file mode 100755 index 0000000..657082f Binary files /dev/null and b/Resources/db.sys differ diff --git a/Resources/dialog_style1.tmx b/Resources/dialog_style1.tmx new file mode 100755 index 0000000..379e138 --- /dev/null +++ b/Resources/dialog_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJzjZmBg4B7Fo3gUj+JRPIpH8SgexVTDAB2HGck= + + + + + eJxjZWBgYBshmAOIRRlGDhBgGPXvcAaj/h3eYNS/wxuMRP/KArH8CMEKQAwAj/8J1Q== + + + diff --git a/Resources/fonts/Marker Felt.ttf b/Resources/fonts/Marker Felt.ttf new file mode 100755 index 0000000..3752ef3 Binary files /dev/null and b/Resources/fonts/Marker Felt.ttf differ diff --git a/Resources/joystick.plist b/Resources/joystick.plist new file mode 100755 index 0000000..98d5a60 --- /dev/null +++ b/Resources/joystick.plist @@ -0,0 +1,74 @@ + + + + + frames + + Ball.png + + frame + {{186,2},{50,50}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{50,50}} + sourceSize + {50,50} + + Ball_hl.png + + frame + {{134,2},{50,50}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{50,50}} + sourceSize + {50,50} + + Dock.png + + frame + {{2,134},{130,130}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{130,130}} + sourceSize + {130,130} + + Dock_hl.png + + frame + {{2,2},{130,130}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{130,130}} + sourceSize + {130,130} + + + metadata + + format + 2 + realTextureFileName + joystick.png + size + {256,512} + smartupdate + $TexturePacker:SmartUpdate:bdfb5eb9edba11c8a3f2e431d6dded2d:1/1$ + textureFileName + joystick.png + + + diff --git a/Resources/joystick.png b/Resources/joystick.png new file mode 100755 index 0000000..15ad6b4 Binary files /dev/null and b/Resources/joystick.png differ diff --git a/Resources/main.plist b/Resources/main.plist new file mode 100755 index 0000000..655a7bc --- /dev/null +++ b/Resources/main.plist @@ -0,0 +1,399 @@ + + + + + frames + + commons_btn_back_01.png + + frame + {{122,350},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_01_cnt.png + + frame + {{122,350},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_02.png + + frame + {{122,280},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_02_cnt.png + + frame + {{122,280},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_03.png + + frame + {{188,437},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_back_04.png + + frame + {{188,371},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_back_05.png + + frame + {{122,420},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_cancel_01.png + + frame + {{122,210},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_01_cnt.png + + frame + {{122,210},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_02.png + + frame + {{122,140},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_02_cnt.png + + frame + {{122,140},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_close.png + + frame + {{421,5},{18,16}} + offset + {0,0} + rotated + + sourceColorRect + {{7,8},{18,16}} + sourceSize + {32,32} + + gui_battle_progress_bar01_a.png + + frame + {{41,104},{403,37}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{403,37}} + sourceSize + {403,37} + + gui_battle_progress_bar01_b.png + + frame + {{2,104},{403,37}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{403,37}} + sourceSize + {403,37} + + gui_hand.png + + frame + {{351,39},{150,116}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{150,116}} + sourceSize + {150,116} + + gui_separate.png + + frame + {{504,2},{1,100}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{1,100}} + sourceSize + {1,100} + + gui_setting_slider.png + + frame + {{450,2},{52,35}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{52,35}} + sourceSize + {52,35} + + gui_setting_slider_bg.png + + frame + {{80,157},{330,40}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{330,40}} + sourceSize + {330,40} + + gui_window01.png + + frame + {{2,5},{347,91}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{347,91}} + sourceSize + {347,91} + + gui_window02.png + + frame + {{150,98},{271,196}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{271,196}} + sourceSize + {271,196} + + separate.png + + frame + {{2,2},{446,1}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{446,1}} + sourceSize + {446,1} + + settings_btn_default_01.png + + frame + {{80,119},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_01_cnt.png + + frame + {{80,98},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_02.png + + frame + {{80,489},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_02_cnt.png + + frame + {{351,5},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + start_btn_left_01.png + + frame + {{94,140},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_left_02.png + + frame + {{80,140},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_right_01.png + + frame + {{435,23},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_right_02.png + + frame + {{421,23},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + + metadata + + format + 2 + realTextureFileName + main.png + size + {512,512} + smartupdate + $TexturePacker:SmartUpdate:bc5c1e7831f1dd2a30267cbbc66b73f5:1/1$ + textureFileName + main.png + + + diff --git a/Resources/main.png b/Resources/main.png new file mode 100755 index 0000000..32caf08 Binary files /dev/null and b/Resources/main.png differ diff --git a/Resources/map.png b/Resources/map.png new file mode 100755 index 0000000..ff3fb46 Binary files /dev/null and b/Resources/map.png differ diff --git a/Resources/map_01.tmx b/Resources/map_01.tmx new file mode 100755 index 0000000..8011fab --- /dev/null +++ b/Resources/map_01.tmx @@ -0,0 +1,53 @@ + + + + + + + + eJy7yMDAcIkMfItMfSB8GYgfAjETnfFjIu1VJ9HcFVSylxKMzc30sJfa/iU17Ie6fwfC3u1AvIOAmhVYMLK95Lj3OBCfGKThTMi/tLJXHA3Ty78gu5ihmJb2oudnetk7UP6lNH5XYNGDnBYbgbgJDTeT6CZy/LsQiBeh4cV0sJcaGGTvRyD+RGf8GYgBkXJsEg== + + + + + eJztyzkNAAAMw8Dyx9kPRkMha+WTPDrCk6pUq1Fr/gAAAN8dLU8Efw== + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Resources/map_02.tmx b/Resources/map_02.tmx new file mode 100755 index 0000000..5293798 --- /dev/null +++ b/Resources/map_02.tmx @@ -0,0 +1,36 @@ + + + + + + + + eJxbzsDAsHyAMBOd8WCxdwUOdbjEB7N/sbl5sITzYLWXUDwTmw6Gin+pbfdI8e9gtpfSNLwCi5rB7N9Re4e+vQOBAdFRR8I= + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Resources/map_03.tmx b/Resources/map_03.tmx new file mode 100755 index 0000000..92ce86d --- /dev/null +++ b/Resources/map_03.tmx @@ -0,0 +1,30 @@ + + + + + + + + eJyrYWBg8ANifyCuIQKvhmJfJLE9QBwHxPFA3EME3g3FsVD+XiA+SQH2BGIvCs2IBOIoCs3IBOIsCs0YKTgbiL2B2AeIcygwIxqIYygwgxDOHwRhRSo+DcRngPgsAXUAqnu43Q== + + + + + + + + + + + + + + + + + + + + + + diff --git a/Resources/map_menu1_style1.tmx b/Resources/map_menu1_style1.tmx new file mode 100755 index 0000000..a894dba --- /dev/null +++ b/Resources/map_menu1_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJztw0ENAAAMA6HzU//+pmF/SFg1VVVVVVVVVVVV3w+e5ZMw + + + + + eJztzzEKgDAQBdFtIjaCjWXQ+5/SeIRPmgnOhy0H9rWq2ha6fVybaI9aa+e4a6LVy57erNXLnt6s1cue3qzVy57erNXLnt6s1cue3qzVy57erNXLnt6s1cue3qzVy57erNXLnt6s1cue3qz9m7ePuxe6Z+Lnr30BS1oSeQ== + + + diff --git a/Resources/map_menu2_style1.tmx b/Resources/map_menu2_style1.tmx new file mode 100755 index 0000000..ca527cc --- /dev/null +++ b/Resources/map_menu2_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJztwzENAEAIBLDTwvr418eKgJ9Im7STtKqq3z5PL1VVVVVVVV0HugBaeA== + + + + + eJztmTEKgDAUQ/9SdRFcHNXe/5TWwRsEDUkeZA3/DaX9tFXVZJJlZC0ftoqvMo6++99DfEh8tXH0PUZOk/SRVtj3y9M3kwb9vmK/39DzxZeL+HL1oYkvVx+a+HL1oYkvVx+a+HL1oXn3wQuUDu5D55mPeX9j3wfZYT9vaOKrTXy1ia828dUmvto4+rr9D95Beh9k + + + diff --git a/Resources/map_menu3_style1.tmx b/Resources/map_menu3_style1.tmx new file mode 100755 index 0000000..34752cb --- /dev/null +++ b/Resources/map_menu3_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJztw0ENAAAMA6HzU//+pmF/SFg1VVVVVVVVVVVV3w+e5ZMw + + + + + eJztz7ENACEQxMBNeBGSEL6g/yq5OnweyQV4JPmaNKudPlb8JfOXzV82f9n8ZfOXzV82f9n8ZfOXzV82f9n8ZfOXzV82f9n8ZfOXrePvX50m3eoBOiUOKw== + + + diff --git a/Resources/map_menu4_style1.tmx b/Resources/map_menu4_style1.tmx new file mode 100755 index 0000000..9eeb9fa --- /dev/null +++ b/Resources/map_menu4_style1.tmx @@ -0,0 +1,16 @@ + + + + + + + + eJztwzENAEAIBLDTwvr418eKgJ9Im7STtKqq3z5PL1VVVVVVVV0HugBaeA== + + + + + eJztmDsKgDAQRLfx0wg2go2S+5/SeIa86JCdB9MO+4rENVNEzEmy1myRhz3sOzIZfY+/h/gQ+45NRt+r5k6SUjMFu7+8fYto6P1K/ftGz2dfLeyr1UdjX60+Gvtq9dH08FXeT0sHX++TOtD/g+q+Z7C+dB+NfbX6aN75yPOm7kvfL/bVwr5t2FcL+7ZhXy3s24Z9taDfXwrc1+M95wFush8r + + + diff --git a/Resources/monsters.plist b/Resources/monsters.plist new file mode 100755 index 0000000..d1e7460 --- /dev/null +++ b/Resources/monsters.plist @@ -0,0 +1,1868 @@ + + + + + frames + + bufle-marteau.png + + frame + {{153,2},{129,121}} + offset + {-3,-5} + rotated + + sourceColorRect + {{0,12},{129,121}} + sourceSize + {135,135} + + cactus.png + + frame + {{299,723},{51,109}} + offset + {1,-1} + rotated + + sourceColorRect + {{8,4},{51,109}} + sourceSize + {65,115} + + cactus1.png + + frame + {{613,571},{34,65}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{34,65}} + sourceSize + {34,65} + + cadeau7.png + + frame + {{349,944},{65,77}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{65,77}} + sourceSize + {67,79} + + cape-grise.png + + frame + {{70,681},{40,101}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{40,101}} + sourceSize + {42,103} + + capitaine-jambe-bois.png + + frame + {{2,851},{60,116}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{60,116}} + sourceSize + {60,116} + + champignon.png + + frame + {{641,887},{49,54}} + offset + {0,0} + rotated + + sourceColorRect + {{3,3},{49,54}} + sourceSize + {55,60} + + chat-baluchon.png + + frame + {{465,607},{65,89}} + offset + {0,1} + rotated + + sourceColorRect + {{10,2},{65,89}} + sourceSize + {85,95} + + chat.png + + frame + {{619,474},{57,63}} + offset + {-3,-1} + rotated + + sourceColorRect + {{6,7},{57,63}} + sourceSize + {75,75} + + chauve-souris-feu.png + + frame + {{195,949},{73,50}} + offset + {0,3} + rotated + + sourceColorRect + {{0,9},{73,50}} + sourceSize + {73,74} + + chauve-souris-violet.png + + frame + {{631,638},{46,32}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{46,32}} + sourceSize + {46,32} + + chauve_souris_archer.png + + frame + {{470,121},{93,67}} + offset + {-1,-1} + rotated + + sourceColorRect + {{5,10},{93,67}} + sourceSize + {105,85} + + chef-chine.png + + frame + {{631,2},{31,88}} + offset + {1,1} + rotated + + sourceColorRect + {{13,1},{31,88}} + sourceSize + {55,92} + + chef-chine2.png + + frame + {{544,309},{34,90}} + offset + {2,2} + rotated + + sourceColorRect + {{5,1},{34,90}} + sourceSize + {40,96} + + chef-chine3.png + + frame + {{202,133},{36,83}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{36,83}} + sourceSize + {36,83} + + chef-coreen.png + + frame + {{247,949},{72,100}} + offset + {-1,-1} + rotated + + sourceColorRect + {{2,2},{72,100}} + sourceSize + {78,102} + + chef-indien.png + + frame + {{620,211},{57,74}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{57,74}} + sourceSize + {59,76} + + chef-vert.png + + frame + {{2,412},{62,160}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{62,160}} + sourceSize + {62,160} + + chenille1.png + + frame + {{571,744},{68,40}} + offset + {4,0} + rotated + + sourceColorRect + {{20,5},{68,40}} + sourceSize + {100,50} + + chevaier-casque.png + + frame + {{2,969},{53,102}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{53,102}} + sourceSize + {55,104} + + cheval-feu.png + + frame + {{2,723},{93,126}} + offset + {-1,-1} + rotated + + sourceColorRect + {{3,4},{93,126}} + sourceSize + {101,132} + + cheval_feu.png + + frame + {{276,2},{96,127}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{96,127}} + sourceSize + {98,129} + + chevalier_blanc.png + + frame + {{2,2},{149,214}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{149,214}} + sourceSize + {151,216} + + chien-arc.png + + frame + {{707,734},{50,55}} + offset + {2,-2} + rotated + + sourceColorRect + {{14,13},{50,55}} + sourceSize + {74,77} + + chien-diamant.png + + frame + {{772,375},{56,53}} + offset + {0,-1} + rotated + + sourceColorRect + {{1,3},{56,53}} + sourceSize + {58,57} + + chien-fou.png + + frame + {{640,816},{69,63}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{69,63}} + sourceSize + {71,65} + + chien-glace.png + + frame + {{139,555},{121,102}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{121,102}} + sourceSize + {123,104} + + chien-glace53.png + + frame + {{611,304},{74,61}} + offset + {-1,0} + rotated + + sourceColorRect + {{12,12},{74,61}} + sourceSize + {100,85} + + chien-pointu.png + + frame + {{684,938},{67,44}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{67,44}} + sourceSize + {67,44} + + chien.png + + frame + {{747,564},{35,35}} + offset + {2,1} + rotated + + sourceColorRect + {{12,9},{35,35}} + sourceSize + {55,55} + + chinois-coupant.png + + frame + {{479,315},{63,91}} + offset + {-1,1} + rotated + + sourceColorRect + {{1,1},{63,91}} + sourceSize + {67,95} + + chose-volante.png + + frame + {{734,411},{36,58}} + offset + {-3,3} + rotated + + sourceColorRect + {{15,10},{36,58}} + sourceSize + {72,84} + + chose-volante2.png + + frame + {{699,601},{35,48}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{35,48}} + sourceSize + {35,48} + + chose3.png + + frame + {{572,638},{32,57}} + offset + {-2,2} + rotated + + sourceColorRect + {{7,2},{32,57}} + sourceSize + {50,65} + + chun-li.png + + frame + {{459,722},{57,95}} + offset + {9,3} + rotated + + sourceColorRect + {{23,7},{57,95}} + sourceSize + {85,115} + + cloporte-evolue.png + + frame + {{679,638},{44,32}} + offset + {3,0} + rotated + + sourceColorRect + {{14,14},{44,32}} + sourceSize + {66,60} + + cloporte.png + + frame + {{243,646},{30,24}} + offset + {5,-1} + rotated + + sourceColorRect + {{15,14},{30,24}} + sourceSize + {50,50} + + clown-jongleur.png + + frame + {{70,555},{67,124}} + offset + {-2,-1} + rotated + + sourceColorRect + {{2,4},{67,124}} + sourceSize + {75,130} + + clown.png + + frame + {{548,401},{38,89}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{38,89}} + sourceSize + {40,91} + + cocci.png + + frame + {{309,623},{22,21}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{22,21}} + sourceSize + {22,21} + + cochon-marron-canine.png + + frame + {{798,661},{42,42}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{42,42}} + sourceSize + {42,42} + + cochon-rose-canine.png + + frame + {{741,840},{44,42}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{44,42}} + sourceSize + {44,42} + + coffre-yeux.png + + frame + {{709,564},{35,36}} + offset + {1,-2} + rotated + + sourceColorRect + {{7,8},{35,36}} + sourceSize + {47,48} + + corne.png + + frame + {{784,530},{39,57}} + offset + {4,2} + rotated + + sourceColorRect + {{12,12},{39,57}} + sourceSize + {55,85} + + coulis.png + + frame + {{628,938},{54,80}} + offset + {-1,2} + rotated + + sourceColorRect + {{1,1},{54,80}} + sourceSize + {58,86} + + crabe89.png + + frame + {{539,121},{90,52}} + offset + {0,1} + rotated + + sourceColorRect + {{6,8},{90,52}} + sourceSize + {102,70} + + femme-vert-hache.png + + frame + {{497,408},{49,90}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{49,90}} + sourceSize + {51,92} + + femme-vert-hache1.png + + frame + {{518,698},{51,86}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{51,86}} + sourceSize + {51,86} + + fenetre_et_ombre.png + + frame + {{545,2},{88,84}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{88,84}} + sourceSize + {88,84} + + feraille.png + + frame + {{127,218},{131,121}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{131,121}} + sourceSize + {131,121} + + feuillage.png + + frame + {{811,589},{39,39}} + offset + {0,5} + rotated + + sourceColorRect + {{0,1},{39,39}} + sourceSize + {39,51} + + fille_et_monstre.png + + frame + {{272,646},{75,92}} + offset + {2,1} + rotated + + sourceColorRect + {{7,3},{75,92}} + sourceSize + {85,100} + + fourmi.png + + frame + {{725,638},{40,32}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{40,32}} + sourceSize + {42,34} + + fourmi2.png + + frame + {{518,786},{49,31}} + offset + {0,-1} + rotated + + sourceColorRect + {{3,13},{49,31}} + sourceSize + {55,55} + + garcon-roux.png + + frame + {{811,488},{49,39}} + offset + {1,3} + rotated + + sourceColorRect + {{5,4},{49,39}} + sourceSize + {57,53} + + garde-royal.png + + frame + {{366,623},{30,98}} + offset + {-2,0} + rotated + + sourceColorRect + {{6,2},{30,98}} + sourceSize + {46,102} + + golem-epees.png + + frame + {{2,218},{123,192}} + offset + {1,0} + rotated + + sourceColorRect + {{8,4},{123,192}} + sourceSize + {137,200} + + golem-vieux.png + + frame + {{697,887},{49,49}} + offset + {1,1} + rotated + + sourceColorRect + {{4,2},{49,49}} + sourceSize + {55,55} + + grande-dent.png + + frame + {{748,317},{54,56}} + offset + {0,-4} + rotated + + sourceColorRect + {{1,9},{54,56}} + sourceSize + {56,66} + + grenouille-vert.png + + frame + {{741,786},{44,52}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{44,52}} + sourceSize + {44,52} + + grizzli.png + + frame + {{243,535},{64,109}} + offset + {1,0} + rotated + + sourceColorRect + {{8,3},{64,109}} + sourceSize + {78,115} + + gros-lutin-lance.png + + frame + {{564,819},{74,80}} + offset + {0,1} + rotated + + sourceColorRect + {{4,4},{74,80}} + sourceSize + {82,90} + + gros-poisson.png + + frame + {{546,938},{80,82}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{80,82}} + sourceSize + {82,84} + + hache.png + + frame + {{106,966},{56,87}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{56,87}} + sourceSize + {58,89} + + halloween.png + + frame + {{153,133},{47,83}} + offset + {0,-1} + rotated + + sourceColorRect + {{19,7},{47,83}} + sourceSize + {85,95} + + herisson-2.png + + frame + {{504,908},{42,28}} + offset + {4,3} + rotated + + sourceColorRect + {{15,14},{42,28}} + sourceSize + {64,62} + + hibou.png + + frame + {{649,601},{35,48}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{35,48}} + sourceSize + {35,48} + + hypocampe.png + + frame + {{642,672},{47,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{47,64}} + sourceSize + {47,64} + + hérisson-3.png + + frame + {{808,705},{38,38}} + offset + {1,2} + rotated + + sourceColorRect + {{14,11},{38,38}} + sourceSize + {64,64} + + hérisson.png + + frame + {{610,786},{32,28}} + offset + {2,3} + rotated + + sourceColorRect + {{11,8},{32,28}} + sourceSize + {50,50} + + indien-epee.png + + frame + {{630,121},{53,72}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{53,72}} + sourceSize + {55,74} + + indien.png + + frame + {{572,571},{39,65}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{39,65}} + sourceSize + {41,67} + + indien1.png + + frame + {{588,395},{44,77}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{44,77}} + sourceSize + {46,79} + + insecte9.png + + frame + {{606,92},{43,27}} + offset + {1,0} + rotated + + sourceColorRect + {{2,1},{43,27}} + sourceSize + {45,29} + + lapin.png + + frame + {{507,938},{37,84}} + offset + {1,1} + rotated + + sourceColorRect + {{5,2},{37,84}} + sourceSize + {45,90} + + lezard-col.png + + frame + {{758,471},{57,51}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{57,51}} + sourceSize + {57,51} + + lezard-langue.png + + frame + {{751,672},{60,45}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{60,45}} + sourceSize + {62,47} + + libellule.png + + frame + {{787,786},{51,51}} + offset + {1,4} + rotated + + sourceColorRect + {{9,2},{51,51}} + sourceSize + {67,63} + + limace1.png + + frame + {{548,908},{34,28}} + offset + {-2,1} + rotated + + sourceColorRect + {{1,5},{34,28}} + sourceSize + {40,40} + + linux....png + + frame + {{641,744},{40,64}} + offset + {0,-2} + rotated + + sourceColorRect + {{15,10},{40,64}} + sourceSize + {70,80} + + lion-sable.png + + frame + {{285,339},{60,70}} + offset + {4,1} + rotated + + sourceColorRect + {{14,4},{60,70}} + sourceSize + {80,80} + + livre-dent.png + + frame + {{569,786},{39,29}} + offset + {0,-3} + rotated + + sourceColorRect + {{8,16},{39,29}} + sourceSize + {55,55} + + lol.png + + frame + {{403,512},{39,95}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{39,95}} + sourceSize + {41,97} + + lol2.png + + frame + {{593,121},{35,88}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{35,88}} + sourceSize + {37,90} + + loup-boule-piquant.png + + frame + {{679,195},{58,60}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{58,60}} + sourceSize + {58,60} + + loup-bracelet-piquant.png + + frame + {{240,133},{82,108}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{82,108}} + sourceSize + {82,108} + + loup-garou-orange.png + + frame + {{97,723},{65,112}} + offset + {0,1} + rotated + + sourceColorRect + {{2,0},{65,112}} + sourceSize + {69,114} + + loup-garou-rose.png + + frame + {{232,723},{65,109}} + offset + {1,-3} + rotated + + sourceColorRect + {{11,6},{65,109}} + sourceSize + {85,115} + + loup-garou5.png + + frame + {{263,834},{64,109}} + offset + {-7,0} + rotated + + sourceColorRect + {{0,0},{64,109}} + sourceSize + {78,109} + + loup-hache.png + + frame + {{634,380},{62,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{62,58}} + sourceSize + {62,58} + + loup-long-poils.png + + frame + {{350,131},{84,118}} + offset + {-2,0} + rotated + + sourceColorRect + {{3,1},{84,118}} + sourceSize + {94,120} + + loup-marteau.png + + frame + {{691,672},{60,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{60,58}} + sourceSize + {60,58} + + lutin-boule-piquant.png + + frame + {{678,444},{54,58}} + offset + {2,2} + rotated + + sourceColorRect + {{6,3},{54,58}} + sourceSize + {62,68} + + lutin-couteau-bouclier.png + + frame + {{767,601},{42,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{42,58}} + sourceSize + {42,58} + + lutin-hache-bouclier.png + + frame + {{710,257},{52,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{52,58}} + sourceSize + {52,58} + + lutin-helicoptere.png + + frame + {{412,831},{105,90}} + offset + {-3,-6} + rotated + + sourceColorRect + {{10,22},{105,90}} + sourceSize + {131,122} + + lutin-marteau-bouclier.png + + frame + {{694,351},{52,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{52,58}} + sourceSize + {52,58} + + lutin-sourire-diabolique.png + + frame + {{563,492},{54,77}} + offset + {-1,3} + rotated + + sourceColorRect + {{10,4},{54,77}} + sourceSize + {76,91} + + lutin25.png + + frame + {{674,287},{34,62}} + offset + {2,1} + rotated + + sourceColorRect + {{14,5},{34,62}} + sourceSize + {58,74} + + lutin54.png + + frame + {{649,539},{60,58}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{60,58}} + sourceSize + {60,58} + + lutin56.png + + frame + {{709,504},{47,58}} + offset + {1,-1} + rotated + + sourceColorRect + {{5,2},{47,58}} + sourceSize + {55,60} + + mage-chapeau_pointu.png + + frame + {{532,591},{38,80}} + offset + {9,2} + rotated + + sourceColorRect + {{30,8},{38,80}} + sourceSize + {80,100} + + mage-puissant.png + + frame + {{164,723},{66,110}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{66,110}} + sourceSize + {68,112} + + mage-puissant2.png + + frame + {{297,411},{66,105}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{66,105}} + sourceSize + {68,107} + + mageanimal.png + + frame + {{580,304},{29,89}} + offset + {-2,1} + rotated + + sourceColorRect + {{6,2},{29,89}} + sourceSize + {45,95} + + main momie.png + + frame + {{329,834},{81,108}} + offset + {-4,4} + rotated + + sourceColorRect + {{2,3},{81,108}} + sourceSize + {93,122} + + mamy-indien.png + + frame + {{545,92},{27,59}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{27,59}} + sourceSize + {29,61} + + marionette-bougie.png + + frame + {{127,351},{59,89}} + offset + {3,1} + rotated + + sourceColorRect + {{16,2},{59,89}} + sourceSize + {85,95} + + masque.png + + frame + {{444,512},{66,93}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{66,93}} + sourceSize + {68,95} + + mechant-loup.png + + frame + {{218,351},{65,59}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{65,59}} + sourceSize + {67,61} + + mechante-grenouille.png + + frame + {{785,840},{46,42}} + offset + {1,-1} + rotated + + sourceColorRect + {{5,5},{46,42}} + sourceSize + {54,50} + + meduse-blanche.png + + frame + {{584,901},{35,55}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{35,55}} + sourceSize + {35,55} + + mille-pattes.png + + frame + {{173,678},{97,43}} + offset + {5,2} + rotated + + sourceColorRect + {{14,4},{97,43}} + sourceSize + {115,55} + + mini-pieuvre.png + + frame + {{748,886},{46,49}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{46,49}} + sourceSize + {46,49} + + momie24.png + + frame + {{512,500},{49,89}} + offset + {6,0} + rotated + + sourceColorRect + {{22,6},{49,89}} + sourceSize + {81,101} + + momie25.png + + frame + {{434,323},{43,85}} + offset + {6,2} + rotated + + sourceColorRect + {{17,3},{43,85}} + sourceSize + {65,95} + + momie7.png + + frame + {{508,216},{42,91}} + offset + {2,-2} + rotated + + sourceColorRect + {{15,6},{42,91}} + sourceSize + {68,99} + + monstre-bleu-marteau.png + + frame + {{398,623},{65,97}} + offset + {-1,1} + rotated + + sourceColorRect + {{3,1},{65,97}} + sourceSize + {73,101} + + monstre-bottes.png + + frame + {{374,2},{90,118}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{90,118}} + sourceSize + {90,118} + + monstre-casque-a-cornes.png + + frame + {{446,410},{49,93}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{49,93}} + sourceSize + {51,95} + + monstre-chapeau-noel.png + + frame + {{730,938},{42,67}} + offset + {6,-1} + rotated + + sourceColorRect + {{19,5},{42,67}} + sourceSize + {68,75} + + monstre-de-la-mort.png + + frame + {{2,574},{66,147}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{66,147}} + sourceSize + {66,147} + + monstre-horloge.png + + frame + {{466,2},{77,117}} + offset + {2,5} + rotated + + sourceColorRect + {{8,0},{77,117}} + sourceSize + {89,127} + + monstre-lance.png + + frame + {{416,938},{89,84}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{89,84}} + sourceSize + {89,84} + + monstre-masque-mort.png + + frame + {{154,837},{107,110}} + offset + {0,1} + rotated + + sourceColorRect + {{4,4},{107,110}} + sourceSize + {115,120} + + monstre-mirroir.png + + frame + {{352,723},{105,106}} + offset + {1,-2} + rotated + + sourceColorRect + {{4,7},{105,106}} + sourceSize + {111,116} + + monstre-pinces.png + + frame + {{764,734},{50,42}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{50,42}} + sourceSize + {50,42} + + monstre-prisonnier.png + + frame + {{347,339},{69,85}} + offset + {0,0} + rotated + + sourceColorRect + {{0,2},{69,85}} + sourceSize + {69,89} + + monstre-qui-degouline.png + + frame + {{363,217},{76,104}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{76,104}} + sourceSize + {78,106} + + monstre-reine.png + + frame + {{66,412},{141,133}} + offset + {0,0} + rotated + + sourceColorRect + {{1,1},{141,133}} + sourceSize + {143,135} + + monstre-rocher.png + + frame + {{705,786},{34,67}} + offset + {1,1} + rotated + + sourceColorRect + {{9,3},{34,67}} + sourceSize + {50,75} + + monstre-rouge.png + + frame + {{825,529},{37,39}} + offset + {1,0} + rotated + + sourceColorRect + {{2,0},{37,39}} + sourceSize + {39,39} + + monstre-sable.png + + frame + {{811,433},{40,53}} + offset + {1,0} + rotated + + sourceColorRect + {{15,9},{40,53}} + sourceSize + {68,71} + + monstre-serpents.png + + frame + {{250,217},{111,120}} + offset + {3,3} + rotated + + sourceColorRect + {{11,6},{111,120}} + sourceSize + {127,138} + + monstre-vert-arc.png + + frame + {{552,213},{66,89}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{66,89}} + sourceSize + {66,89} + + monstre-vert-corne.png + + frame + {{365,410},{79,100}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{79,100}} + sourceSize + {79,100} + + monstre-vert-marteau.png + + frame + {{441,217},{65,96}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{65,96}} + sourceSize + {65,96} + + mort et canne.png + + frame + {{309,518},{92,103}} + offset + {1,1} + rotated + + sourceColorRect + {{5,4},{92,103}} + sourceSize + {100,113} + + mort volant.png + + frame + {{201,412},{94,121}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{94,121}} + sourceSize + {94,121} + + mort volante.png + + frame + {{571,673},{69,69}} + offset + {0,1} + rotated + + sourceColorRect + {{9,17},{69,69}} + sourceSize + {87,105} + + mort-acher.png + + frame + {{504,819},{58,87}} + offset + {1,-1} + rotated + + sourceColorRect + {{7,5},{58,87}} + sourceSize + {70,95} + + mort-pepe.png + + frame + {{64,851},{88,113}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{88,113}} + sourceSize + {88,113} + + + metadata + + format + 2 + realTextureFileName + monsters.png + size + {1024,1024} + smartupdate + $TexturePacker:SmartUpdate:90c710a084a762a0c15d535f14cbb467:1/1$ + textureFileName + monsters.png + + + diff --git a/Resources/monsters.png b/Resources/monsters.png new file mode 100755 index 0000000..3b641d9 Binary files /dev/null and b/Resources/monsters.png differ diff --git a/Resources/scene_battle_cns.plist b/Resources/scene_battle_cns.plist new file mode 100755 index 0000000..ec1cc61 --- /dev/null +++ b/Resources/scene_battle_cns.plist @@ -0,0 +1,20 @@ + + + + + escape_success + 逃跑成功 + escape_fail + 逃跑失败 + battle_playermenu_attack + 攻击 + battle_playermenu_defense + 防御 + battle_playermenu_skill + 技能 + battle_playermenu_items + 道具 + battle_playermenu_escape + 逃跑 + + diff --git a/Resources/scene_loading_cns.plist b/Resources/scene_loading_cns.plist new file mode 100755 index 0000000..e438b42 --- /dev/null +++ b/Resources/scene_loading_cns.plist @@ -0,0 +1,8 @@ + + + + + loading + 正在读取中... + + diff --git a/Resources/scene_map_cns.plist b/Resources/scene_map_cns.plist new file mode 100755 index 0000000..fc9d1f1 --- /dev/null +++ b/Resources/scene_map_cns.plist @@ -0,0 +1,48 @@ + + + + + status_equip_arms + 武器:%s + status_equip_armor + 防具:%s + status_name + 名字:%s + status_level + Level:%i (Next:%i) + status_hp + HP:%i / %i + status_mp + MP:%i / %i + status_attack + 攻击:%i + status_defense + 防御:%i + status_speed + 速度:%i + status_magic_attack + 魔攻:%i + status_magic_defense + 魔防:%i + confirm_exit_ok + 确定 + confirm_cancel + 取消 + confirm_exit + 退出游戏返回到初始界面。 + menu_back + 后退 + menu_close + 关闭 + menu_exit + 退出 + menu_skill + 技能 + menu_status + 状态 + menu_items + 道具 + menu_equip + 装备 + + diff --git a/Resources/scene_start_cns.plist b/Resources/scene_start_cns.plist new file mode 100755 index 0000000..85200ca --- /dev/null +++ b/Resources/scene_start_cns.plist @@ -0,0 +1,16 @@ + + + + + confirm_ok + 确定 + confirm_cancel + 取消 + confirm_delete + 确定删除之前的进度吗? + menuitem_start + 继续游戏 + menuitem_delete + 重新开始 + + diff --git a/Resources/start_bg.png b/Resources/start_bg.png new file mode 100755 index 0000000..a9d5baa Binary files /dev/null and b/Resources/start_bg.png differ diff --git a/Resources/方正粗圆简体.ttf b/Resources/方正粗圆简体.ttf new file mode 100755 index 0000000..ec8c537 Binary files /dev/null and b/Resources/方正粗圆简体.ttf differ diff --git a/_images/Ball.png b/_images/Ball.png new file mode 100755 index 0000000..366b557 Binary files /dev/null and b/_images/Ball.png differ diff --git a/_images/Ball_hl.png b/_images/Ball_hl.png new file mode 100755 index 0000000..a32838c Binary files /dev/null and b/_images/Ball_hl.png differ diff --git a/_images/Dock.png b/_images/Dock.png new file mode 100755 index 0000000..adc1042 Binary files /dev/null and b/_images/Dock.png differ diff --git a/_images/Dock_hl.png b/_images/Dock_hl.png new file mode 100755 index 0000000..40ab4f9 Binary files /dev/null and b/_images/Dock_hl.png differ diff --git a/_images/main/commons_btn_back_01.png b/_images/main/commons_btn_back_01.png new file mode 100755 index 0000000..b42cc78 Binary files /dev/null and b/_images/main/commons_btn_back_01.png differ diff --git a/_images/main/commons_btn_back_01_cnt.png b/_images/main/commons_btn_back_01_cnt.png new file mode 100755 index 0000000..b42cc78 Binary files /dev/null and b/_images/main/commons_btn_back_01_cnt.png differ diff --git a/_images/main/commons_btn_back_02.png b/_images/main/commons_btn_back_02.png new file mode 100755 index 0000000..ac870d7 Binary files /dev/null and b/_images/main/commons_btn_back_02.png differ diff --git a/_images/main/commons_btn_back_02_cnt.png b/_images/main/commons_btn_back_02_cnt.png new file mode 100755 index 0000000..ac870d7 Binary files /dev/null and b/_images/main/commons_btn_back_02_cnt.png differ diff --git a/_images/main/commons_btn_back_03.png b/_images/main/commons_btn_back_03.png new file mode 100755 index 0000000..051c041 Binary files /dev/null and b/_images/main/commons_btn_back_03.png differ diff --git a/_images/main/commons_btn_back_04.png b/_images/main/commons_btn_back_04.png new file mode 100755 index 0000000..c5a2dc9 Binary files /dev/null and b/_images/main/commons_btn_back_04.png differ diff --git a/_images/main/commons_btn_back_05.png b/_images/main/commons_btn_back_05.png new file mode 100755 index 0000000..a22df47 Binary files /dev/null and b/_images/main/commons_btn_back_05.png differ diff --git a/_images/main/commons_btn_cancel_01.png b/_images/main/commons_btn_cancel_01.png new file mode 100755 index 0000000..4f77196 Binary files /dev/null and b/_images/main/commons_btn_cancel_01.png differ diff --git a/_images/main/commons_btn_cancel_01_cnt.png b/_images/main/commons_btn_cancel_01_cnt.png new file mode 100755 index 0000000..4f77196 Binary files /dev/null and b/_images/main/commons_btn_cancel_01_cnt.png differ diff --git a/_images/main/commons_btn_cancel_02.png b/_images/main/commons_btn_cancel_02.png new file mode 100755 index 0000000..9912caa Binary files /dev/null and b/_images/main/commons_btn_cancel_02.png differ diff --git a/_images/main/commons_btn_cancel_02_cnt.png b/_images/main/commons_btn_cancel_02_cnt.png new file mode 100755 index 0000000..9912caa Binary files /dev/null and b/_images/main/commons_btn_cancel_02_cnt.png differ diff --git a/_images/main/commons_btn_close.png b/_images/main/commons_btn_close.png new file mode 100755 index 0000000..58f233d Binary files /dev/null and b/_images/main/commons_btn_close.png differ diff --git a/_images/main/gui_battle_progress_bar01_a.png b/_images/main/gui_battle_progress_bar01_a.png new file mode 100755 index 0000000..2a3bd39 Binary files /dev/null and b/_images/main/gui_battle_progress_bar01_a.png differ diff --git a/_images/main/gui_battle_progress_bar01_b.png b/_images/main/gui_battle_progress_bar01_b.png new file mode 100755 index 0000000..64af40e Binary files /dev/null and b/_images/main/gui_battle_progress_bar01_b.png differ diff --git a/_images/main/gui_hand.png b/_images/main/gui_hand.png new file mode 100755 index 0000000..f809f4b Binary files /dev/null and b/_images/main/gui_hand.png differ diff --git a/_images/main/gui_separate.png b/_images/main/gui_separate.png new file mode 100755 index 0000000..0dac55c Binary files /dev/null and b/_images/main/gui_separate.png differ diff --git a/_images/main/gui_setting_slider.png b/_images/main/gui_setting_slider.png new file mode 100755 index 0000000..ec93b8d Binary files /dev/null and b/_images/main/gui_setting_slider.png differ diff --git a/_images/main/gui_setting_slider_bg.png b/_images/main/gui_setting_slider_bg.png new file mode 100755 index 0000000..f98e923 Binary files /dev/null and b/_images/main/gui_setting_slider_bg.png differ diff --git a/_images/main/gui_window01.png b/_images/main/gui_window01.png new file mode 100755 index 0000000..61df7c8 Binary files /dev/null and b/_images/main/gui_window01.png differ diff --git a/_images/main/gui_window02.png b/_images/main/gui_window02.png new file mode 100755 index 0000000..45e49b7 Binary files /dev/null and b/_images/main/gui_window02.png differ diff --git a/_images/main/main.plist b/_images/main/main.plist new file mode 100755 index 0000000..655a7bc --- /dev/null +++ b/_images/main/main.plist @@ -0,0 +1,399 @@ + + + + + frames + + commons_btn_back_01.png + + frame + {{122,350},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_01_cnt.png + + frame + {{122,350},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_02.png + + frame + {{122,280},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_02_cnt.png + + frame + {{122,280},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_back_03.png + + frame + {{188,437},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_back_04.png + + frame + {{188,371},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_back_05.png + + frame + {{122,420},{64,64}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{64,64}} + sourceSize + {64,64} + + commons_btn_cancel_01.png + + frame + {{122,210},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_01_cnt.png + + frame + {{122,210},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_02.png + + frame + {{122,140},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_cancel_02_cnt.png + + frame + {{122,140},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + commons_btn_close.png + + frame + {{421,5},{18,16}} + offset + {0,0} + rotated + + sourceColorRect + {{7,8},{18,16}} + sourceSize + {32,32} + + gui_battle_progress_bar01_a.png + + frame + {{41,104},{403,37}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{403,37}} + sourceSize + {403,37} + + gui_battle_progress_bar01_b.png + + frame + {{2,104},{403,37}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{403,37}} + sourceSize + {403,37} + + gui_hand.png + + frame + {{351,39},{150,116}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{150,116}} + sourceSize + {150,116} + + gui_separate.png + + frame + {{504,2},{1,100}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{1,100}} + sourceSize + {1,100} + + gui_setting_slider.png + + frame + {{450,2},{52,35}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{52,35}} + sourceSize + {52,35} + + gui_setting_slider_bg.png + + frame + {{80,157},{330,40}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{330,40}} + sourceSize + {330,40} + + gui_window01.png + + frame + {{2,5},{347,91}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{347,91}} + sourceSize + {347,91} + + gui_window02.png + + frame + {{150,98},{271,196}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{271,196}} + sourceSize + {271,196} + + separate.png + + frame + {{2,2},{446,1}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{446,1}} + sourceSize + {446,1} + + settings_btn_default_01.png + + frame + {{80,119},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_01_cnt.png + + frame + {{80,98},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_02.png + + frame + {{80,489},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + settings_btn_default_02_cnt.png + + frame + {{351,5},{68,19}} + offset + {0,0} + rotated + + sourceColorRect + {{0,0},{68,19}} + sourceSize + {68,19} + + start_btn_left_01.png + + frame + {{94,140},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_left_02.png + + frame + {{80,140},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_right_01.png + + frame + {{435,23},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + start_btn_right_02.png + + frame + {{421,23},{14,12}} + offset + {0,0} + rotated + + sourceColorRect + {{1,2},{14,12}} + sourceSize + {16,16} + + + metadata + + format + 2 + realTextureFileName + main.png + size + {512,512} + smartupdate + $TexturePacker:SmartUpdate:bc5c1e7831f1dd2a30267cbbc66b73f5:1/1$ + textureFileName + main.png + + + diff --git a/_images/main/main.png b/_images/main/main.png new file mode 100755 index 0000000..32caf08 Binary files /dev/null and b/_images/main/main.png differ diff --git a/_images/main/main.tps b/_images/main/main.tps new file mode 100755 index 0000000..2b65263 --- /dev/null +++ b/_images/main/main.tps @@ -0,0 +1,192 @@ + + + + fileFormatVersion + 1 + variation + main + verbose + + autoSDSettings + + allowRotation + + quiet + + premultiplyAlpha + + shapeDebug + + dpi + 72 + dataFormat + cocos2d + textureFileName + main.png + flipPVR + + ditherType + NearestNeighbour + backgroundColor + 0 + libGdx + + filtering + + x + Linear + y + Linear + + + shapePadding + 2 + jpgQuality + 80 + pngOptimizationLevel + 0 + textureSubPath + + textureFormat + png + borderPadding + 2 + maxTextureSize + + width + 2048 + height + 2048 + + fixedTextureSize + + width + -1 + height + -1 + + reduceBorderArtifacts + + algorithmSettings + + algorithm + MaxRects + freeSizeMode + Best + sizeConstraints + POT + forceSquared + + forceWordAligned + + maxRects + + heuristic + Best + + basic + + sortBy + Best + order + Ascending + + + andEngine + + minFilter + Linear + packageName + Texture + javaFileName + main.java + wrap + + s + Clamp + t + Clamp + + magFilter + MagLinear + + dataFileName + main.plist + multiPack + + mainExtension + + forceIdenticalLayout + + outputFormat + RGBA4444 + contentProtection + + key + + + autoAliasEnabled + + trimSpriteNames + + globalSpriteSettings + + scale + 1 + scaleMode + Smooth + innerPadding + 0 + extrude + 0 + trimThreshold + 1 + trimMode + Trim + heuristicMask + + + fileList + + commons_btn_back_01_cnt.png + commons_btn_back_01.png + commons_btn_back_02_cnt.png + commons_btn_back_02.png + commons_btn_back_03.png + commons_btn_back_04.png + commons_btn_back_05.png + commons_btn_cancel_01_cnt.png + commons_btn_cancel_01.png + commons_btn_cancel_02_cnt.png + commons_btn_cancel_02.png + commons_btn_close.png + gui_battle_progress_bar01_a.png + gui_battle_progress_bar01_b.png + gui_hand.png + gui_separate.png + gui_setting_slider_bg.png + gui_setting_slider.png + gui_window01.png + gui_window02.png + settings_btn_default_01_cnt.png + settings_btn_default_01.png + settings_btn_default_02_cnt.png + settings_btn_default_02.png + start_btn_left_01.png + start_btn_left_02.png + start_btn_right_01.png + start_btn_right_02.png + separate.png + + ignoreFileList + + replaceList + + ignoredWarnings + + commonDivisorX + 1 + commonDivisorY + 1 + + diff --git a/_images/main/separate.png b/_images/main/separate.png new file mode 100755 index 0000000..7c42ae2 Binary files /dev/null and b/_images/main/separate.png differ diff --git a/_images/main/settings_btn_default_01.png b/_images/main/settings_btn_default_01.png new file mode 100755 index 0000000..2f559ab Binary files /dev/null and b/_images/main/settings_btn_default_01.png differ diff --git a/_images/main/settings_btn_default_01_cnt.png b/_images/main/settings_btn_default_01_cnt.png new file mode 100755 index 0000000..75d5e3d Binary files /dev/null and b/_images/main/settings_btn_default_01_cnt.png differ diff --git a/_images/main/settings_btn_default_02.png b/_images/main/settings_btn_default_02.png new file mode 100755 index 0000000..70db2f0 Binary files /dev/null and b/_images/main/settings_btn_default_02.png differ diff --git a/_images/main/settings_btn_default_02_cnt.png b/_images/main/settings_btn_default_02_cnt.png new file mode 100755 index 0000000..e90b58e Binary files /dev/null and b/_images/main/settings_btn_default_02_cnt.png differ diff --git a/_images/main/start_btn_left_01.png b/_images/main/start_btn_left_01.png new file mode 100755 index 0000000..01b2154 Binary files /dev/null and b/_images/main/start_btn_left_01.png differ diff --git a/_images/main/start_btn_left_02.png b/_images/main/start_btn_left_02.png new file mode 100755 index 0000000..3fbcadc Binary files /dev/null and b/_images/main/start_btn_left_02.png differ diff --git a/_images/main/start_btn_right_01.png b/_images/main/start_btn_right_01.png new file mode 100755 index 0000000..975eadd Binary files /dev/null and b/_images/main/start_btn_right_01.png differ diff --git a/_images/main/start_btn_right_02.png b/_images/main/start_btn_right_02.png new file mode 100755 index 0000000..62bfff7 Binary files /dev/null and b/_images/main/start_btn_right_02.png differ diff --git a/libs/CppSQLite3.cpp b/libs/CppSQLite3.cpp new file mode 100755 index 0000000..866f638 --- /dev/null +++ b/libs/CppSQLite3.cpp @@ -0,0 +1,1484 @@ +//////////////////////////////////////////////////////////////////////////////// +// CppSQLite3 - A C++ wrapper around the SQLite3 embedded database library. +// +// Copyright (c) 2004 Rob Groves. All Rights Reserved. rob.groves@btinternet.com +// +// Permission to use, copy, modify, and distribute this software and its +// documentation for any purpose, without fee, and without a written +// agreement, is hereby granted, provided that the above copyright notice, +// this paragraph and the following two paragraphs appear in all copies, +// modifications, and distributions. +// +// IN NO EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, +// INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING LOST +// PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, +// EVEN IF THE AUTHOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +// +// THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +// PARTICULAR PURPOSE. THE SOFTWARE AND ACCOMPANYING DOCUMENTATION, IF +// ANY, PROVIDED HEREUNDER IS PROVIDED "AS IS". THE AUTHOR HAS NO OBLIGATION +// TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. +// +// V3.0 03/08/2004 -Initial Version for sqlite3 +// +// V3.1 16/09/2004 -Implemented getXXXXField using sqlite3 functions +// -Added CppSQLiteDB3::tableExists() +//////////////////////////////////////////////////////////////////////////////// +#include "CppSQLite3.h" +#include + + +// Named constant for passing to CppSQLite3Exception when passing it a string +// that cannot be deleted. +static const bool DONT_DELETE_MSG=false; + +//////////////////////////////////////////////////////////////////////////////// +// Prototypes for SQLite functions not included in SQLite DLL, but copied below +// from SQLite encode.c +//////////////////////////////////////////////////////////////////////////////// +int sqlite3_encode_binary(const unsigned char *in, int n, unsigned char *out); +int sqlite3_decode_binary(const unsigned char *in, unsigned char *out); + +//////////////////////////////////////////////////////////////////////////////// + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Exception::CppSQLite3Exception(const int nErrCode, + char* szErrMess, + bool bDeleteMsg/*=true*/) : + mnErrCode(nErrCode) +{ + mpszErrMess = sqlite3_mprintf("%s[%d]: %s", + errorCodeAsString(nErrCode), + nErrCode, + szErrMess ? szErrMess : ""); + + if (bDeleteMsg && szErrMess) + { + sqlite3_free(szErrMess); + } +} + + +CppSQLite3Exception::CppSQLite3Exception(const CppSQLite3Exception& e) : + mnErrCode(e.mnErrCode) +{ + mpszErrMess = 0; + if (e.mpszErrMess) + { + mpszErrMess = sqlite3_mprintf("%s", e.mpszErrMess); + } +} + + +const char* CppSQLite3Exception::errorCodeAsString(int nErrCode) +{ + switch (nErrCode) + { + case SQLITE_OK : return "SQLITE_OK"; + case SQLITE_ERROR : return "SQLITE_ERROR"; + case SQLITE_INTERNAL : return "SQLITE_INTERNAL"; + case SQLITE_PERM : return "SQLITE_PERM"; + case SQLITE_ABORT : return "SQLITE_ABORT"; + case SQLITE_BUSY : return "SQLITE_BUSY"; + case SQLITE_LOCKED : return "SQLITE_LOCKED"; + case SQLITE_NOMEM : return "SQLITE_NOMEM"; + case SQLITE_READONLY : return "SQLITE_READONLY"; + case SQLITE_INTERRUPT : return "SQLITE_INTERRUPT"; + case SQLITE_IOERR : return "SQLITE_IOERR"; + case SQLITE_CORRUPT : return "SQLITE_CORRUPT"; + case SQLITE_NOTFOUND : return "SQLITE_NOTFOUND"; + case SQLITE_FULL : return "SQLITE_FULL"; + case SQLITE_CANTOPEN : return "SQLITE_CANTOPEN"; + case SQLITE_PROTOCOL : return "SQLITE_PROTOCOL"; + case SQLITE_EMPTY : return "SQLITE_EMPTY"; + case SQLITE_SCHEMA : return "SQLITE_SCHEMA"; + case SQLITE_TOOBIG : return "SQLITE_TOOBIG"; + case SQLITE_CONSTRAINT : return "SQLITE_CONSTRAINT"; + case SQLITE_MISMATCH : return "SQLITE_MISMATCH"; + case SQLITE_MISUSE : return "SQLITE_MISUSE"; + case SQLITE_NOLFS : return "SQLITE_NOLFS"; + case SQLITE_AUTH : return "SQLITE_AUTH"; + case SQLITE_FORMAT : return "SQLITE_FORMAT"; + case SQLITE_RANGE : return "SQLITE_RANGE"; + case SQLITE_ROW : return "SQLITE_ROW"; + case SQLITE_DONE : return "SQLITE_DONE"; + case CPPSQLITE_ERROR : return "CPPSQLITE_ERROR"; + default: return "UNKNOWN_ERROR"; + } +} + + +CppSQLite3Exception::~CppSQLite3Exception() +{ + if (mpszErrMess) + { + sqlite3_free(mpszErrMess); + mpszErrMess = 0; + } +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Buffer::CppSQLite3Buffer() +{ + mpBuf = 0; +} + + +CppSQLite3Buffer::~CppSQLite3Buffer() +{ + clear(); +} + + +void CppSQLite3Buffer::clear() +{ + if (mpBuf) + { + sqlite3_free(mpBuf); + mpBuf = 0; + } + +} + + +const char* CppSQLite3Buffer::format(const char* szFormat, ...) +{ + clear(); + va_list va; + va_start(va, szFormat); + mpBuf = sqlite3_vmprintf(szFormat, va); + va_end(va); + return mpBuf; +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Binary::CppSQLite3Binary() : + mpBuf(0), + mnBinaryLen(0), + mnBufferLen(0), + mnEncodedLen(0), + mbEncoded(false) +{ +} + + +CppSQLite3Binary::~CppSQLite3Binary() +{ + clear(); +} + + +void CppSQLite3Binary::setBinary(const unsigned char* pBuf, int nLen) +{ + mpBuf = allocBuffer(nLen); + memcpy(mpBuf, pBuf, nLen); +} + + +void CppSQLite3Binary::setEncoded(const unsigned char* pBuf) +{ + clear(); + + mnEncodedLen = strlen((const char*)pBuf); + mnBufferLen = mnEncodedLen + 1; // Allow for NULL terminator + + mpBuf = (unsigned char*)malloc(mnBufferLen); + + if (!mpBuf) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Cannot allocate memory", + DONT_DELETE_MSG); + } + + memcpy(mpBuf, pBuf, mnBufferLen); + mbEncoded = true; +} + + +const unsigned char* CppSQLite3Binary::getEncoded() +{ + if (!mbEncoded) + { + unsigned char* ptmp = (unsigned char*)malloc(mnBinaryLen); + memcpy(ptmp, mpBuf, mnBinaryLen); + mnEncodedLen = sqlite3_encode_binary(ptmp, mnBinaryLen, mpBuf); + free(ptmp); + mbEncoded = true; + } + + return mpBuf; +} + + +const unsigned char* CppSQLite3Binary::getBinary() +{ + if (mbEncoded) + { + // in/out buffers can be the same + mnBinaryLen = sqlite3_decode_binary(mpBuf, mpBuf); + + if (mnBinaryLen == -1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Cannot decode binary", + DONT_DELETE_MSG); + } + + mbEncoded = false; + } + + return mpBuf; +} + + +int CppSQLite3Binary::getBinaryLength() +{ + getBinary(); + return mnBinaryLen; +} + + +unsigned char* CppSQLite3Binary::allocBuffer(int nLen) +{ + clear(); + + // Allow extra space for encoded binary as per comments in + // SQLite encode.c See bottom of this file for implementation + // of SQLite functions use 3 instead of 2 just to be sure ;-) + mnBinaryLen = nLen; + mnBufferLen = 3 + (257*nLen)/254; + + mpBuf = (unsigned char*)malloc(mnBufferLen); + + if (!mpBuf) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Cannot allocate memory", + DONT_DELETE_MSG); + } + + mbEncoded = false; + + return mpBuf; +} + + +void CppSQLite3Binary::clear() +{ + if (mpBuf) + { + mnBinaryLen = 0; + mnBufferLen = 0; + free(mpBuf); + mpBuf = 0; + } +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Query::CppSQLite3Query() +{ + mpVM = 0; + mbEof = true; + mnCols = 0; + mbOwnVM = false; +} + + +CppSQLite3Query::CppSQLite3Query(const CppSQLite3Query& rQuery) +{ + mpVM = rQuery.mpVM; + // Only one object can own the VM + const_cast(rQuery).mpVM = 0; + mbEof = rQuery.mbEof; + mnCols = rQuery.mnCols; + mbOwnVM = rQuery.mbOwnVM; +} + + +CppSQLite3Query::CppSQLite3Query(sqlite3* pDB, + sqlite3_stmt* pVM, + bool bEof, + bool bOwnVM/*=true*/) +{ + mpDB = pDB; + mpVM = pVM; + mbEof = bEof; + mnCols = sqlite3_column_count(mpVM); + mbOwnVM = bOwnVM; +} + + +CppSQLite3Query::~CppSQLite3Query() +{ + try + { + finalize(); + } + catch (...) + { + } +} + + +CppSQLite3Query& CppSQLite3Query::operator=(const CppSQLite3Query& rQuery) +{ + try + { + finalize(); + } + catch (...) + { + } + mpVM = rQuery.mpVM; + // Only one object can own the VM + const_cast(rQuery).mpVM = 0; + mbEof = rQuery.mbEof; + mnCols = rQuery.mnCols; + mbOwnVM = rQuery.mbOwnVM; + return *this; +} + + +int CppSQLite3Query::numFields() +{ + checkVM(); + return mnCols; +} + + +const char* CppSQLite3Query::fieldValue(int nField) +{ + checkVM(); + + if (nField < 0 || nField > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + return (const char*)sqlite3_column_text(mpVM, nField); +} + + +const char* CppSQLite3Query::fieldValue(const char* szField) +{ + int nField = fieldIndex(szField); + return (const char*)sqlite3_column_text(mpVM, nField); +} + + +int CppSQLite3Query::getIntField(int nField, int nNullValue/*=0*/) +{ + if (fieldDataType(nField) == SQLITE_NULL) + { + return nNullValue; + } + else + { + return sqlite3_column_int(mpVM, nField); + } +} + + +int CppSQLite3Query::getIntField(const char* szField, int nNullValue/*=0*/) +{ + int nField = fieldIndex(szField); + return getIntField(nField, nNullValue); +} + + +double CppSQLite3Query::getFloatField(int nField, double fNullValue/*=0.0*/) +{ + if (fieldDataType(nField) == SQLITE_NULL) + { + return fNullValue; + } + else + { + return sqlite3_column_double(mpVM, nField); + } +} + + +double CppSQLite3Query::getFloatField(const char* szField, double fNullValue/*=0.0*/) +{ + int nField = fieldIndex(szField); + return getFloatField(nField, fNullValue); +} + + +const char* CppSQLite3Query::getStringField(int nField, const char* szNullValue/*=""*/) +{ + if (fieldDataType(nField) == SQLITE_NULL) + { + return szNullValue; + } + else + { + return (const char*)sqlite3_column_text(mpVM, nField); + } +} + + +const char* CppSQLite3Query::getStringField(const char* szField, const char* szNullValue/*=""*/) +{ + int nField = fieldIndex(szField); + return getStringField(nField, szNullValue); +} + + +const unsigned char* CppSQLite3Query::getBlobField(int nField, int& nLen) +{ + checkVM(); + + if (nField < 0 || nField > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + nLen = sqlite3_column_bytes(mpVM, nField); + return (const unsigned char*)sqlite3_column_blob(mpVM, nField); +} + + +const unsigned char* CppSQLite3Query::getBlobField(const char* szField, int& nLen) +{ + int nField = fieldIndex(szField); + return getBlobField(nField, nLen); +} + + +bool CppSQLite3Query::fieldIsNull(int nField) +{ + return (fieldDataType(nField) == SQLITE_NULL); +} + + +bool CppSQLite3Query::fieldIsNull(const char* szField) +{ + int nField = fieldIndex(szField); + return (fieldDataType(nField) == SQLITE_NULL); +} + + +int CppSQLite3Query::fieldIndex(const char* szField) +{ + checkVM(); + + if (szField) + { + for (int nField = 0; nField < mnCols; nField++) + { + const char* szTemp = sqlite3_column_name(mpVM, nField); + + if (strcmp(szField, szTemp) == 0) + { + return nField; + } + } + } + + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field name requested", + DONT_DELETE_MSG); +} + + +const char* CppSQLite3Query::fieldName(int nCol) +{ + checkVM(); + + if (nCol < 0 || nCol > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + return sqlite3_column_name(mpVM, nCol); +} + + +const char* CppSQLite3Query::fieldDeclType(int nCol) +{ + checkVM(); + + if (nCol < 0 || nCol > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + return sqlite3_column_decltype(mpVM, nCol); +} + + +int CppSQLite3Query::fieldDataType(int nCol) +{ + checkVM(); + + if (nCol < 0 || nCol > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + return sqlite3_column_type(mpVM, nCol); +} + + +bool CppSQLite3Query::eof() +{ + checkVM(); + return mbEof; +} + + +void CppSQLite3Query::nextRow() +{ + checkVM(); + + int nRet = sqlite3_step(mpVM); + + if (nRet == SQLITE_DONE) + { + // no rows + mbEof = true; + } + else if (nRet == SQLITE_ROW) + { + // more rows, nothing to do + } + else + { + nRet = sqlite3_finalize(mpVM); + mpVM = 0; + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, + (char*)szError, + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Query::finalize() +{ + if (mpVM && mbOwnVM) + { + int nRet = sqlite3_finalize(mpVM); + mpVM = 0; + if (nRet != SQLITE_OK) + { + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } + } +} + + +void CppSQLite3Query::checkVM() +{ + if (mpVM == 0) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Null Virtual Machine pointer", + DONT_DELETE_MSG); + } +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Table::CppSQLite3Table() +{ + mpaszResults = 0; + mnRows = 0; + mnCols = 0; + mnCurrentRow = 0; +} + + +CppSQLite3Table::CppSQLite3Table(const CppSQLite3Table& rTable) +{ + mpaszResults = rTable.mpaszResults; + // Only one object can own the results + const_cast(rTable).mpaszResults = 0; + mnRows = rTable.mnRows; + mnCols = rTable.mnCols; + mnCurrentRow = rTable.mnCurrentRow; +} + + +CppSQLite3Table::CppSQLite3Table(char** paszResults, int nRows, int nCols) +{ + mpaszResults = paszResults; + mnRows = nRows; + mnCols = nCols; + mnCurrentRow = 0; +} + + +CppSQLite3Table::~CppSQLite3Table() +{ + try + { + finalize(); + } + catch (...) + { + } +} + + +CppSQLite3Table& CppSQLite3Table::operator=(const CppSQLite3Table& rTable) +{ + try + { + finalize(); + } + catch (...) + { + } + mpaszResults = rTable.mpaszResults; + // Only one object can own the results + const_cast(rTable).mpaszResults = 0; + mnRows = rTable.mnRows; + mnCols = rTable.mnCols; + mnCurrentRow = rTable.mnCurrentRow; + return *this; +} + + +void CppSQLite3Table::finalize() +{ + if (mpaszResults) + { + sqlite3_free_table(mpaszResults); + mpaszResults = 0; + } +} + + +int CppSQLite3Table::numFields() +{ + checkResults(); + return mnCols; +} + + +int CppSQLite3Table::numRows() +{ + checkResults(); + return mnRows; +} + + +const char* CppSQLite3Table::fieldValue(int nField) +{ + checkResults(); + + if (nField < 0 || nField > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + int nIndex = (mnCurrentRow*mnCols) + mnCols + nField; + return mpaszResults[nIndex]; +} + + +const char* CppSQLite3Table::fieldValue(const char* szField) +{ + checkResults(); + + if (szField) + { + for (int nField = 0; nField < mnCols; nField++) + { + if (strcmp(szField, mpaszResults[nField]) == 0) + { + int nIndex = (mnCurrentRow*mnCols) + mnCols + nField; + return mpaszResults[nIndex]; + } + } + } + + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field name requested", + DONT_DELETE_MSG); +} + + +int CppSQLite3Table::getIntField(int nField, int nNullValue/*=0*/) +{ + if (fieldIsNull(nField)) + { + return nNullValue; + } + else + { + return atoi(fieldValue(nField)); + } +} + + +int CppSQLite3Table::getIntField(const char* szField, int nNullValue/*=0*/) +{ + if (fieldIsNull(szField)) + { + return nNullValue; + } + else + { + return atoi(fieldValue(szField)); + } +} + + +double CppSQLite3Table::getFloatField(int nField, double fNullValue/*=0.0*/) +{ + if (fieldIsNull(nField)) + { + return fNullValue; + } + else + { + return atof(fieldValue(nField)); + } +} + + +double CppSQLite3Table::getFloatField(const char* szField, double fNullValue/*=0.0*/) +{ + if (fieldIsNull(szField)) + { + return fNullValue; + } + else + { + return atof(fieldValue(szField)); + } +} + + +const char* CppSQLite3Table::getStringField(int nField, const char* szNullValue/*=""*/) +{ + if (fieldIsNull(nField)) + { + return szNullValue; + } + else + { + return fieldValue(nField); + } +} + + +const char* CppSQLite3Table::getStringField(const char* szField, const char* szNullValue/*=""*/) +{ + if (fieldIsNull(szField)) + { + return szNullValue; + } + else + { + return fieldValue(szField); + } +} + + +bool CppSQLite3Table::fieldIsNull(int nField) +{ + checkResults(); + return (fieldValue(nField) == 0); +} + + +bool CppSQLite3Table::fieldIsNull(const char* szField) +{ + checkResults(); + return (fieldValue(szField) == 0); +} + + +const char* CppSQLite3Table::fieldName(int nCol) +{ + checkResults(); + + if (nCol < 0 || nCol > mnCols-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid field index requested", + DONT_DELETE_MSG); + } + + return mpaszResults[nCol]; +} + + +void CppSQLite3Table::setRow(int nRow) +{ + checkResults(); + + if (nRow < 0 || nRow > mnRows-1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid row index requested", + DONT_DELETE_MSG); + } + + mnCurrentRow = nRow; +} + + +void CppSQLite3Table::checkResults() +{ + if (mpaszResults == 0) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Null Results pointer", + DONT_DELETE_MSG); + } +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3Statement::CppSQLite3Statement() +{ + mpDB = 0; + mpVM = 0; +} + + +CppSQLite3Statement::CppSQLite3Statement(const CppSQLite3Statement& rStatement) +{ + mpDB = rStatement.mpDB; + mpVM = rStatement.mpVM; + // Only one object can own VM + const_cast(rStatement).mpVM = 0; +} + + +CppSQLite3Statement::CppSQLite3Statement(sqlite3* pDB, sqlite3_stmt* pVM) +{ + mpDB = pDB; + mpVM = pVM; +} + + +CppSQLite3Statement::~CppSQLite3Statement() +{ + try + { + finalize(); + } + catch (...) + { + } +} + + +CppSQLite3Statement& CppSQLite3Statement::operator=(const CppSQLite3Statement& rStatement) +{ + mpDB = rStatement.mpDB; + mpVM = rStatement.mpVM; + // Only one object can own VM + const_cast(rStatement).mpVM = 0; + return *this; +} + + +int CppSQLite3Statement::execDML() +{ + checkDB(); + checkVM(); + + const char* szError=0; + + int nRet = sqlite3_step(mpVM); + + if (nRet == SQLITE_DONE) + { + int nRowsChanged = sqlite3_changes(mpDB); + + nRet = sqlite3_reset(mpVM); + + if (nRet != SQLITE_OK) + { + szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } + + return nRowsChanged; + } + else + { + nRet = sqlite3_reset(mpVM); + szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } +} + + +CppSQLite3Query CppSQLite3Statement::execQuery() +{ + checkDB(); + checkVM(); + + int nRet = sqlite3_step(mpVM); + + if (nRet == SQLITE_DONE) + { + // no rows + return CppSQLite3Query(mpDB, mpVM, true/*eof*/, false); + } + else if (nRet == SQLITE_ROW) + { + // at least 1 row + return CppSQLite3Query(mpDB, mpVM, false/*eof*/, false); + } + else + { + nRet = sqlite3_reset(mpVM); + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::bind(int nParam, const char* szValue) +{ + checkVM(); + int nRes = sqlite3_bind_text(mpVM, nParam, szValue, -1, SQLITE_TRANSIENT); + + if (nRes != SQLITE_OK) + { + throw CppSQLite3Exception(nRes, + "Error binding string param", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::bind(int nParam, const int nValue) +{ + checkVM(); + int nRes = sqlite3_bind_int(mpVM, nParam, nValue); + + if (nRes != SQLITE_OK) + { + throw CppSQLite3Exception(nRes, + "Error binding int param", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::bind(int nParam, const double dValue) +{ + checkVM(); + int nRes = sqlite3_bind_double(mpVM, nParam, dValue); + + if (nRes != SQLITE_OK) + { + throw CppSQLite3Exception(nRes, + "Error binding double param", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::bind(int nParam, const unsigned char* blobValue, int nLen) +{ + checkVM(); + int nRes = sqlite3_bind_blob(mpVM, nParam, + (const void*)blobValue, nLen, SQLITE_TRANSIENT); + + if (nRes != SQLITE_OK) + { + throw CppSQLite3Exception(nRes, + "Error binding blob param", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::bindNull(int nParam) +{ + checkVM(); + int nRes = sqlite3_bind_null(mpVM, nParam); + + if (nRes != SQLITE_OK) + { + throw CppSQLite3Exception(nRes, + "Error binding NULL param", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::reset() +{ + if (mpVM) + { + int nRet = sqlite3_reset(mpVM); + + if (nRet != SQLITE_OK) + { + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } + } +} + + +void CppSQLite3Statement::finalize() +{ + if (mpVM) + { + int nRet = sqlite3_finalize(mpVM); + mpVM = 0; + + if (nRet != SQLITE_OK) + { + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } + } +} + + +void CppSQLite3Statement::checkDB() +{ + if (mpDB == 0) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Database not open", + DONT_DELETE_MSG); + } +} + + +void CppSQLite3Statement::checkVM() +{ + if (mpVM == 0) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Null Virtual Machine pointer", + DONT_DELETE_MSG); + } +} + + +//////////////////////////////////////////////////////////////////////////////// + +CppSQLite3DB::CppSQLite3DB() +{ + mpDB = 0; + mnBusyTimeoutMs = 60000; // 60 seconds +} + + +CppSQLite3DB::CppSQLite3DB(const CppSQLite3DB& db) +{ + mpDB = db.mpDB; + mnBusyTimeoutMs = 60000; // 60 seconds +} + + +CppSQLite3DB::~CppSQLite3DB() +{ + close(); +} + + +CppSQLite3DB& CppSQLite3DB::operator=(const CppSQLite3DB& db) +{ + mpDB = db.mpDB; + mnBusyTimeoutMs = 60000; // 60 seconds + return *this; +} + + +void CppSQLite3DB::open(const char* szFile) +{ + int nRet = sqlite3_open(szFile, &mpDB); + + if (nRet != SQLITE_OK) + { + const char* szError = sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } + + setBusyTimeout(mnBusyTimeoutMs); +} + + +void CppSQLite3DB::close() +{ + if (mpDB) + { + sqlite3_close(mpDB); + mpDB = 0; + } +} + + +CppSQLite3Statement CppSQLite3DB::compileStatement(const char* szSQL) +{ + checkDB(); + + sqlite3_stmt* pVM = compile(szSQL); + return CppSQLite3Statement(mpDB, pVM); +} + + +bool CppSQLite3DB::tableExists(const char* szTable) +{ + char szSQL[128]; + sprintf(szSQL, + "select count(*) from sqlite_master where type='table' and name='%s'", + szTable); + int nRet = execScalar(szSQL); + return (nRet > 0); +} + + +int CppSQLite3DB::execDML(const char* szSQL) +{ + checkDB(); + + char* szError=0; + + int nRet = sqlite3_exec(mpDB, szSQL, 0, 0, &szError); + + if (nRet == SQLITE_OK) + { + return sqlite3_changes(mpDB); + } + else + { + throw CppSQLite3Exception(nRet, szError); + } +} + + +CppSQLite3Query CppSQLite3DB::execQuery(const char* szSQL) +{ + checkDB(); + + sqlite3_stmt* pVM = compile(szSQL); + + int nRet = sqlite3_step(pVM); + + if (nRet == SQLITE_DONE) + { + // no rows + return CppSQLite3Query(mpDB, pVM, true/*eof*/); + } + else if (nRet == SQLITE_ROW) + { + // at least 1 row + return CppSQLite3Query(mpDB, pVM, false/*eof*/); + } + else + { + nRet = sqlite3_finalize(pVM); + const char* szError= sqlite3_errmsg(mpDB); + throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); + } +} + + +int CppSQLite3DB::execScalar(const char* szSQL) +{ + CppSQLite3Query q = execQuery(szSQL); + + if (q.eof() || q.numFields() < 1) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Invalid scalar query", + DONT_DELETE_MSG); + } + + return atoi(q.fieldValue(0)); +} + + +CppSQLite3Table CppSQLite3DB::getTable(const char* szSQL) +{ + checkDB(); + + char* szError=0; + char** paszResults=0; + int nRet; + int nRows(0); + int nCols(0); + + nRet = sqlite3_get_table(mpDB, szSQL, &paszResults, &nRows, &nCols, &szError); + + if (nRet == SQLITE_OK) + { + return CppSQLite3Table(paszResults, nRows, nCols); + } + else + { + throw CppSQLite3Exception(nRet, szError); + } +} + + +sqlite_int64 CppSQLite3DB::lastRowId() +{ + return sqlite3_last_insert_rowid(mpDB); +} + + +void CppSQLite3DB::setBusyTimeout(int nMillisecs) +{ + mnBusyTimeoutMs = nMillisecs; + sqlite3_busy_timeout(mpDB, mnBusyTimeoutMs); +} + + +void CppSQLite3DB::checkDB() +{ + if (!mpDB) + { + throw CppSQLite3Exception(CPPSQLITE_ERROR, + "Database not open", + DONT_DELETE_MSG); + } +} + + +sqlite3_stmt* CppSQLite3DB::compile(const char* szSQL) +{ + checkDB(); + + char* szError=0; + const char* szTail=0; + sqlite3_stmt* pVM; + + int nRet = sqlite3_prepare(mpDB, szSQL, -1, &pVM, &szTail); + + if (nRet != SQLITE_OK) + { + throw CppSQLite3Exception(nRet, szError); + } + + return pVM; +} + + +//////////////////////////////////////////////////////////////////////////////// +// SQLite encode.c reproduced here, containing implementation notes and source +// for sqlite3_encode_binary() and sqlite3_decode_binary() +//////////////////////////////////////////////////////////////////////////////// + +/* +** 2002 April 25 +** +** The author disclaims copyright to this source code. In place of +** a legal notice, here is a blessing: +** +** May you do good and not evil. +** May you find forgiveness for yourself and forgive others. +** May you share freely, never taking more than you give. +** +************************************************************************* +** This file contains helper routines used to translate binary data into +** a null-terminated string (suitable for use in SQLite) and back again. +** These are convenience routines for use by people who want to store binary +** data in an SQLite database. The code in this file is not used by any other +** part of the SQLite library. +** +** $Id: encode.c,v 1.10 2004/01/14 21:59:23 drh Exp $ +*/ + +/* +** How This Encoder Works +** +** The output is allowed to contain any character except 0x27 (') and +** 0x00. This is accomplished by using an escape character to encode +** 0x27 and 0x00 as a two-byte sequence. The escape character is always +** 0x01. An 0x00 is encoded as the two byte sequence 0x01 0x01. The +** 0x27 character is encoded as the two byte sequence 0x01 0x03. Finally, +** the escape character itself is encoded as the two-character sequence +** 0x01 0x02. +** +** To summarize, the encoder works by using an escape sequences as follows: +** +** 0x00 -> 0x01 0x01 +** 0x01 -> 0x01 0x02 +** 0x27 -> 0x01 0x03 +** +** If that were all the encoder did, it would work, but in certain cases +** it could double the size of the encoded string. For example, to +** encode a string of 100 0x27 characters would require 100 instances of +** the 0x01 0x03 escape sequence resulting in a 200-character output. +** We would prefer to keep the size of the encoded string smaller than +** this. +** +** To minimize the encoding size, we first add a fixed offset value to each +** byte in the sequence. The addition is modulo 256. (That is to say, if +** the sum of the original character value and the offset exceeds 256, then +** the higher order bits are truncated.) The offset is chosen to minimize +** the number of characters in the string that need to be escaped. For +** example, in the case above where the string was composed of 100 0x27 +** characters, the offset might be 0x01. Each of the 0x27 characters would +** then be converted into an 0x28 character which would not need to be +** escaped at all and so the 100 character input string would be converted +** into just 100 characters of output. Actually 101 characters of output - +** we have to record the offset used as the first byte in the sequence so +** that the string can be decoded. Since the offset value is stored as +** part of the output string and the output string is not allowed to contain +** characters 0x00 or 0x27, the offset cannot be 0x00 or 0x27. +** +** Here, then, are the encoding steps: +** +** (1) Choose an offset value and make it the first character of +** output. +** +** (2) Copy each input character into the output buffer, one by +** one, adding the offset value as you copy. +** +** (3) If the value of an input character plus offset is 0x00, replace +** that one character by the two-character sequence 0x01 0x01. +** If the sum is 0x01, replace it with 0x01 0x02. If the sum +** is 0x27, replace it with 0x01 0x03. +** +** (4) Put a 0x00 terminator at the end of the output. +** +** Decoding is obvious: +** +** (5) Copy encoded characters except the first into the decode +** buffer. Set the first encoded character aside for use as +** the offset in step 7 below. +** +** (6) Convert each 0x01 0x01 sequence into a single character 0x00. +** Convert 0x01 0x02 into 0x01. Convert 0x01 0x03 into 0x27. +** +** (7) Subtract the offset value that was the first character of +** the encoded buffer from all characters in the output buffer. +** +** The only tricky part is step (1) - how to compute an offset value to +** minimize the size of the output buffer. This is accomplished by testing +** all offset values and picking the one that results in the fewest number +** of escapes. To do that, we first scan the entire input and count the +** number of occurances of each character value in the input. Suppose +** the number of 0x00 characters is N(0), the number of occurances of 0x01 +** is N(1), and so forth up to the number of occurances of 0xff is N(255). +** An offset of 0 is not allowed so we don't have to test it. The number +** of escapes required for an offset of 1 is N(1)+N(2)+N(40). The number +** of escapes required for an offset of 2 is N(2)+N(3)+N(41). And so forth. +** In this way we find the offset that gives the minimum number of escapes, +** and thus minimizes the length of the output string. +*/ + +/* +** Encode a binary buffer "in" of size n bytes so that it contains +** no instances of characters '\'' or '\000'. The output is +** null-terminated and can be used as a string value in an INSERT +** or UPDATE statement. Use sqlite3_decode_binary() to convert the +** string back into its original binary. +** +** The result is written into a preallocated output buffer "out". +** "out" must be able to hold at least 2 +(257*n)/254 bytes. +** In other words, the output will be expanded by as much as 3 +** bytes for every 254 bytes of input plus 2 bytes of fixed overhead. +** (This is approximately 2 + 1.0118*n or about a 1.2% size increase.) +** +** The return value is the number of characters in the encoded +** string, excluding the "\000" terminator. +*/ +int sqlite3_encode_binary(const unsigned char *in, int n, unsigned char *out){ + int i, j, e, m; + int cnt[256]; + if( n<=0 ){ + out[0] = 'x'; + out[1] = 0; + return 1; + } + memset(cnt, 0, sizeof(cnt)); + for(i=n-1; i>=0; i--){ cnt[in[i]]++; } + m = n; + for(i=1; i<256; i++){ + int sum; + if( i=='\'' ) continue; + sum = cnt[i] + cnt[(i+1)&0xff] + cnt[(i+'\'')&0xff]; + if( sum +#include + +#define CPPSQLITE_ERROR 1000 + +class CppSQLite3Exception +{ +public: + + CppSQLite3Exception(const int nErrCode, + char* szErrMess, + bool bDeleteMsg=true); + + CppSQLite3Exception(const CppSQLite3Exception& e); + + virtual ~CppSQLite3Exception(); + + const int errorCode() { return mnErrCode; } + + const char* errorMessage() { return mpszErrMess; } + + static const char* errorCodeAsString(int nErrCode); + +private: + + int mnErrCode; + char* mpszErrMess; +}; + + +class CppSQLite3Buffer +{ +public: + + CppSQLite3Buffer(); + + ~CppSQLite3Buffer(); + + const char* format(const char* szFormat, ...); + + operator const char*() { return mpBuf; } + + void clear(); + +private: + + char* mpBuf; +}; + + +class CppSQLite3Binary +{ +public: + + CppSQLite3Binary(); + + ~CppSQLite3Binary(); + + void setBinary(const unsigned char* pBuf, int nLen); + void setEncoded(const unsigned char* pBuf); + + const unsigned char* getEncoded(); + const unsigned char* getBinary(); + + int getBinaryLength(); + + unsigned char* allocBuffer(int nLen); + + void clear(); + +private: + + unsigned char* mpBuf; + int mnBinaryLen; + int mnBufferLen; + int mnEncodedLen; + bool mbEncoded; +}; + + +class CppSQLite3Query +{ +public: + + CppSQLite3Query(); + + CppSQLite3Query(const CppSQLite3Query& rQuery); + + CppSQLite3Query(sqlite3* pDB, + sqlite3_stmt* pVM, + bool bEof, + bool bOwnVM=true); + + CppSQLite3Query& operator=(const CppSQLite3Query& rQuery); + + virtual ~CppSQLite3Query(); + + int numFields(); + + int fieldIndex(const char* szField); + const char* fieldName(int nCol); + + const char* fieldDeclType(int nCol); + int fieldDataType(int nCol); + + const char* fieldValue(int nField); + const char* fieldValue(const char* szField); + + int getIntField(int nField, int nNullValue=0); + int getIntField(const char* szField, int nNullValue=0); + + double getFloatField(int nField, double fNullValue=0.0); + double getFloatField(const char* szField, double fNullValue=0.0); + + const char* getStringField(int nField, const char* szNullValue=""); + const char* getStringField(const char* szField, const char* szNullValue=""); + + const unsigned char* getBlobField(int nField, int& nLen); + const unsigned char* getBlobField(const char* szField, int& nLen); + + bool fieldIsNull(int nField); + bool fieldIsNull(const char* szField); + + bool eof(); + + void nextRow(); + + void finalize(); + +private: + + void checkVM(); + + sqlite3* mpDB; + sqlite3_stmt* mpVM; + bool mbEof; + int mnCols; + bool mbOwnVM; +}; + + +class CppSQLite3Table +{ +public: + + CppSQLite3Table(); + + CppSQLite3Table(const CppSQLite3Table& rTable); + + CppSQLite3Table(char** paszResults, int nRows, int nCols); + + virtual ~CppSQLite3Table(); + + CppSQLite3Table& operator=(const CppSQLite3Table& rTable); + + int numFields(); + + int numRows(); + + const char* fieldName(int nCol); + + const char* fieldValue(int nField); + const char* fieldValue(const char* szField); + + int getIntField(int nField, int nNullValue=0); + int getIntField(const char* szField, int nNullValue=0); + + double getFloatField(int nField, double fNullValue=0.0); + double getFloatField(const char* szField, double fNullValue=0.0); + + const char* getStringField(int nField, const char* szNullValue=""); + const char* getStringField(const char* szField, const char* szNullValue=""); + + bool fieldIsNull(int nField); + bool fieldIsNull(const char* szField); + + void setRow(int nRow); + + void finalize(); + +private: + + void checkResults(); + + int mnCols; + int mnRows; + int mnCurrentRow; + char** mpaszResults; +}; + + +class CppSQLite3Statement +{ +public: + + CppSQLite3Statement(); + + CppSQLite3Statement(const CppSQLite3Statement& rStatement); + + CppSQLite3Statement(sqlite3* pDB, sqlite3_stmt* pVM); + + virtual ~CppSQLite3Statement(); + + CppSQLite3Statement& operator=(const CppSQLite3Statement& rStatement); + + int execDML(); + + CppSQLite3Query execQuery(); + + void bind(int nParam, const char* szValue); + void bind(int nParam, const int nValue); + void bind(int nParam, const double dwValue); + void bind(int nParam, const unsigned char* blobValue, int nLen); + void bindNull(int nParam); + + void reset(); + + void finalize(); + +private: + + void checkDB(); + void checkVM(); + + sqlite3* mpDB; + sqlite3_stmt* mpVM; +}; + + +class CppSQLite3DB +{ +public: + + CppSQLite3DB(); + + virtual ~CppSQLite3DB(); + + void open(const char* szFile); + + void close(); + + bool tableExists(const char* szTable); + + int execDML(const char* szSQL); + + CppSQLite3Query execQuery(const char* szSQL); + + int execScalar(const char* szSQL); + + CppSQLite3Table getTable(const char* szSQL); + + CppSQLite3Statement compileStatement(const char* szSQL); + + sqlite_int64 lastRowId(); + + void interrupt() { sqlite3_interrupt(mpDB); } + + void setBusyTimeout(int nMillisecs); + + static const char* SQLiteVersion() { return SQLITE_VERSION; } + +private: + + CppSQLite3DB(const CppSQLite3DB& db); + CppSQLite3DB& operator=(const CppSQLite3DB& db); + + sqlite3_stmt* compile(const char* szSQL); + + void checkDB(); + + sqlite3* mpDB; + int mnBusyTimeoutMs; +}; + +#endif diff --git a/libs/JsonBox/include/JsonBox.h b/libs/JsonBox/include/JsonBox.h new file mode 100644 index 0000000..e9290c8 --- /dev/null +++ b/libs/JsonBox/include/JsonBox.h @@ -0,0 +1,31 @@ +#ifndef JB_JSON_BOX_H +#define JB_JSON_BOX_H + +/** + * @mainpage JsonBox + * @section format_description What is JSON? + * [JSON](http://json.org/) (JavaScript Object Notation) is a lightweight data-interchange format. + * @section project_description What is Json Box? + * Json Box is a C++ library used to read and write JSON with ease and speed. + * + * Things it does: + * * Follows the standards established on [http://json.org/](http://json.org/) + * * Read and write JSON in UTF-8 + * * Uses the STL streams for input and output + * * Generated JSON can be indented and pretty or compact and hard-to-read + * * Does not crash when the JSON input contains errors, it simply tries to interpret as much as it can + * + * Things it does not do: + * * Read JSON in UTF-16 or UTF-32 + * * Keep the order of the members in objects (the standard doesn't require keeping the order) + * * Write useful error messages when the JSON input contains errors + * + * The library wasn't designed with multi-threading in mind. + * @see JsonBox + */ + +#include +#include +#include + +#endif diff --git a/libs/JsonBox/include/JsonBox/Array.h b/libs/JsonBox/include/JsonBox/Array.h new file mode 100644 index 0000000..00a6bfc --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Array.h @@ -0,0 +1,143 @@ +#ifndef JB_ARRAY_H +#define JB_ARRAY_H + +#include +#include + +#include "Value.h" + +namespace JsonBox { + /** + * Represents an array of values in JSON. It's a vector with added methods. + * So it can be used the same way as a standard STL vector, but can be more + * easily output in a stream. + * @see JsonBox::Value + */ + class Array { + public: + typedef std::vector container; + typedef container::value_type value_type; + typedef container::allocator_type allocator_type; + typedef container::size_type size_type; + typedef container::difference_type difference_type; + typedef container::reference reference; + typedef container::const_reference const_reference; + typedef container::pointer pointer; + typedef container::const_pointer const_pointer; + typedef container::iterator iterator; + typedef container::const_iterator const_iterator; + typedef container::reverse_iterator reverse_iterator; + typedef container::const_reverse_iterator const_reverse_iterator; + + Array(const allocator_type &alloc = allocator_type()); + + explicit Array(size_type count, const_reference value = value_type(), const allocator_type &alloc = allocator_type()); + + template + Array(InputIterator first, InputIterator last, const allocator_type &alloc = allocator_type()) : data(first, last) { + } + + Array(const Array &other); + + Array &operator=(const Array &other); + + bool operator==(const Array &rhs) const; + + bool operator!=(const Array &rhs) const; + + bool operator<(const Array &rhs) const; + + bool operator<=(const Array &rhs) const; + + bool operator>(const Array &rhs) const; + + bool operator>=(const Array &rhs) const; + + void assign(size_type count, const_reference value); + + template + void assign(InputIterator first, InputIterator last) { + data.assign(first, last); + } + + allocator_type get_allocator() const; + + reference at(size_type pos); + + const_reference at(size_type pos) const; + + reference operator[](size_type pos); + + const_reference operator[](size_type pos) const; + + reference front(); + + const_reference front() const; + + reference back(); + + const_reference back() const; + + iterator begin(); + + const_iterator begin() const; + + iterator end(); + + const_iterator end() const; + + reverse_iterator rbegin(); + + const_reverse_iterator rbegin() const; + + reverse_iterator rend(); + + const_reverse_iterator rend() const; + + bool empty() const; + + size_type size() const; + + size_type max_size() const; + + void reserve(size_type size); + + size_type capacity() const; + + void clear(); + + iterator insert(iterator pos, const_reference value); + + void insert(iterator pos, size_type count, const_reference value); + + template + void insert(iterator pos, InputIterator first, InputIterator last) { + data.insert(pos, first, last); + } + + iterator erase(iterator pos); + + iterator erase(iterator first, iterator last); + + void push_back(const_reference value); + + void pop_back(); + + void resize(size_type count, const_reference value = value_type()); + + void swap(Array &other); + private: + container data; + }; + + /** + * Output operator overload for the JSON array. Outputs in standard JSON + * format. Indents the output and esapes the minimum characters. + * @param output Output stream in which to write the array's JSON. + * @param a Array to output into the stream. + * @return Output stream filled with the JSON code. + */ + std::ostream &operator<<(std::ostream &output, const Array &a); +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Convert.h b/libs/JsonBox/include/JsonBox/Convert.h new file mode 100644 index 0000000..0f290de --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Convert.h @@ -0,0 +1,35 @@ +/** + * @file + */ +#ifndef JB_CONVERTER_H +#define JB_CONVERTER_H + +#include +#include + +namespace JsonBox { + + typedef std::basic_string String32; + + /** + * This class is used to encode/decode/transcode UTF8, 16 and 32. + */ + class Convert { + public: + /** + * Encode the given UTF32 string to a 8bit UTF8 one. + * @param utf32String UTF32 string to convert to UTF8. + * @return UTF8 string resulting from the conversion. + */ + static std::string encodeToUTF8(const String32& utf32String); + + /** + * Decode the given 8bit UTF8 string to an UTF32 string. + * @param utf8String UTF8 string to convert to UTF32. + * @return UTF32 string resulting from the conversion. + */ + static String32 decodeUTF8(const std::string& utf8String); + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Escaper.h b/libs/JsonBox/include/JsonBox/Escaper.h new file mode 100644 index 0000000..2ec928f --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Escaper.h @@ -0,0 +1,19 @@ +#ifndef JB_ESCAPER_H +#define JB_ESCAPER_H + +#include + +namespace JsonBox { + class Escaper { + public: + Escaper(); + + std::streambuf::int_type operator()(std::streambuf &destination, + std::streambuf::int_type character); + private: + bool afterBackSlash; + bool inString; + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Grammar.h b/libs/JsonBox/include/JsonBox/Grammar.h new file mode 100644 index 0000000..b67a508 --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Grammar.h @@ -0,0 +1,83 @@ +#ifndef JB_GRAMMAR_H +#define JB_GRAMMAR_H + +#include + +namespace JsonBox { + // Structural characters. + namespace Structural { + const char BEGIN_ARRAY = '['; + const char BEGIN_OBJECT = '{'; + const char END_ARRAY = ']'; + const char END_OBJECT = '}'; + const char NAME_SEPARATOR = ':'; + const char VALUE_SEPARATOR = ','; + const char BEGIN_END_STRING = '"'; + } + + // Whitespace characters. + namespace Whitespace { + const char SPACE = ' '; + const char HORIZONTAL_TAB = '\t'; + const char NEW_LINE = '\n'; + const char CARRIAGE_RETURN = '\r'; + } + + // Literals. + namespace Literals { + const std::string FALSE_STRING = "false"; + const std::string TRUE_STRING = "true"; + const std::string NULL_STRING = "null"; + } + + // Numbers. + namespace Numbers { + const std::string DIGITS = "0123456789ABCDEFabcdef"; + const char DECIMAL_POINT = '.'; + const char LOWER_EXP = 'e'; + const char UPPER_EXP = 'E'; + const char MINUS = '-'; + const char PLUS = '+'; + } + + // Strings. + namespace Strings { + // C++ string characters. + namespace Std { + const char QUOTATION_MARK = '"'; + const char REVERSE_SOLIDUS = '\\'; + const char SOLIDUS = '/'; + const char BACKSPACE = '\b'; + const char FORM_FEED = '\f'; + const char LINE_FEED = '\n'; + const char CARRIAGE_RETURN = '\r'; + const char TAB = '\t'; + } + // Json escape strings. + namespace Json { + const std::string QUOTATION_MARK = "\\\""; + const std::string REVERSE_SOLIDUS = "\\\\"; + const std::string SOLIDUS = "\\/"; + const std::string BACKSPACE = "\\b"; + const std::string FORM_FEED = "\\f"; + const std::string LINE_FEED = "\\n"; + const std::string CARRIAGE_RETURN = "\\r"; + const std::string TAB = "\\t"; + const std::string BEGIN_UNICODE = "\\u"; + namespace Escape { + const char BEGIN_ESCAPE = '\\'; + const char QUOTATION_MARK = '"'; + const char REVERSE_SOLIDUS = '\\'; + const char SOLIDUS = '/'; + const char BACKSPACE = 'b'; + const char FORM_FEED = 'f'; + const char LINE_FEED = 'n'; + const char CARRIAGE_RETURN = 'r'; + const char TAB = 't'; + const char BEGIN_UNICODE = 'u'; + } + } + } +} + +#endif \ No newline at end of file diff --git a/libs/JsonBox/include/JsonBox/IndentCanceller.h b/libs/JsonBox/include/JsonBox/IndentCanceller.h new file mode 100644 index 0000000..97fc345 --- /dev/null +++ b/libs/JsonBox/include/JsonBox/IndentCanceller.h @@ -0,0 +1,33 @@ +#ifndef JB_INDENT_CANCELLER_H +#define JB_INDENT_CANCELLER_H + +#include + +namespace JsonBox { + /** + * Cancels indentations to a streambuf. + * @see JsonBox::OutputFilter + */ + class IndentCanceller { + public: + /** + * Default constructor. + */ + IndentCanceller(); + + /** + * Inserts a tab character at the start of each line. + * @param destination Streambuf in which to insert the tab character. + * @param character Character to insert in the streambuf. + * @return Unspecified value not equal to traits::eof() on success, + * traits::eof() on failure. + */ + std::streambuf::int_type operator()(std::streambuf &destination, + std::streambuf::int_type character); + private: + bool afterBackSlash; + bool inString; + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Indenter.h b/libs/JsonBox/include/JsonBox/Indenter.h new file mode 100644 index 0000000..ec561d7 --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Indenter.h @@ -0,0 +1,33 @@ +#ifndef JB_INDENTER_H +#define JB_INDENTER_H + +#include + +namespace JsonBox { + /** + * Adds a level of indentation to a streambuf. + * @see JsonBox::OutputFilter + */ + class Indenter { + public: + /** + * Default constructor. + */ + Indenter(); + + /** + * Inserts a tab character at the start of each line. + * @param destination Streambuf in which to insert the tab character. + * @param character Character to insert in the streambuf. + * @return Unspecified value not equal to traits::eof() on success, + * traits::eof() on failure. + */ + std::streambuf::int_type operator()(std::streambuf &destination, + std::streambuf::int_type character); + private: + /// Used to indicate if we are at the start of a new line. + bool atStartOfLine; + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Object.h b/libs/JsonBox/include/JsonBox/Object.h new file mode 100644 index 0000000..8df3778 --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Object.h @@ -0,0 +1,136 @@ +#ifndef JB_OBJECT_H +#define JB_OBJECT_H + +#include +#include +#include + +#include "Value.h" + +namespace JsonBox { + /** + * Represents a JSON object. It's a map with added methods. So the JSON + * object type can be used the same way as a standard STL map of string and + * Value, but can be more easily output in a stream. + * @see JsonBox::Value + */ + class Object { + public: + typedef std::map container; + typedef container::key_type key_type; + typedef container::mapped_type mapped_type; + typedef container::value_type value_type; + typedef container::size_type size_type; + typedef container::difference_type difference_type; + typedef container::key_compare key_compare; + typedef container::allocator_type allocator_type; + typedef container::reference reference; + typedef container::const_reference const_reference; + typedef container::pointer pointer; + typedef container::const_pointer const_pointer; + typedef container::iterator iterator; + typedef container::const_iterator const_iterator; + typedef container::reverse_iterator reverse_iterator; + typedef container::const_reverse_iterator const_reverse_iterator; + + explicit Object(const key_compare &comp = key_compare(), const allocator_type &alloc = allocator_type()); + + template + explicit Object(InputIterator first, InputIterator last, const key_compare &comp = key_compare(), const allocator_type &alloc = allocator_type()) : data(first, last, comp, alloc) { + } + + Object(const Object &other); + + Object &operator=(const Object &other); + + bool operator==(const Object &rhs) const; + + bool operator!=(const Object &rhs) const; + + bool operator<(const Object &rhs) const; + + bool operator<=(const Object &rhs) const; + + bool operator>(const Object &rhs) const; + + bool operator>=(const Object &rhs) const; + + allocator_type get_allocator() const; + + mapped_type &operator[](const key_type &key); + + iterator begin(); + + const_iterator begin() const; + + iterator end(); + + const_iterator end() const; + + reverse_iterator rbegin(); + + const_reverse_iterator rbegin() const; + + reverse_iterator rend(); + + const_reverse_iterator rend() const; + + bool empty() const; + + size_type size() const; + + size_type max_size() const; + + void clear(); + + std::pair insert(const_reference value); + + iterator insert(iterator hint, const_reference value); + + template + void insert(InputIterator first, InputIterator last) { + data.insert(first, last); + } + + void erase(iterator position); + + void erase(iterator first, iterator last); + + size_type erase(const key_type &key); + + void swap(Object &other); + + size_type count(const key_type &key) const; + + iterator find(const key_type &key); + + const_iterator find(const key_type &key) const; + + std::pair equal_range(const key_type &key); + + std::pair equal_range(const key_type &key) const; + + iterator lower_bound(const key_type &key); + + const_iterator lower_bound(const key_type &key) const; + + iterator upper_bound(const key_type &key); + + const_iterator upper_bound(const key_type &key) const; + + key_compare key_comp() const; + private: + container data; + }; + + /** + * Output operator overload for the JSON object. Outputs in standard JSON + * format. Indents the output and escapes the minimum characters. + * @param output Output stream in which to write the object's JSON. + * @param o Object to output into the stream. + * @return Output stream filled with the JSON code. + */ + std::ostream& operator<<(std::ostream& output, const Object& o); +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/OutputFilter.h b/libs/JsonBox/include/JsonBox/OutputFilter.h new file mode 100644 index 0000000..de297ab --- /dev/null +++ b/libs/JsonBox/include/JsonBox/OutputFilter.h @@ -0,0 +1,134 @@ +#ifndef JB_OUTPUT_FILTER_H +#define JB_OUTPUT_FILTER_H + +#include + +#include +#include + +namespace JsonBox { + /** + * Templated class used to filter output in an std::ostream. The custom + * mechanic of the filtering is easily implemented in the given Inserter. An + * output filter can be used to add indentation to an std::ostream, it can + * be used to log an std::ostream, etc. + * @tparam Inserter Type used as the inserter for the output filter. + */ + template + class OutputFilter : public std::streambuf { + public: + /** + * Parameterized constructor. + * @param newDestination Pointer to the streambuf destination. + * @param newInserter Inserter to use to filter the output. + * @param newDeleteWhenFinished Used to know if the instance will have + * to delete its destination streambuf or not. + */ + OutputFilter(std::streambuf *newDestination, Inserter newInserter, + bool newDeleteWhenFinished = false) : + destination(newDestination), inserter(newInserter), + deleteWhenFinished(newDeleteWhenFinished) { + } + + /** + * Parameterized constructor. + * @param newDestination Pointer to the streambuf destination. + * @param newInserter Inserter to use to filter the output. + */ + OutputFilter(std::streambuf *newDestination, + bool newDeleteWhenFinished = false) : + destination(newDestination), + deleteWhenFinished(newDeleteWhenFinished) { + } + + /** + * Destructor. Takes care of deleting the destination streambuf if + * necessary. + */ + virtual ~OutputFilter() { + // We delete the destination streambuf if necessary. + if (deleteWhenFinished && destination) { + delete destination; + } + } + + /** + * Actual function that calls the inserter to filter the output. + * @return Unspecified value not equal to traits::eof() on success, + * traits::eof() on failure. + */ + virtual int_type overflow(int_type ch) { + int result = std::char_traits::eof(); + + // If the received character is invalid, we sync. + if (ch == std::char_traits::eof()) { + result = sync(); + + } else if (destination) { + assert(ch >= 0 && ch <= static_cast(std::numeric_limits::max())); + result = inserter(*destination, ch); + } + + return result ; + } + + /** + * Since it's an output filter, we don't need to do anything here. + */ + virtual int_type underflow() { + return std::char_traits::eof(); + } + + /** + * We don't need to do anything here. Calls the base class version. + * @return 0 on success, -1 otherwise. The base class version returns 0. + */ + virtual int_type sync() { + return this->std::streambuf::sync(); + } + + /** + * We don't need to do anything here. Calls the base class version. + * @return Pointer to itself. + */ + virtual std::streambuf *setbuf(char *p, int len) { + return this->std::streambuf::setbuf(p, len); + } + + /** + * Gets the inserter's instance. + * @return Reference to the inserter. + */ + Inserter &getInserter() { + return inserter; + } + + /** + * Gets the destination streambuf. + * @return Pointer to the destination streambuf. + */ + std::streambuf *getDestination() const { + return destination; + } + + private: + /// Pointer to the destination streambuf. + std::streambuf *destination; + + /** + * Inserter to use to insert new characters in the destination + * streambuf. + * @see JsonBox::Filter::destination + */ + Inserter inserter; + + /** + * Bool used to know if the filter must delete its destination filter or + * not. + * @see JsonBox::Filter::destination + */ + bool deleteWhenFinished; + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/SolidusEscaper.h b/libs/JsonBox/include/JsonBox/SolidusEscaper.h new file mode 100644 index 0000000..ee6f7f8 --- /dev/null +++ b/libs/JsonBox/include/JsonBox/SolidusEscaper.h @@ -0,0 +1,19 @@ +#ifndef JB_SOLIDUS_ESCAPER_H +#define JB_SOLIDUS_ESCAPER_H + +#include + +namespace JsonBox { + class SolidusEscaper { + public: + SolidusEscaper(); + + std::streambuf::int_type operator()(std::streambuf &destination, + std::streambuf::int_type character); + private: + bool afterBackSlash; + bool inString; + }; +} + +#endif diff --git a/libs/JsonBox/include/JsonBox/Value.h b/libs/JsonBox/include/JsonBox/Value.h new file mode 100644 index 0000000..70034fc --- /dev/null +++ b/libs/JsonBox/include/JsonBox/Value.h @@ -0,0 +1,611 @@ +/** + * @file + */ +#ifndef JB_VALUE_H +#define JB_VALUE_H + +#include +#include + +namespace JsonBox { + class Array; + class Object; + + /** + * Represents a json value. Can be a string, an integer, a floating point + * number, an object, an array, a boolean value or a null value. To put it + * simply, it acts a lot like a variant. Objects are actually a map of + * strings and values while an array is a deque of values. + * The user doesn't have to worry about character escaping in strings, + * the i/o algorithms take care of that for the user. + * @see JsonBox::Array + * @see JsonBox::Object + */ + class Value { + /** + * Output operator overload. Outputs the value as valid JSON. Does not + * do any indentation. + * @param output Output stream in which the valid JSON is written. + * @param v Value to be output in the stream. + * @return Output parameter with the valud json written into it. + */ + friend std::ostream &operator<<(std::ostream &output, const Value &v); + public: + /** + * Represents the different types a value can be. A value can only be + * one of these types at a time. The UNKNOWN type is only used + * temporarily internally when loading values from an input stream or + * file. + */ + enum Type { + STRING, + INTEGER, + DOUBLE, + OBJECT, + ARRAY, + BOOLEAN, + NULL_VALUE, + UNKNOWN + }; + + /** + * Replaces characters with their JSON equivalent. The only difference + * from escapeAllCharacters is that the solidi won't be escaped in this + * method. + * @param str String to have its characters escaped. + * @return Copy of the recieved string, but with the concerned + * characters escaped. + * @see JsonBox::Value::escapeAllCharacters(const std::string& str) + */ + static std::string escapeMinimumCharacters(const std::string &str); + + /** + * Replaces characters with its JSON equivalent for escape characters. + * So for example, if in the string there is the newline character '\n', + * it will be replaced by the two characters '\' and 'n'. + * @param str String make a copy and have its characters escaped. + * @return Copy of the recieved string, but with the concerned + * characters escaped. + * @see JsonBox::Value::escapeMinimumCharacters(const std::string& str) + */ + static std::string escapeAllCharacters(const std::string &str); + + /** + * Escapes a character to its unicode equivalent. This function only + * takes characters from '/0' to '/x1f'. + * @param charToEscape Character to escape, must be between '\0' and + * '\x1f'. + * @return String with the character escaped in the format "\u00xx". + * "xx" being the hexadecimal ASCII code of the character escaped. + */ + static const std::string escapeToUnicode(char charToEscape); + + /** + * Default constructor. Makes the value null. + */ + Value(); + + /** + * Loads the value from an input stream. If there is more than one value + * in the input stream, they are ignored. Only the first value is read. + * @param input Input stream to load the value from. Can also be an + * input file stream. + */ + Value(std::istream &input); + + /** + * Constructs the value from a string. + * @param newString String used as the value. + */ + Value(const std::string &newString); + + /** + * Constructs the value from a C-style string. + * @param newCString C-style string used as the value. + */ + Value(const char *newCString); + + /** + * Constructs the value from an integer. + * @param newInt Integer used as the value. + */ + Value(int newInt); + + /** + * Constructs the value from a double. + * @param newDouble Double used as the value. + */ + Value(double newDouble); + + /** + * Constructs the value from an object. + * @param newObject Object used as the value. + */ + Value(const Object &newObject); + + /** + * Constructs the value from an array. + * @param newArray Array used as the value. + */ + Value(const Array &newArray); + + /** + * Constructs the value from a boolean. + * @param newBoolean Boolean used as the value. + */ + Value(bool newBoolean); + + /** + * Copy constructor. + * @param src Value to make a copy of. + */ + Value(const Value &src); + + /** + * Destructor. Frees up the memory used by the value's allocated + * pointers. + */ + ~Value(); + + /** + * Assignation operator overload. + * @param src Value to copy. + * @return Reference to the modified value. + */ + Value &operator=(const Value &src); + + /** + * Checks if the current value is equal to the right hand side value. + * @param rhs Right hand side value to check for equality with. + * @return True if the contents of the two values are equal, false if + * not. + */ + bool operator==(const Value &rhs) const; + + /** + * Checks if the current value is different from the right hand side + * value. + * @param rhs Right hand side value to check for not equality with. + * @return True if the contents of the two values are different, false + * if not. + */ + bool operator!=(const Value &rhs) const; + + /** + * Checks if the contents of instance are lexicographically less than + * the contents of the right hand side value. + * @param rhs Right hand side value to check. + * @return True if the contents of of the instance are lexicographically + * less than the contents of the right hand side value. + */ + bool operator <(const Value &rhs) const; + + /** + * Checks if the contents of instance are lexicographically less than or + * equal the contents of the right hand side value. + * @param rhs Right hand side value to check. + * @return True if the contents of of the instance are lexicographically + * less than or equal the contents of the right hand side value. + */ + bool operator <=(const Value &rhs) const; + + /** + * Checks if the contents of instance are lexicographically greater than + * the contents of the right hand side value. + * @param rhs Right hand side value to check. + * @return True if the contents of of the instance are lexicographically + * greater than the contents of the right hand side value. + */ + bool operator >(const Value &rhs) const; + + /** + * Checks if the contents of instance are lexicographically greater than + * or equal the contents of the right hand side value. + * @param rhs Right hand side value to check. + * @return True if the contents of of the instance are lexicographically + * greater than or equal the contents of the right hand side value. + */ + bool operator >=(const Value &rhs) const; + + /** + * Bracket operator overload. If the value doesn't represent an object, + * it is changed to do so and accesses the object's member value. If + * the object's member doesn't exist, it is created. + * @param key Key identifier of the object's value to get. + * @return Reference to the object's member's value. + */ + Value &operator[](const std::string &key); + + /** + * Bracket operator overload. If the value doesn't represent an object, + * it is changed to do so and accesses the object's member value. If + * the object's member doesn't exist, it is created. + * @param key Key identifier of the object's value to get. + * @return Reference to the object's member's value. + */ + Value &operator[](const char *key); + + /** + * Bracket operator overload. If the value doesn't represent an array, + * it is changed to do so and accesses the array's value at the + * specified index. To make sure the index value exists when it creates + * the array, it initializes the array with empty values up to the + * required index. If the value already represents an array and the + * index is too high for the size of the array, undefined behavior + * happens (no bounds checking is done). + * @param index Index of the value to get. + * @return Reference to the value at the received index in the array. + */ + Value &operator[](size_t index); + + /** + * Gets the value's type. + * @return Value's type, does not return Type::UNKOWN, would return + * NULL_VALUE if no type has been given to the value yet. + * @see JsonBox::Type + */ + Type getType() const; + + /** + * Checks if the value is a string. + * @return True if the value contains a string, false if not. + */ + bool isString() const; + /** + * Checks if the value is an integer. + * @return True if the value contains an integer, false if not. + */ + bool isInteger() const; + + /** + * Checks if the value is a double. + * @return True if the value contains a double, false if not. + */ + bool isDouble() const; + + /** + * Checks if the value is an object. + * @return True if the value contains an object, false if not. + */ + bool isObject() const; + + /** + * Checks if the value is an array. + * @return True if the value contains an array, false if not. + */ + bool isArray() const; + + /** + * Checks if the value is a boolean. + * @return True if the value contains a boolean, false if not. + */ + bool isBoolean() const; + + /** + * Checks if the value is null. + * @return True if the value contains nothing. + */ + bool isNull() const; + + /** + * Gets the value's string value. + * @return Value's string value, or an empty string if the value doesn't + * contain a string. + */ + const std::string &getString() const; + + /** + * Sets the value as a string. + * @param newString New string value that the Value will contain. If the + * value's type is changed if necessary to contain the integer. + */ + void setString(const std::string &newString); + + /** + * Gets the value's integer value. + * @return Value's integer value, or 0 if the value doesn't contain an + * integer. + */ + int getInt() const; + + /** + * Sets the value as an integer. + * @param newInt New integer value that the Value will contain. The + * value's type is changed if necessary to contain the integer. + */ + void setInt(int newInt); + + /** + * Gets the value's double value. + * @return Value's double value, or 0.0 if the value doesn't contain a + * double. + */ + double getDouble() const; + + /** + * Sets the value as a double. + * @param newDouble New double value that the Value will contain. The + * value's type is changed if necessary to contain the double. + */ + void setDouble(double newDouble); + + /** + * Gets the value's object value. + * @return Value's object value, or an empty object if the value doesn't + * contain an object. + */ + const Object &getObject() const; + + /** + * Sets the value as a JSON object. + * @param newObject New object value that the Value will contain. The + * value's type is changed if necessary to contain the object. + */ + void setObject(const Object &newObject); + + /** + * Gets the value's array value. + * @return Value's array value, or an empty Array if the value doesn't + * contain an array. + */ + const Array &getArray() const; + + /** + * Sets the value as a JSON array. + * @param newArray New array value that the Value will contain. The + * value's type is changed if necessary to contain the array. + */ + void setArray(const Array &newArray); + + /** + * Gets the value's boolean value. + * @return Value's boolean value, or false if the value doesn't contain + * a boolean. + */ + bool getBoolean() const; + + /** + * Sets the value as a boolean. + * @param newBoolean New boolean value that the Value will contain. The + * value's type is changed if necessary to contain the boolean. + */ + void setBoolean(bool newBoolean); + + /** + * Sets the value as a null value. + */ + void setNull(); + + /** + * Loads the current value from a string containing the JSON to parse. + * @param json String containing the JSON to parse. + */ + void loadFromString(const std::string &json); + + /** + * Loads a Value from a stream containing valid JSON in UTF-8. Does not + * read the stream if it is in UTF-32 or UTF-16. All the json escape + * sequences in string values are converted to their char equivalent, + * including unicode characters. Unicode characters that use two "\u" + * sequences are interpreted as two unicode characters, so it doesn't + * support perfect parsing. + * @param input Input stream to read from. Can be a file stream. + */ + void loadFromStream(std::istream &input); + + /** + * Loads a value from a file. Loads the file then calls the + * loadFromStream(...) method. + * @param filePath Path to the JSON file to load. + * @see JsonBox::Value::loadFromStream + */ + void loadFromFile(const std::string &filePath); + + /** + * Writes the value to an output stream in valid JSON. Uses the + * overloaded output operator. + * @param output Output stream to write the value to. + * @param indent Specifies if the output is to have nice indentation or + * not. + * @param escapeAll Specifies if all the JSON escapable characters + * should be escaped or not. + * @see JsonBox::Value::operator<<(std::ostream& output, const Value& v) + * @see JsonBox::Value::escapeAllCharacters + * @see JsonBox::Value::escapeMinimumCharacters + */ + void writeToStream(std::ostream &output, bool indent = true, + bool escapeAll = false) const; + + /** + * Writes the value to a JSON file. Uses writeToStream(...). + * @param filePath Path to the file to write. + * @param indent Specifies if the output is to have nice indentation or + * not. + * @param escapeAll Specifies if all the JSON escapable characters + * should be escaped or not. + * @see JsonBox::Value::writeToStream + */ + void writeToFile(const std::string &filePath, bool indent = true, + bool escapeAll = false) const; + private: + /** + * Union used to contain the pointer to the value's data. + */ + union ValueDataPointer { + std::string *stringValue; + int *intValue; + double *doubleValue; + Object *objectValue; + Array *arrayValue; + bool *boolValue; + + /** + * Default constructor. Puts the pointers at NULL. + */ + ValueDataPointer(); + + /** + * Parameterized constructor. + * @param newConstStringValue Pointer to set to the string pointer. + */ + ValueDataPointer(std::string *newStringValue); + + /** + * Parameterized constructor. + * @param newConstIntValue Pointer to set to the int pointer. + */ + ValueDataPointer(int *newIntValue); + + /** + * Parameterized constructor. + * @param newConstDoubleValue Pointer to set to the double pointer. + */ + ValueDataPointer(double *newDoubleValue); + + /** + * Parameterized constructor. + * @param newConstObjectValue Pointer to set to the object pointer. + */ + ValueDataPointer(Object *newObjectValue); + + /** + * Parameterized constructor. + * @param newConstArrayValue Pointer to set to the array pointer. + */ + ValueDataPointer(Array *newArrayValue); + + /** + * Parameterized constructor. + * @param newConstBoolValue Pointer to set to the bool pointer. + */ + ValueDataPointer(bool *newBoolValue); + }; + + /** + * Empty string returned by getString() when the value doesn't contain a + * string. + * @see JsonBox::Value::getString + */ + static const std::string EMPTY_STRING; + + /** + * Default int value returned by getInt() when the value doesn't contain + * an integer. + * @see JsonBox::Value::getInt + */ + static const int EMPTY_INT = 0; + + /** + * Default double value returned by getDouble() when the value doesn't + * contain a double. + * @see JsonBox::Value::getDouble + */ + static const double EMPTY_DOUBLE; + + /** + * Default empty object value returned by getObject() when the value + * doesn't contain an object. + * @see JsonBox::Value::getObject + */ + static const Object EMPTY_OBJECT; + + /** + * Default empty array value returned by getArray() when the value + * doesn't contain an array. + * @see JsonBox::Value::getArray + */ + static const Array EMPTY_ARRAY; + + /** + * Default boolean value returned by getBoolean() when the value doesn't + * contain a boolean. + * @see JsonBox::Value::getBoolean + */ + static const bool EMPTY_BOOL = false; + + /** + * Checks if the char given is a hex digit. + * @return True if the char contains an hexadecimal digit (0-9, a-f or + * A-F). + */ + static bool isHexDigit(char digit); + + /** + * Checks if the char given is a JSON whitespace. + * @return True if the char is either a space, a horizontal tab, a line + * feed or a carriage return. + */ + static bool isWhiteSpace(char whiteSpace); + + /** + * Reads a JSON string from an input stream. + * @param input Input stream to read the string value from. + * @param result UTF-8 string read from the input stream. + */ + static void readString(std::istream &input, std::string &result); + + /** + * Reads a JSON object from an input stream. + * @param input Input stream to read the object from. + * @param result Object read from the input stream. + */ + static void readObject(std::istream &input, Object &result); + + /** + * Reads a JSON array from an input stream. + * @param input Input stream to read the array from. + * @param result Array read from the input stream. + */ + static void readArray(std::istream &input, Array &result); + + /** + * Reads a JSON number from an input stream. + * @param input Input stream to read the array from. + * @param result Value containing the integer or the double read from + * the input stream. + */ + static void readNumber(std::istream &input, Value &result); + + /** + * Advances through the input stream until it reaches a character that + * is not a whitespace. + * @param input Input stream to read the whitespace characters from. + * @param currentCharacter Char in which each character read is + * temporarily stored. After the method is called, this char contains + * the first non white space character reached. + */ + static void readToNonWhiteSpace(std::istream &input, + char ¤tCharacter); + + /** + * Frees up the dynamic memory allocated by the value. + */ + void clear(); + + /** + * Outputs the value in JSON format. + * @param output Output stream used to output the value in JSON format. + * @param indent Specifies if the JSON being output must be indented or + * not. False is to output the JSON in compact format. + * @param escapeAll Specifies if the strings must escape all characters + * or only the minimum. + * @see JsonBox::Value::escapeAllCharacters(const std::string str) + * @see JsonBox::Value::escapeMinimumCharacters(const std::string str) + * @see JsonBox::Value::output(std::ostream& output, unsigned int& level, bool indent, bool escapeAll) + */ + void output(std::ostream &output, bool indent = true, + bool escapeAll = false) const; + + /** + * Type of data the value contains. + */ + Type type; + + /** + * Pointer to the Value's data. + */ + ValueDataPointer data; + }; +} + +#endif diff --git a/libs/JsonBox/sn.txt b/libs/JsonBox/sn.txt new file mode 100644 index 0000000..b3f5f21 --- /dev/null +++ b/libs/JsonBox/sn.txt @@ -0,0 +1,21 @@ +https://github.com/anhero/JsonBox + +xcode +Header Search Paths +"$(SRCROOT)/../libs/JsonBox/include" + + +JsonBox::Value json; +// json.loadFromString("{\"a\":\"A\", \"b\":\"B\", \"c\":\"C\"}"); + json.loadFromString("[5, 6, 7]"); + +// CCLog("%s", json["a"].getString().c_str()); +// CCLog("%i", json.getArray()[1].getInt()); + +// json["d"] = "D"; + + std::ostringstream s; + json.writeToStream(s); + string result = s.str(); + + CCLog("%s", result.c_str()); diff --git a/libs/JsonBox/src/Array.cpp b/libs/JsonBox/src/Array.cpp new file mode 100644 index 0000000..1f1fc35 --- /dev/null +++ b/libs/JsonBox/src/Array.cpp @@ -0,0 +1,199 @@ +#include + +#include +#include +#include +#include + +namespace JsonBox { + Array::Array(const allocator_type &alloc) : data(alloc) { + } + + Array::Array(size_type count, const_reference value, const allocator_type &alloc) : data(count, value, alloc) { + } + + Array::Array(const Array &other) : data(other.data) { + } + + Array &Array::operator=(const Array &other) { + data = other.data; + return *this; + } + + bool Array::operator==(const Array &rhs) const { + return data == rhs.data; + } + + bool Array::operator!=(const Array &rhs) const { + return data != rhs.data; + } + + bool Array::operator<(const Array &rhs) const { + return data < rhs.data; + } + + bool Array::operator<=(const Array &rhs) const { + return data <= rhs.data; + } + + bool Array::operator>(const Array &rhs) const { + return data > rhs.data; + } + + bool Array::operator>=(const Array &rhs) const { + return data >= rhs.data; + } + + void Array::assign(size_type count, const_reference value) { + data.assign(count, value); + } + + Array::allocator_type Array::get_allocator() const { + return data.get_allocator(); + } + + Array::reference Array::at(size_type pos) { + return data.at(pos); + } + + Array::const_reference Array::at(size_type pos) const { + return data.at(pos); + } + + Array::reference Array::operator[](size_type pos) { + return data[pos]; + } + + Array::const_reference Array::operator[](size_type pos) const { + return data[pos]; + } + + Array::reference Array::front() { + return data.front(); + } + + Array::const_reference Array::front() const { + return data.front(); + } + + Array::reference Array::back() { + return data.back(); + } + + Array::const_reference Array::back() const { + return data.back(); + } + + Array::iterator Array::begin() { + return data.begin(); + } + + Array::const_iterator Array::begin() const { + return data.begin(); + } + + Array::iterator Array::end() { + return data.end(); + } + + Array::const_iterator Array::end() const { + return data.end(); + } + + Array::reverse_iterator Array::rbegin() { + return data.rbegin(); + } + + Array::const_reverse_iterator Array::rbegin() const { + return data.rbegin(); + } + + Array::reverse_iterator Array::rend() { + return data.rend(); + } + + Array::const_reverse_iterator Array::rend() const { + return data.rend(); + } + + bool Array::empty() const { + return data.empty(); + } + + Array::size_type Array::size() const { + return data.size(); + } + + Array::size_type Array::max_size() const { + return data.max_size(); + } + + void Array::reserve(size_type size) { + data.reserve(size); + } + + Array::size_type Array::capacity() const { + return data.capacity(); + } + + void Array::clear() { + data.clear(); + } + + Array::iterator Array::insert(iterator pos, const_reference value) { + return data.insert(pos, value); + } + + void Array::insert(iterator pos, size_type count, const_reference value) { + data.insert(pos, count, value); + } + + Array::iterator Array::erase(iterator pos) { + return data.erase(pos); + } + + Array::iterator Array::erase(iterator first, iterator last) { + return data.erase(first, last); + } + + void Array::push_back(const_reference value) { + data.push_back(value); + } + + void Array::pop_back() { + data.pop_back(); + } + + void Array::resize(size_type count, const_reference value) { + data.resize(count, value); + } + + void Array::swap(Array &other) { + data.swap(other.data); + } + + std::ostream &operator<<(std::ostream &output, const Array &a) { + if (a.empty()) { + output << Structural::BEGIN_ARRAY << Structural::END_ARRAY; + + } else { + output << Structural::BEGIN_ARRAY << std::endl; + OutputFilter indent(output.rdbuf()); + output.rdbuf(&indent); + + for (Array::const_iterator i = a.begin(); i != a.end(); ++i) { + if (i != a.begin()) { + output << Structural::VALUE_SEPARATOR << std::endl; + } + + output << *i; + } + + output.rdbuf(indent.getDestination()); + + output << std::endl << Structural::END_ARRAY; + } + + return output; + } +} diff --git a/libs/JsonBox/src/Convert.cpp b/libs/JsonBox/src/Convert.cpp new file mode 100644 index 0000000..0aa72b1 --- /dev/null +++ b/libs/JsonBox/src/Convert.cpp @@ -0,0 +1,114 @@ +#include + +#include + +#define MASKBITS 0x3F //00111111 +#define MASK1BYTE 0x80 //10000000 +#define MASK2BYTES 0xC0 //11000000 +#define MASK3BYTES 0xE0 //11100000 +#define MASK4BYTES 0xF0 //11110000 +#define MASK5BYTES 0xF8 //11111000 +#define MASK6BYTES 0xFC //11111100 + +namespace JsonBox { + std::string Convert::encodeToUTF8(const String32& utf32String) { + std::stringstream result; + + for(String32::const_iterator i = utf32String.begin() ; i < utf32String.end(); ++i) { + // 0xxxxxxx + if(*i < 0x80) { + result << static_cast(*i); + } + // 110xxxxx 10xxxxxx + else if(*i < 0x800) { + result << static_cast(MASK2BYTES | (*i >> 6)); + result << static_cast(MASK1BYTE | (*i & MASKBITS)); + } + // 1110xxxx 10xxxxxx 10xxxxxx + else if(*i < 0x10000) { + result << static_cast(MASK3BYTES | (*i >> 12)); + result << static_cast(MASK1BYTE | (*i >> 6 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i & MASKBITS)); + } + // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx + else if(*i < 0x200000) { + result << static_cast(MASK4BYTES | (*i >> 18)); + result << static_cast(MASK1BYTE | (*i >> 12 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i >> 6 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i & MASKBITS)); + } + // 111110xx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx + else if(*i < 0x4000000) { + result << static_cast(MASK5BYTES | (*i >> 24)); + result << static_cast(MASK1BYTE | (*i >> 18 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i >> 12 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i >> 6 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i & MASKBITS)); + } + // 1111110x 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx + else if(*i < 0x8000000) { + result << static_cast(MASK6BYTES | (*i >> 30)); + result << static_cast(MASK1BYTE | (*i >> 18 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i >> 12 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i >> 6 & MASKBITS)); + result << static_cast(MASK1BYTE | (*i & MASKBITS)); + } + } + + return result.str(); + } + + String32 Convert::decodeUTF8(const std::string& utf8String) { + String32 result; + + String32::value_type tmpUnicodeChar; + + for(std::string::const_iterator i = utf8String.begin() ; i < utf8String.end();) { + + // 1111110x 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx + if((*i & MASK6BYTES) == MASK6BYTES) { + tmpUnicodeChar = ((*i & 0x01) << 30) | ((*(i + 1) & MASKBITS) << 24) + | ((*(i + 2) & MASKBITS) << 18) | ((*(i + 3) + & MASKBITS) << 12) + | ((*(i + 4) & MASKBITS) << 6) | (*(i + 5) & MASKBITS); + i += 6; + } + // 111110xx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx + else if((*i & MASK5BYTES) == MASK5BYTES) { + tmpUnicodeChar = ((*i & 0x03) << 24) | ((*(i + 1) + & MASKBITS) << 18) + | ((*(i + 2) & MASKBITS) << 12) | ((*(i + 3) + & MASKBITS) << 6) + | (*(i + 4) & MASKBITS); + i += 5; + } + // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx + else if((*i & MASK4BYTES) == MASK4BYTES) { + tmpUnicodeChar = ((*i & 0x07) << 18) | ((*(i + 1) + & MASKBITS) << 12) + | ((*(i + 2) & MASKBITS) << 6) | (*(i + 3) & MASKBITS); + i += 4; + } + // 1110xxxx 10xxxxxx 10xxxxxx + else if((*i & MASK3BYTES) == MASK3BYTES) { + tmpUnicodeChar = ((*i & 0x0F) << 12) | ((*(i + 1) & MASKBITS) << 6) + | (*(i + 2) & MASKBITS); + i += 3; + } + // 110xxxxx 10xxxxxx + else if((*i & MASK2BYTES) == MASK2BYTES) { + tmpUnicodeChar = ((*i & 0x1F) << 6) | (*(i + 1) & MASKBITS); + i += 2; + } + // 0xxxxxxx + else { // if(*i < MASK1BYTE) + tmpUnicodeChar = *i; + i += 1; + } + + result.push_back(tmpUnicodeChar); + } + + return result; + } +} diff --git a/libs/JsonBox/src/Escaper.cpp b/libs/JsonBox/src/Escaper.cpp new file mode 100644 index 0000000..760d62a --- /dev/null +++ b/libs/JsonBox/src/Escaper.cpp @@ -0,0 +1,56 @@ +#include + +#include +#include + +namespace JsonBox { + Escaper::Escaper() : afterBackSlash(false), inString(false) { + } + + std::streambuf::int_type Escaper::operator()(std::streambuf &destination, + std::streambuf::int_type character) { + bool notEscaped = true; + std::streambuf::char_type tmpChar = std::streambuf::traits_type::to_char_type(character); + + // If we encounter a quotation mark. + if (tmpChar == Structural::BEGIN_END_STRING) { + // If we're not in a string, we change that. If we're in a string, + // we change that only if we're not after an escape back slash. + inString = !inString || (afterBackSlash); + + } else if (inString && !afterBackSlash) { + // If we are in a string definition and we're not after a backslash + // escape. + if (tmpChar == Strings::Std::REVERSE_SOLIDUS) { + destination.sputn(Strings::Json::REVERSE_SOLIDUS.c_str(), Strings::Json::REVERSE_SOLIDUS.size()); + notEscaped = false; + + } else if (tmpChar == Strings::Std::BACKSPACE) { + destination.sputn(Strings::Json::BACKSPACE.c_str(), Strings::Json::BACKSPACE.size()); + notEscaped = false; + + } else if (tmpChar == Strings::Std::FORM_FEED) { + destination.sputn(Strings::Json::FORM_FEED.c_str(), Strings::Json::FORM_FEED.size()); + notEscaped = false; + + } else if (tmpChar == Strings::Std::LINE_FEED) { + destination.sputn(Strings::Json::LINE_FEED.c_str(), Strings::Json::LINE_FEED.size()); + notEscaped = false; + + } else if (tmpChar == Strings::Std::TAB) { + destination.sputn(Strings::Json::TAB.c_str(), Strings::Json::TAB.size()); + notEscaped = false; + + } else if (tmpChar >= '\0' && tmpChar <= '\x1f') { + std::string tmp(Value::escapeToUnicode(tmpChar)); + destination.sputn(tmp.c_str(), tmp.size()); + notEscaped = false; + } + + } + + // We determine if we start a backslash escape or not. + afterBackSlash = inString && !afterBackSlash && (tmpChar == Strings::Json::Escape::BEGIN_ESCAPE); + return (notEscaped) ? (destination.sputc(tmpChar)) : (0); + } +} diff --git a/libs/JsonBox/src/IndentCanceller.cpp b/libs/JsonBox/src/IndentCanceller.cpp new file mode 100644 index 0000000..47566c5 --- /dev/null +++ b/libs/JsonBox/src/IndentCanceller.cpp @@ -0,0 +1,25 @@ +#include + +#include + +namespace JsonBox { + IndentCanceller::IndentCanceller() : afterBackSlash(false), inString(false) { + } + + std::streambuf::int_type IndentCanceller::operator()(std::streambuf &destination, + std::streambuf::int_type character) { + std::streambuf::char_type tmpChar = std::streambuf::traits_type::to_char_type(character); + + // If we encounter a quotation mark. + if (tmpChar == Structural::BEGIN_END_STRING) { + // If we're not in a string, we change that. If we're in a string, + // we change that only if we're not after an escape back slash. + inString = !inString || (afterBackSlash); + } + + // We determine if we start a backslash escape or not. + afterBackSlash = inString && !afterBackSlash && (tmpChar == Strings::Json::Escape::BEGIN_ESCAPE); + + return (tmpChar != Whitespace::NEW_LINE && tmpChar != Whitespace::HORIZONTAL_TAB && tmpChar != Whitespace::CARRIAGE_RETURN && (inString || tmpChar != Whitespace::SPACE)) ? (destination.sputc(tmpChar)) : (0); + } +} diff --git a/libs/JsonBox/src/Indenter.cpp b/libs/JsonBox/src/Indenter.cpp new file mode 100644 index 0000000..0100786 --- /dev/null +++ b/libs/JsonBox/src/Indenter.cpp @@ -0,0 +1,20 @@ +#include + +#include + +namespace JsonBox { + Indenter::Indenter() : atStartOfLine(true) { + } + + std::streambuf::int_type Indenter::operator()(std::streambuf &destination, + std::streambuf::int_type character) { + std::streambuf::char_type tmpChar = std::streambuf::traits_type::to_char_type(character); + + if (atStartOfLine && tmpChar != Whitespace::NEW_LINE) { + destination.sputc(Whitespace::HORIZONTAL_TAB); + } + + atStartOfLine = (tmpChar == Whitespace::NEW_LINE); + return destination.sputc(tmpChar); + } +} diff --git a/libs/JsonBox/src/Object.cpp b/libs/JsonBox/src/Object.cpp new file mode 100644 index 0000000..ae958a8 --- /dev/null +++ b/libs/JsonBox/src/Object.cpp @@ -0,0 +1,191 @@ +#include + +#include +#include +#include +#include + +namespace JsonBox { + Object::Object(const key_compare &comp, const allocator_type &alloc) : data(comp, alloc) { + } + + Object::Object(const Object &other) : data(other.data) { + } + + Object &Object::operator=(const Object &other) { + data = other.data; + return *this; + } + + bool Object::operator==(const Object &rhs) const { + return data == rhs.data; + } + + bool Object::operator!=(const Object &rhs) const { + return data != rhs.data; + } + + bool Object::operator<(const Object &rhs) const { + return data < rhs.data; + } + + bool Object::operator<=(const Object &rhs) const { + return data <= rhs.data; + } + + bool Object::operator>(const Object &rhs) const { + return data > rhs.data; + } + + bool Object::operator>=(const Object &rhs) const { + return data >= rhs.data; + } + + Object::allocator_type Object::get_allocator() const { + return data.get_allocator(); + } + + Object::mapped_type &Object::operator[](const key_type &key) { + return data[key]; + } + + Object::iterator Object::begin() { + return data.begin(); + } + + Object::const_iterator Object::begin() const { + return data.begin(); + } + + Object::iterator Object::end() { + return data.end(); + } + + Object::const_iterator Object::end() const { + return data.end(); + } + + Object::reverse_iterator Object::rbegin() { + return data.rbegin(); + } + + Object::const_reverse_iterator Object::rbegin() const { + return data.rbegin(); + } + + Object::reverse_iterator Object::rend() { + return data.rend(); + } + + Object::const_reverse_iterator Object::rend() const { + return data.rend(); + } + + bool Object::empty() const { + return data.empty(); + } + + Object::size_type Object::size() const { + return data.size(); + } + + Object::size_type Object::max_size() const { + return data.max_size(); + } + + void Object::clear() { + data.clear(); + } + + std::pair Object::insert(const_reference value) { + return data.insert(value); + } + + Object::iterator Object::insert(iterator hint, const_reference value) { + return data.insert(hint, value); + } + + void Object::erase(iterator position) { + data.erase(position); + } + + void Object::erase(iterator first, iterator last) { + data.erase(first, last); + } + + Object::size_type Object::erase(const key_type &key) { + return data.erase(key); + } + + void Object::swap(Object &other) { + data.swap(other.data); + } + + Object::size_type Object::count(const key_type &key) const { + return data.count(key); + } + + Object::iterator Object::find(const key_type &key) { + return data.find(key); + } + + Object::const_iterator Object::find(const key_type &key) const { + return data.find(key); + } + + std::pair Object::equal_range(const key_type &key) { + return data.equal_range(key); + } + + std::pair Object::equal_range(const key_type &key) const { + return data.equal_range(key); + } + + Object::iterator Object::lower_bound(const key_type &key) { + return data.lower_bound(key); + } + + Object::const_iterator Object::lower_bound(const key_type &key) const { + return data.lower_bound(key); + } + + Object::iterator Object::upper_bound(const key_type &key) { + return data.upper_bound(key); + } + + Object::const_iterator Object::upper_bound(const key_type &key) const { + return data.upper_bound(key); + } + + Object::key_compare Object::key_comp() const { + return data.key_comp(); + } + + std::ostream &operator<<(std::ostream &output, const Object &o) { + // If the object is empty, we simply write "{}". + if (o.empty()) { + output << Structural::BEGIN_OBJECT << Structural::END_OBJECT; + + } else { + output << Structural::BEGIN_OBJECT << std::endl; + OutputFilter indent(output.rdbuf()); + output.rdbuf(&indent); + + // For each item in the object. + for (Object::const_iterator i = o.begin(); i != o.end(); ++i) { + if (i != o.begin()) { + output << Structural::VALUE_SEPARATOR << std::endl; + } + + // We print the name of the attribute and its value. + output << Structural::BEGIN_END_STRING << Value::escapeMinimumCharacters(i->first) << Structural::BEGIN_END_STRING << Whitespace::SPACE << Structural::NAME_SEPARATOR << Whitespace::SPACE << i->second; + } + + output.rdbuf(indent.getDestination()); + + output << std::endl << Structural::END_OBJECT; + } + + return output; + } +} diff --git a/libs/JsonBox/src/SolidusEscaper.cpp b/libs/JsonBox/src/SolidusEscaper.cpp new file mode 100644 index 0000000..5b20d5d --- /dev/null +++ b/libs/JsonBox/src/SolidusEscaper.cpp @@ -0,0 +1,35 @@ +#include + +#include + +namespace JsonBox { + SolidusEscaper::SolidusEscaper() : afterBackSlash(false), inString(false) { + } + + std::streambuf::int_type SolidusEscaper::operator()(std::streambuf &destination, + std::streambuf::int_type character) { + bool notEscaped = true; + std::streambuf::char_type tmpChar = std::streambuf::traits_type::to_char_type(character); + + // If we encounter a quotation mark. + if (tmpChar == Strings::Json::Escape::QUOTATION_MARK) { + // If we're not in a string, we change that. If we're in a string, + // we change that only if we're not after an escape back slash. + inString = !inString || (afterBackSlash); + + } else if (inString && !afterBackSlash) { + // If we are in a string definition and we're not after a backslash + // escape. + if (tmpChar == Strings::Std::SOLIDUS) { + destination.sputn(Strings::Json::SOLIDUS.c_str(), Strings::Json::SOLIDUS.size()); + notEscaped = false; + + } + + } + + // We determine if we start a backslash escape or not. + afterBackSlash = inString && !afterBackSlash && (tmpChar == Strings::Json::Escape::BEGIN_ESCAPE); + return (notEscaped) ? (destination.sputc(tmpChar)) : (0); + } +} diff --git a/libs/JsonBox/src/Value.cpp b/libs/JsonBox/src/Value.cpp new file mode 100755 index 0000000..0dcbb65 --- /dev/null +++ b/libs/JsonBox/src/Value.cpp @@ -0,0 +1,1108 @@ +#include + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +namespace JsonBox { + + const std::string Value::EMPTY_STRING = std::string(); + const double Value::EMPTY_DOUBLE = 0.0; + const Object Value::EMPTY_OBJECT = Object(); + const Array Value::EMPTY_ARRAY = Array(); + + std::string Value::escapeMinimumCharacters(const std::string &str) { + std::stringstream result; + + // For each character in the string. + for (std::string::const_iterator i = str.begin(); i != str.end(); ++i) { + if (*i == Strings::Std::QUOTATION_MARK) { + result << Strings::Json::QUOTATION_MARK; + + } else if (*i == Strings::Std::REVERSE_SOLIDUS) { + result << Strings::Json::REVERSE_SOLIDUS; + + } else if (*i == Strings::Std::BACKSPACE) { + result << Strings::Json::BACKSPACE; + + } else if (*i == Strings::Std::FORM_FEED) { + result << Strings::Json::FORM_FEED; + + } else if (*i == Strings::Std::LINE_FEED) { + result << Strings::Json::LINE_FEED; + + } else if (*i == Strings::Std::CARRIAGE_RETURN) { + result << Strings::Json::CARRIAGE_RETURN; + + } else if (*i == Strings::Std::TAB) { + result << Strings::Json::TAB; + + } else if (*i >= '\0' && *i <= '\x1f') { + result << Value::escapeToUnicode(*i); + + } else { + result << *i; + } + } + + return result.str(); + } + + std::string Value::escapeAllCharacters(const std::string &str) { + std::stringstream result; + + // For each character in the string. + for (std::string::const_iterator i = str.begin(); i != str.end(); ++i) { + if (*i == Strings::Std::QUOTATION_MARK) { + result << Strings::Json::QUOTATION_MARK; + + } else if (*i == Strings::Std::REVERSE_SOLIDUS) { + result << Strings::Json::REVERSE_SOLIDUS; + + } else if (*i == Strings::Std::SOLIDUS) { + result << Strings::Json::SOLIDUS; + + } else if (*i == Strings::Std::BACKSPACE) { + result << Strings::Json::BACKSPACE; + + } else if (*i == Strings::Std::FORM_FEED) { + result << Strings::Json::FORM_FEED; + + } else if (*i == Strings::Std::LINE_FEED) { + result << Strings::Json::LINE_FEED; + + } else if (*i == Strings::Std::CARRIAGE_RETURN) { + result << Strings::Json::CARRIAGE_RETURN; + + } else if (*i == Strings::Std::TAB) { + result << Strings::Json::TAB; + + } else if (*i >= '\0' && *i <= '\x1f') { + result << Value::escapeToUnicode(*i); + + } else { + result << *i; + } + + } + + return result.str(); + } + + + const std::string Value::escapeToUnicode(char charToEscape) { + std::stringstream result; + + if (charToEscape >= '\0' && charToEscape <= '\x1f') { + result << "\\u00"; + result << std::hex << std::setfill('0') << std::setw(2) << static_cast(charToEscape); + } + + return result.str(); + } + + Value::Value() : type(NULL_VALUE), data() { + } + + Value::Value(std::istream &input) : type(NULL_VALUE), data() { + loadFromStream(input); + } + + Value::Value(const std::string &newString) : type(STRING), + data(new std::string(newString)) { + } + + Value::Value(const char *newCString) : type(STRING), + data(new std::string(newCString)) { + } + + Value::Value(int newInt) : type(INTEGER), data(new int(newInt)) { + } + + Value::Value(double newDouble) : type(DOUBLE), data(new double(newDouble)) { + } + + Value::Value(const Object &newObject) : type(OBJECT), + data(new Object(newObject)) { + } + + Value::Value(const Array &newArray) : type(ARRAY), + data(new Array(newArray)) { + } + + Value::Value(bool newBoolean) : type(BOOLEAN), data(new bool(newBoolean)) { + } + + Value::Value(const Value &src) : type(src.type), data() { + switch (type) { + case STRING: + data.stringValue = new std::string(*src.data.stringValue); + break; + + case INTEGER: + data.intValue = new int(*src.data.intValue); + break; + + case DOUBLE: + data.doubleValue = new double(*src.data.doubleValue); + break; + + case OBJECT: + data.objectValue = new Object(*src.data.objectValue); + break; + + case ARRAY: + data.arrayValue = new Array(*src.data.arrayValue); + break; + + case BOOLEAN: + data.boolValue = new bool(*src.data.boolValue); + break; + + default: + type = NULL_VALUE; + break; + } + } + + Value::~Value() { + clear(); + } + + Value &Value::operator=(const Value &src) { + if (this != &src) { + clear(); + type = src.type; + + switch (type) { + case STRING: + data.stringValue = new std::string(*src.data.stringValue); + break; + + case INTEGER: + data.intValue = new int(*src.data.intValue); + break; + + case DOUBLE: + data.doubleValue = new double(*src.data.doubleValue); + break; + + case OBJECT: + data.objectValue = new Object(*src.data.objectValue); + break; + + case ARRAY: + data.arrayValue = new Array(*src.data.arrayValue); + break; + + case BOOLEAN: + data.boolValue = new bool(*src.data.boolValue); + break; + + default: + type = NULL_VALUE; + data.stringValue = NULL; + break; + } + } + + return *this; + } + + bool Value::operator==(const Value &rhs) const { + bool result = true; + + if (this != &rhs) { + if (type == rhs.type) { + switch (type) { + case STRING: + result = (*data.stringValue == *data.stringValue); + break; + + case INTEGER: + result = (*data.intValue == *data.intValue); + break; + + case DOUBLE: + result = (*data.doubleValue == *data.doubleValue); + break; + + case OBJECT: + result = (*data.objectValue == *data.objectValue); + break; + + case ARRAY: + result = (*data.arrayValue == *data.arrayValue); + break; + + case BOOLEAN: + result = (*data.boolValue == *data.boolValue); + break; + + default: + break; + } + + } else { + result = false; + } + } + + return result; + } + + bool Value::operator!=(const Value &rhs) const { + return !(*this == rhs); + } + + bool Value::operator<(const Value &rhs) const { + bool result = false; + + if (this != &rhs) { + if (type == rhs.type) { + switch (type) { + case STRING: + result = (*data.stringValue < *data.stringValue); + break; + + case INTEGER: + result = (*data.intValue < *data.intValue); + break; + + case DOUBLE: + result = (*data.doubleValue < *data.doubleValue); + break; + + case OBJECT: + result = (*data.objectValue < *data.objectValue); + break; + + case ARRAY: + result = (*data.arrayValue < *data.arrayValue); + break; + + case BOOLEAN: + result = (*data.boolValue < *data.boolValue); + break; + + default: + break; + } + + } + } + + return result; + } + + bool Value::operator<=(const Value &rhs) const { + return *this < rhs || *this == rhs; + } + + bool Value::operator>(const Value &rhs) const { + bool result = false; + + if (this != &rhs) { + if (type == rhs.type) { + switch (type) { + case STRING: + result = (*data.stringValue > *data.stringValue); + break; + + case INTEGER: + result = (*data.intValue > *data.intValue); + break; + + case DOUBLE: + result = (*data.doubleValue > *data.doubleValue); + break; + + case OBJECT: + result = (*data.objectValue > *data.objectValue); + break; + + case ARRAY: + result = (*data.arrayValue > *data.arrayValue); + break; + + case BOOLEAN: + result = (*data.boolValue > *data.boolValue); + break; + + default: + break; + } + + } + } + + return result; + } + + bool Value::operator>=(const Value &rhs) const { + return *this > rhs || *this == rhs; + } + + Value &Value::operator[](const Object::key_type &key) { + if (type != OBJECT) { + clear(); + type = OBJECT; + data.objectValue = new Object(); + } + + return (*data.objectValue)[key]; + } + + Value &Value::operator[](const char *key) { + return operator[](std::string(key)); + } + + Value &Value::operator[](Array::size_type index) { + if (type != ARRAY) { + clear(); + type = ARRAY; + data.arrayValue = new Array(index + 1); + } + + assert(index <= (*data.arrayValue).size()); + + if(index == (*data.arrayValue).size()) + { + (*data.arrayValue).push_back(Value()); + return (*data.arrayValue).back(); + } + else + { + return (*data.arrayValue)[index]; + } + } + + Value::Type Value::getType() const { + return type; + } + + bool Value::isString() const { + return type == STRING; + } + + bool Value::isInteger() const { + return type == INTEGER; + } + + bool Value::isDouble() const { + return type == DOUBLE; + } + + bool Value::isObject() const { + return type == OBJECT; + } + + bool Value::isArray() const { + return type == ARRAY; + } + + bool Value::isBoolean() const { + return type == BOOLEAN; + } + + bool Value::isNull() const { + return type == NULL_VALUE; + } + + const std::string &Value::getString() const { + return (type == STRING) ? (*data.stringValue) : (EMPTY_STRING); + } + + void Value::setString(std::string const &newString) { + if (type == STRING) { + *data.stringValue = newString; + + } else { + clear(); + type = STRING; + data.stringValue = new std::string(newString); + } + } + + int Value::getInt() const { + return (type == INTEGER) ? (*data.intValue) : (EMPTY_INT); + } + + void Value::setInt(int newInt) { + if (type == INTEGER) { + *data.intValue = newInt; + + } else { + clear(); + type = INTEGER; + data.intValue = new int(newInt); + } + } + + double Value::getDouble() const { + return (type == DOUBLE) ? (*data.doubleValue) : (EMPTY_DOUBLE); + } + + void Value::setDouble(double newDouble) { + if (type == DOUBLE) { + *data.doubleValue = newDouble; + + } else { + clear(); + type = DOUBLE; + data.doubleValue = new double(newDouble); + } + } + + const Object &Value::getObject() const { + return (type == OBJECT) ? (*data.objectValue) : (EMPTY_OBJECT); + } + + void Value::setObject(const Object &newObject) { + if (type == OBJECT) { + *data.objectValue = newObject; + + } else { + clear(); + type = OBJECT; + data.objectValue = new Object(newObject); + } + } + + const Array &Value::getArray() const { + return (type == ARRAY) ? (*data.arrayValue) : (EMPTY_ARRAY); + } + + void Value::setArray(const Array &newArray) { + if (type == ARRAY) { + *data.arrayValue = newArray; + + } else { + clear(); + type = ARRAY; + data.arrayValue = new Array(newArray); + } + } + + bool Value::getBoolean() const { + return (type == BOOLEAN) ? (*data.boolValue) : (EMPTY_BOOL); + } + + void Value::setBoolean(bool newBoolean) { + if (type == BOOLEAN) { + *data.boolValue = newBoolean; + + } else { + clear(); + type = BOOLEAN; + data.boolValue = new bool(newBoolean); + } + } + + void Value::setNull() { + clear(); + type = NULL_VALUE; + data.stringValue = NULL; + } + + void Value::loadFromString(std::string const &json) { + std::stringstream jsonStream(json); + loadFromStream(jsonStream); + } + + void Value::loadFromStream(std::istream &input) { + char currentCharacter; + + // We check that the stream is in UTF-8. + char encoding[2]; + input.get(encoding[0]); + input.get(encoding[1]); + + if (encoding[0] != '\0' && encoding[1] != '\0') { + // We put the characters back. + input.putback(encoding[1]); + input.putback(encoding[0]); + + // Boolean value used to stop reading characters after the value + // is done loading. + bool noErrors = true; + + while (noErrors && input.good()) { + input.get(currentCharacter); + + if (input.good()) { + if (currentCharacter == Structural::BEGIN_END_STRING) { + // The value to be parsed is a string. + setString(""); + readString(input, *data.stringValue); + noErrors = false; + + } else if (currentCharacter == Structural::BEGIN_OBJECT) { + // The value to be parsed is an object. + setObject(Object()); + readObject(input, *data.objectValue); + noErrors = false; + + } else if (currentCharacter == Structural::BEGIN_ARRAY) { + // The value to be parsed is an array. + setArray(Array()); + readArray(input, *data.arrayValue); + noErrors = false; + + } else if (currentCharacter == Literals::NULL_STRING[0]) { + // We try to read the literal 'null'. + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::NULL_STRING[1]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::NULL_STRING[2]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::NULL_STRING[3]) { + setNull(); + noErrors = false; + + } else { + std::cout << "invalid characters found" << std::endl; + } + + } else { + std::cout << "json input ends incorrectly" << std::endl; + } + + } else { + std::cout << "invalid characters found" << std::endl; + } + + } else { + std::cout << "json input ends incorrectly" << std::endl; + } + + } else { + std::cout << "invalid characters found" << std::endl; + } + + } else { + std::cout << "json input ends incorrectly" << std::endl; + } + + } else if (currentCharacter == Numbers::MINUS || + (currentCharacter >= Numbers::DIGITS[0] && currentCharacter <= Numbers::DIGITS[9])) { + // Numbers can't start with zeroes. + input.putback(currentCharacter); + readNumber(input, *this); + noErrors = false; + + } else if (currentCharacter == Literals::TRUE_STRING[0]) { + // We try to read the boolean literal 'true'. + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::TRUE_STRING[1]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::TRUE_STRING[2]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::TRUE_STRING[3]) { + setBoolean(true); + noErrors = false; + } + } + } + } + } + } + + } else if (currentCharacter == Literals::FALSE_STRING[0]) { + // We try to read the boolean literal 'false'. + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::FALSE_STRING[1]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::FALSE_STRING[2]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::FALSE_STRING[3]) { + if (!input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == Literals::FALSE_STRING[4]) { + setBoolean(false); + noErrors = false; + } + } + } + } + } + } + } + } + + } else if (!isWhiteSpace(currentCharacter)) { + std::cout << "Invalid character found: '" << currentCharacter << "'" << std::endl; + } + } + } + + } else { + std::cout << "File is not in UTF-8, not parsing." << std::endl; + } + } + + void Value::loadFromFile(const std::string &filePath) { + std::ifstream file; + file.open(filePath.c_str()); + + if (file.is_open()) { + loadFromStream(file); + file.close(); + + } else { + std::cout << "Failed to open file to load the json: " << filePath << std::endl; + } + } + + void Value::writeToStream(std::ostream &output, bool indent, + bool escapeAll) const { + this->output(output, indent, escapeAll); + } + + void Value::writeToFile(const std::string &filePath, bool indent, + bool escapeAll) const { + std::ofstream file; + file.open(filePath.c_str()); + + if (file.is_open()) { + writeToStream(file, indent, escapeAll); + file.close(); + + } else { + std::cout << "Failed to open file to write the json into: " << filePath << std::endl; + } + } + + Value::ValueDataPointer::ValueDataPointer(): stringValue(NULL) { + } + + Value::ValueDataPointer::ValueDataPointer(std::string *newStringValue) : + stringValue(newStringValue) { + } + + Value::ValueDataPointer::ValueDataPointer(int *newIntValue) : + intValue(newIntValue) { + } + + Value::ValueDataPointer::ValueDataPointer(double *newDoubleValue) : + doubleValue(newDoubleValue) { + } + + Value::ValueDataPointer::ValueDataPointer(Object *newObjectValue) : + objectValue(newObjectValue) { + } + + Value::ValueDataPointer::ValueDataPointer(Array *newArrayValue) : + arrayValue(newArrayValue) { + } + + Value::ValueDataPointer::ValueDataPointer(bool *newBoolValue) : + boolValue(newBoolValue) { + } + + bool Value::isHexDigit(char digit) { + return (digit >= Numbers::DIGITS[0] && digit <= Numbers::DIGITS[9]) || (digit >= Numbers::DIGITS[10] && digit <= Numbers::DIGITS[15]) || + (digit >= Numbers::DIGITS[16] && digit <= Numbers::DIGITS[21]); + } + + bool Value::isWhiteSpace(char whiteSpace) { + return whiteSpace == Whitespace::SPACE || + whiteSpace == Whitespace::HORIZONTAL_TAB || + whiteSpace == Whitespace::NEW_LINE || + whiteSpace == Whitespace::CARRIAGE_RETURN; + } + + void Value::readString(std::istream &input, std::string &result) { + bool noErrors = true, noUnicodeError = true; + char currentCharacter, tmpCharacter; + std::stringstream constructing; + std::string tmpStr(4, ' '); + std::stringstream tmpSs; + int32_t tmpInt; + String32 tmpStr32; + unsigned int tmpCounter; + + // As long as there aren't any errors and that we haven't reached the + // end of the input stream. + while (noErrors && !input.eof()) { + input.get(currentCharacter); + + if (input.good()) { + if (currentCharacter & 0x80) { // 0x80 --> 10000000 + // The character is part of an utf8 character. + constructing << currentCharacter; + + } else if (currentCharacter == Strings::Json::Escape::BEGIN_ESCAPE) { + if (!input.eof()) { + input.get(tmpCharacter); + + switch (tmpCharacter) { + case Strings::Json::Escape::QUOTATION_MARK: + constructing << Strings::Std::QUOTATION_MARK; + break; + + case Strings::Json::Escape::REVERSE_SOLIDUS: + constructing << Strings::Std::REVERSE_SOLIDUS; + break; + + case Strings::Json::Escape::SOLIDUS: + constructing << Strings::Std::SOLIDUS; + break; + + case Strings::Json::Escape::BACKSPACE: + constructing << Strings::Std::BACKSPACE; + break; + + case Strings::Json::Escape::FORM_FEED: + constructing << Strings::Std::FORM_FEED; + break; + + case Strings::Json::Escape::LINE_FEED: + constructing << Strings::Std::LINE_FEED; + break; + + case Strings::Json::Escape::CARRIAGE_RETURN: + constructing << Strings::Std::CARRIAGE_RETURN; + break; + + case Strings::Json::Escape::TAB: + constructing << Strings::Std::TAB; + break; + + case Strings::Json::Escape::BEGIN_UNICODE: + // TODO: Check for utf16 surrogate pairs. + tmpCounter = 0; + tmpStr.clear(); + tmpStr = " "; + noUnicodeError = true; + + while (tmpCounter < 4 && !input.eof()) { + input.get(tmpCharacter); + + if (isHexDigit(tmpCharacter)) { + tmpStr[tmpCounter] = tmpCharacter; + + } else { + noUnicodeError = false; + std::cout << "Invalid \\u character, skipping it." << std::endl; + } + + ++tmpCounter; + } + + if (noUnicodeError) { + tmpSs.clear(); + tmpSs.str(""); + tmpSs << std::hex << tmpStr; + tmpSs >> tmpInt; + tmpStr32.clear(); + tmpStr32.push_back(tmpInt); + tmpStr = Convert::encodeToUTF8(tmpStr32); + constructing << tmpStr; + } + + break; + + default: + break; + } + } + + } else if (currentCharacter == '"') { + result = constructing.str(); + noErrors = false; + + } else { + constructing << currentCharacter; + } + } + } + } + + void Value::readObject(std::istream &input, Object &result) { + bool noErrors = true; + char currentCharacter; + std::string tmpString; + + while (noErrors && !input.eof()) { + input.get(currentCharacter); + + if (input.good()) { + if (currentCharacter == Structural::BEGIN_END_STRING) { + // We read the object's member's name. + readString(input, tmpString); + currentCharacter = input.peek(); + // We read white spaces until the next non white space. + readToNonWhiteSpace(input, currentCharacter); + + if (!input.eof()) { + + // We make sure it's the right character. + if (currentCharacter == Structural::NAME_SEPARATOR) { + // We read until the value starts. + readToNonWhiteSpace(input, currentCharacter); + + if (!input.eof()) { + // We put the character back and we load the value + // from the stream. + input.putback(currentCharacter); + result[tmpString].loadFromStream(input); + + while (!input.eof() && currentCharacter != Structural::VALUE_SEPARATOR && + currentCharacter != Structural::END_OBJECT) { + input.get(currentCharacter); + } + + if (currentCharacter == Structural::END_OBJECT) { + // We are done reading the object. + noErrors = false; + } + } + } + } + + } else if (currentCharacter == Structural::END_OBJECT) { + noErrors = false; + + } else if (!isWhiteSpace(currentCharacter)) { + std::cout << "Expected '\"', got '" << currentCharacter << "', ignoring it." << std::endl; + } + } + } + } + + void Value::readArray(std::istream &input, Array &result) { + bool notDone = true; + char currentChar; + + while (notDone && !input.eof()) { + input.get(currentChar); + + if (input.good()) { + if (currentChar == Structural::END_ARRAY) { + notDone = false; + + } else if (!isWhiteSpace(currentChar)) { + input.putback(currentChar); + result.push_back(Value()); + result.back().type = UNKNOWN; + result.back().loadFromStream(input); + + if (result.back().type == UNKNOWN) { + result.pop_back(); + } + + while (!input.eof() && currentChar != ',' && + currentChar != Structural::END_ARRAY) { + input.get(currentChar); + } + + if (currentChar == Structural::END_ARRAY) { + notDone = false; + } + } + } + } + } + + void Value::readNumber(std::istream &input, JsonBox::Value &result) { + bool notDone = true, inFraction = false, inExponent = false; + char currentCharacter; + std::stringstream constructing; + + if (!input.eof() && input.peek() == Numbers::DIGITS[0]) { + // We make sure there isn't more than one zero. + input.get(currentCharacter); + + if (input.peek() == '0') { + notDone = false; + + } else { + input.putback(currentCharacter); + } + } + + while (notDone && !input.eof()) { + input.get(currentCharacter); + + if (currentCharacter == '-') { + if (constructing.str().empty()) { + constructing << currentCharacter; + + } else { + std::cout << "Expected a digit, '.', 'e' or 'E', got '" << currentCharacter << "' instead, ignoring it." << std::endl; + } + + } else if (currentCharacter >= '0' && currentCharacter <= '9') { + constructing << currentCharacter; + + } else if (currentCharacter == '.') { + if (!inFraction && !inExponent) { + inFraction = true; + constructing << currentCharacter; + } + + } else if (currentCharacter == 'e' || currentCharacter == 'E') { + if (!inExponent) { + inExponent = true; + constructing << currentCharacter; + + if (!input.eof() && (input.peek() == '-' || input.peek() == '+')) { + input.get(currentCharacter); + constructing << currentCharacter; + } + } + + } else { + input.putback(currentCharacter); + notDone = false; + } + } + + if (inFraction || inExponent) { + double doubleResult; + constructing >> doubleResult; + result.setDouble(doubleResult); + + } else { + int intResult; + constructing >> intResult; + result.setInt(intResult); + } + } + + void Value::readToNonWhiteSpace(std::istream &input, char ¤tCharacter) { + do { + input.get(currentCharacter); + } while (!input.eof() && isWhiteSpace(currentCharacter)); + } + + void Value::clear() { + switch (type) { + case STRING: + delete data.stringValue; + break; + + case INTEGER: + delete data.intValue; + break; + + case DOUBLE: + delete data.doubleValue; + break; + + case OBJECT: + delete data.objectValue; + break; + + case ARRAY: + delete data.arrayValue; + break; + + case BOOLEAN: + delete data.boolValue; + break; + + default: + break; + } + } + + void Value::output(std::ostream &output, bool indent, + bool escapeAll) const { + if (indent) { + if (escapeAll) { + OutputFilter solidusEscaper(output.rdbuf()); + output.rdbuf(&solidusEscaper); + output << *this; + output.rdbuf(solidusEscaper.getDestination()); + + } else { + output << *this; + } + + } else { + OutputFilter indentCanceller(output.rdbuf()); + output.rdbuf(&indentCanceller); + + if (escapeAll) { + OutputFilter solidusEscaper(output.rdbuf()); + output.rdbuf(&solidusEscaper); + output << *this; + output.rdbuf(solidusEscaper.getDestination()); + + } else { + output << *this; + } + + output.rdbuf(indentCanceller.getDestination()); + } + } + + std::ostream &operator<<(std::ostream &output, const Value &v) { + switch (v.type) { + case Value::STRING: + output << Structural::BEGIN_END_STRING << Value::escapeMinimumCharacters(v.getString()) << Structural::BEGIN_END_STRING; + break; + + case Value::INTEGER: + output << v.getInt(); + break; + + case Value::DOUBLE: + output << v.getDouble(); + break; + + case Value::OBJECT: + output << v.getObject(); + break; + + case Value::ARRAY: + output << v.getArray(); + break; + + case Value::BOOLEAN: + output << (v.getBoolean() ? Literals::TRUE_STRING : Literals::FALSE_STRING); + break; + + case Value::NULL_VALUE: + output << Literals::NULL_STRING; + break; + + default: + break; + } + + return output; + } +} diff --git a/proj.android/.classpath b/proj.android/.classpath new file mode 100644 index 0000000..a4763d1 --- /dev/null +++ b/proj.android/.classpath @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/proj.android/.project b/proj.android/.project new file mode 100644 index 0000000..c9ef1f5 --- /dev/null +++ b/proj.android/.project @@ -0,0 +1,33 @@ + + + OzgGameRPG + + + + + + com.android.ide.eclipse.adt.ResourceManagerBuilder + + + + + com.android.ide.eclipse.adt.PreCompilerBuilder + + + + + org.eclipse.jdt.core.javabuilder + + + + + com.android.ide.eclipse.adt.ApkBuilder + + + + + + com.android.ide.eclipse.adt.AndroidNature + org.eclipse.jdt.core.javanature + + diff --git a/proj.android/AndroidManifest.xml b/proj.android/AndroidManifest.xml new file mode 100644 index 0000000..fbd714c --- /dev/null +++ b/proj.android/AndroidManifest.xml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + diff --git a/proj.android/ant.properties b/proj.android/ant.properties new file mode 100644 index 0000000..b0971e8 --- /dev/null +++ b/proj.android/ant.properties @@ -0,0 +1,17 @@ +# This file is used to override default values used by the Ant build system. +# +# This file must be checked into Version Control Systems, as it is +# integral to the build system of your project. + +# This file is only used by the Ant script. + +# You can use this to override default values such as +# 'source.dir' for the location of your java source folder and +# 'out.dir' for the location of your output folder. + +# You can also use it define how the release builds are signed by declaring +# the following properties: +# 'key.store' for the location of your keystore and +# 'key.alias' for the name of the key to use. +# The password will be asked during the build when you use the 'release' target. + diff --git a/proj.android/build.xml b/proj.android/build.xml new file mode 100644 index 0000000..0b8262f --- /dev/null +++ b/proj.android/build.xml @@ -0,0 +1,83 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/proj.android/build_native.sh b/proj.android/build_native.sh new file mode 100755 index 0000000..a1a273f --- /dev/null +++ b/proj.android/build_native.sh @@ -0,0 +1,88 @@ +APPNAME="OzgGameRPG" + +# options + +buildexternalsfromsource= + +usage(){ +cat << EOF +usage: $0 [options] + +Build C/C++ code for $APPNAME using Android NDK + +OPTIONS: +-s Build externals from source +-h this help +EOF +} + +while getopts "sh" OPTION; do +case "$OPTION" in +s) +buildexternalsfromsource=1 +;; +h) +usage +exit 0 +;; +esac +done + +# paths + +if [ -z "${NDK_ROOT+aaa}" ];then +echo "please define NDK_ROOT" +exit 1 +fi + +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +# ... use paths relative to current directory +COCOS2DX_ROOT="$DIR/../../.." +APP_ROOT="$DIR/.." +APP_ANDROID_ROOT="$DIR" + +echo "NDK_ROOT = $NDK_ROOT" +echo "COCOS2DX_ROOT = $COCOS2DX_ROOT" +echo "APP_ROOT = $APP_ROOT" +echo "APP_ANDROID_ROOT = $APP_ANDROID_ROOT" + +# make sure assets is exist +if [ -d "$APP_ANDROID_ROOT"/assets ]; then + rm -rf "$APP_ANDROID_ROOT"/assets +fi + +mkdir "$APP_ANDROID_ROOT"/assets + +# copy resources +for file in "$APP_ROOT"/Resources/* +do +if [ -d "$file" ]; then + cp -rf "$file" "$APP_ANDROID_ROOT"/assets +fi + +if [ -f "$file" ]; then + cp "$file" "$APP_ANDROID_ROOT"/assets +fi +done + +# copy common luaScript +for file in "$APP_ROOT"/../../scripting/lua/script/* +do +if [ -d "$file" ]; then + cp -rf "$file" "$APP_ANDROID_ROOT"/assets +fi + +if [ -f "$file" ]; then + cp "$file" "$APP_ANDROID_ROOT"/assets +fi +done + +if [[ "$buildexternalsfromsource" ]]; then + echo "Building external dependencies from source" + "$NDK_ROOT"/ndk-build -C "$APP_ANDROID_ROOT" $* \ + "NDK_MODULE_PATH=${COCOS2DX_ROOT}:${COCOS2DX_ROOT}/cocos2dx/platform/third_party/android/source" +else + echo "Using prebuilt externals" + "$NDK_ROOT"/ndk-build -C "$APP_ANDROID_ROOT" $* \ + "NDK_MODULE_PATH=${COCOS2DX_ROOT}:${COCOS2DX_ROOT}/cocos2dx/platform/third_party/android/prebuilt" +fi \ No newline at end of file diff --git a/proj.android/jni/Android.mk b/proj.android/jni/Android.mk new file mode 100644 index 0000000..0fbb765 --- /dev/null +++ b/proj.android/jni/Android.mk @@ -0,0 +1,32 @@ +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_MODULE := cocos2dlua_shared + +LOCAL_MODULE_FILENAME := libcocos2dlua + +LOCAL_SRC_FILES := hellolua/main.cpp \ + ../../Classes/AppDelegate.cpp + + +LOCAL_C_INCLUDES := $(LOCAL_PATH)/../../Classes + +LOCAL_STATIC_LIBRARIES := curl_static_prebuilt + +LOCAL_WHOLE_STATIC_LIBRARIES := cocos2dx_static +LOCAL_WHOLE_STATIC_LIBRARIES += cocosdenshion_static +LOCAL_WHOLE_STATIC_LIBRARIES += cocos_lua_static +LOCAL_WHOLE_STATIC_LIBRARIES += box2d_static +LOCAL_WHOLE_STATIC_LIBRARIES += chipmunk_static +LOCAL_WHOLE_STATIC_LIBRARIES += cocos_extension_static + +include $(BUILD_SHARED_LIBRARY) + +$(call import-module,cocos2dx) +$(call import-module,CocosDenshion/android) +$(call import-module,scripting/lua/proj.android) +$(call import-module,cocos2dx/platform/third_party/android/prebuilt/libcurl) +$(call import-module,extensions) +$(call import-module,external/Box2D) +$(call import-module,external/chipmunk) \ No newline at end of file diff --git a/proj.android/jni/Application.mk b/proj.android/jni/Application.mk new file mode 100644 index 0000000..76e90c2 --- /dev/null +++ b/proj.android/jni/Application.mk @@ -0,0 +1,3 @@ +APP_STL := gnustl_static +APP_CPPFLAGS := -frtti -DCOCOS2D_DEBUG=1 -DCC_ENABLE_CHIPMUNK_INTEGRATION=1 +APP_CPPFLAGS += -fexceptions diff --git a/proj.android/jni/hellolua/main.cpp b/proj.android/jni/hellolua/main.cpp new file mode 100644 index 0000000..c340c4d --- /dev/null +++ b/proj.android/jni/hellolua/main.cpp @@ -0,0 +1,44 @@ +#include "AppDelegate.h" +#include "cocos2d.h" +#include "CCEventType.h" +#include "platform/android/jni/JniHelper.h" +#include +#include + +#define LOG_TAG "main" +#define LOGD(...) __android_log_print(ANDROID_LOG_DEBUG,LOG_TAG,__VA_ARGS__) + +using namespace cocos2d; + +extern "C" +{ + +jint JNI_OnLoad(JavaVM *vm, void *reserved) +{ + JniHelper::setJavaVM(vm); + + return JNI_VERSION_1_4; +} + +void Java_org_cocos2dx_lib_Cocos2dxRenderer_nativeInit(JNIEnv* env, jobject thiz, jint w, jint h) +{ + if (!CCDirector::sharedDirector()->getOpenGLView()) + { + CCEGLView *view = CCEGLView::sharedOpenGLView(); + view->setFrameSize(w, h); + + AppDelegate *pAppDelegate = new AppDelegate(); + CCApplication::sharedApplication()->run(); + } + else + { + ccGLInvalidateStateCache(); + CCShaderCache::sharedShaderCache()->reloadDefaultShaders(); + ccDrawInit(); + CCTextureCache::reloadAllTextures(); + CCNotificationCenter::sharedNotificationCenter()->postNotification(EVENT_COME_TO_FOREGROUND, NULL); + CCDirector::sharedDirector()->setGLDefaultValues(); + } +} + +} diff --git a/proj.android/proguard-project.txt b/proj.android/proguard-project.txt new file mode 100644 index 0000000..f2fe155 --- /dev/null +++ b/proj.android/proguard-project.txt @@ -0,0 +1,20 @@ +# To enable ProGuard in your project, edit project.properties +# to define the proguard.config property as described in that file. +# +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in ${sdk.dir}/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the ProGuard +# include property in project.properties. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} diff --git a/proj.android/project.properties b/proj.android/project.properties new file mode 100644 index 0000000..d5f90eb --- /dev/null +++ b/proj.android/project.properties @@ -0,0 +1,13 @@ +# This file is automatically generated by Android Tools. +# Do not modify this file -- YOUR CHANGES WILL BE ERASED! +# +# This file must be checked in Version Control Systems. +# +# To customize properties used by the Ant build system use, +# "ant.properties", and override values to adapt the script to your +# project structure. + +# Project target. +target=android-8 + +android.library.reference.1=../../../cocos2dx/platform/android/java diff --git a/proj.android/res/drawable-hdpi/icon.png b/proj.android/res/drawable-hdpi/icon.png new file mode 100644 index 0000000..8aa4767 Binary files /dev/null and b/proj.android/res/drawable-hdpi/icon.png differ diff --git a/proj.android/res/drawable-ldpi/icon.png b/proj.android/res/drawable-ldpi/icon.png new file mode 100644 index 0000000..17ce11a Binary files /dev/null and b/proj.android/res/drawable-ldpi/icon.png differ diff --git a/proj.android/res/drawable-mdpi/icon.png b/proj.android/res/drawable-mdpi/icon.png new file mode 100644 index 0000000..3780aac Binary files /dev/null and b/proj.android/res/drawable-mdpi/icon.png differ diff --git a/proj.android/res/values/strings.xml b/proj.android/res/values/strings.xml new file mode 100644 index 0000000..c13c933 --- /dev/null +++ b/proj.android/res/values/strings.xml @@ -0,0 +1,4 @@ + + + OzgGameRPG + diff --git a/proj.android/src/com/ozggame/rpg/OzgGameRPG.java b/proj.android/src/com/ozggame/rpg/OzgGameRPG.java new file mode 100644 index 0000000..4bfde96 --- /dev/null +++ b/proj.android/src/com/ozggame/rpg/OzgGameRPG.java @@ -0,0 +1,59 @@ +/**************************************************************************** +Copyright (c) 2010-2012 cocos2d-x.org + +http://www.cocos2d-x.org + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. +****************************************************************************/ +package com.ozggame.rpg; +import org.cocos2dx.lib.Cocos2dxActivity; +import org.cocos2dx.lib.Cocos2dxGLSurfaceView; + +import android.content.Context; +import android.os.Bundle; +import android.view.KeyEvent; + +public class OzgGameRPG extends Cocos2dxActivity{ + protected void onCreate(Bundle savedInstanceState){ + super.onCreate(savedInstanceState); + } + + public Cocos2dxGLSurfaceView onCreateGLSurfaceView() { + return new LuaGLSurfaceView(this); + } + + static { + System.loadLibrary("cocos2dlua"); + } +} + +class LuaGLSurfaceView extends Cocos2dxGLSurfaceView{ + + public LuaGLSurfaceView(Context context){ + super(context); + } + + public boolean onKeyDown(int keyCode, KeyEvent event) { + // exit program when key back is entered + if (keyCode == KeyEvent.KEYCODE_BACK) { + android.os.Process.killProcess(android.os.Process.myPid()); + } + return super.onKeyDown(keyCode, event); + } +} diff --git a/proj.blackberry/.cproject b/proj.blackberry/.cproject new file mode 100644 index 0000000..4faeafc --- /dev/null +++ b/proj.blackberry/.cproject @@ -0,0 +1,763 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/proj.blackberry/.project b/proj.blackberry/.project new file mode 100644 index 0000000..e42be07 --- /dev/null +++ b/proj.blackberry/.project @@ -0,0 +1,93 @@ + + + OzgGameRPG + + + cocos2dx + CocosDenshion + extensions + lua + + + + org.eclipse.cdt.managedbuilder.core.genmakebuilder + clean,full,incremental, + + + ?name? + + + + org.eclipse.cdt.make.core.append_environment + true + + + org.eclipse.cdt.make.core.buildArguments + + + + org.eclipse.cdt.make.core.buildCommand + make + + + org.eclipse.cdt.make.core.buildLocation + ${workspace_loc:/OzgGameRPG/Device-Debug} + + + org.eclipse.cdt.make.core.contents + org.eclipse.cdt.make.core.activeConfigSettings + + + org.eclipse.cdt.make.core.enableAutoBuild + false + + + org.eclipse.cdt.make.core.enableCleanBuild + true + + + org.eclipse.cdt.make.core.enableFullBuild + true + + + org.eclipse.cdt.make.core.stopOnError + true + + + org.eclipse.cdt.make.core.useDefaultBuildCmd + true + + + + + org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder + full,incremental, + + + + + com.qnx.tools.bbt.xml.core.bbtXMLValidationBuilder + + + + + + org.eclipse.cdt.core.cnature + org.eclipse.cdt.managedbuilder.core.managedBuildNature + org.eclipse.cdt.managedbuilder.core.ScannerConfigNature + com.qnx.tools.ide.bbt.core.bbtnature + org.eclipse.cdt.core.ccnature + + + + Classes + 2 + PARENT-1-PROJECT_LOC/Classes + + + Resources + 2 + PARENT-1-PROJECT_LOC/Resources + + + diff --git a/proj.blackberry/bar-descriptor.xml b/proj.blackberry/bar-descriptor.xml new file mode 100644 index 0000000..ce64ce7 --- /dev/null +++ b/proj.blackberry/bar-descriptor.xml @@ -0,0 +1,120 @@ + + + + + + + org.cocos2dx.OzgGameRPG + + + OzgGameRPG + + + 1.0.0 + + + 1 + + + + + + The OzgGameRPG application + + + + + + Example Inc. + + icon.png + + + + + + + none + false + + + + core.games + icon.png + + + Resources + Resources/script + + + + + + + + + + lib/libCocosDenshion.so + + + armle-v7 + OzgGameRPG + + + armle-v7 + OzgGameRPG + + + armle-v7 + OzgGameRPG + + + armle-v7 + OzgGameRPG + + + x86 + OzgGameRPG + + + x86 + OzgGameRPG + + + x86 + OzgGameRPG + + + + + + + + + run_native + + + + + + + + + + + + + + + + diff --git a/proj.blackberry/empty/.gitkeep b/proj.blackberry/empty/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/proj.blackberry/icon.png b/proj.blackberry/icon.png new file mode 100644 index 0000000..2e63367 Binary files /dev/null and b/proj.blackberry/icon.png differ diff --git a/proj.blackberry/main.cpp b/proj.blackberry/main.cpp new file mode 100644 index 0000000..1c2b01d --- /dev/null +++ b/proj.blackberry/main.cpp @@ -0,0 +1,32 @@ + +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" + + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + + int width, height; + const char *width_str, *height_str; + width_str = getenv("WIDTH"); + height_str = getenv("HEIGHT"); + if (width_str && height_str) + { + width = atoi(width_str); + height = atoi(height_str); + } + else + { + width = 1024; + height = 600; + } + + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(width, height); + + return CCApplication::sharedApplication()->run(); +} diff --git a/proj.ios/AppController.h b/proj.ios/AppController.h new file mode 100644 index 0000000..3d51064 --- /dev/null +++ b/proj.ios/AppController.h @@ -0,0 +1,33 @@ +/**************************************************************************** + Copyright (c) 2010 cocos2d-x.org + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +@class RootViewController; + +@interface AppController : NSObject { + UIWindow *window; + RootViewController *viewController; +} + +@end + diff --git a/proj.ios/AppController.mm b/proj.ios/AppController.mm new file mode 100644 index 0000000..2218aac --- /dev/null +++ b/proj.ios/AppController.mm @@ -0,0 +1,136 @@ +/**************************************************************************** + Copyright (c) 2010 cocos2d-x.org + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ +#import +#import "AppController.h" +#import "cocos2d.h" +#import "EAGLView.h" +#import "AppDelegate.h" + +#import "RootViewController.h" + +@implementation AppController + +#pragma mark - +#pragma mark Application lifecycle + +// cocos2d application instance +static AppDelegate s_sharedApplication; + +- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + + // Override point for customization after application launch. + + // Add the view controller's view to the window and display. + window = [[UIWindow alloc] initWithFrame: [[UIScreen mainScreen] bounds]]; + EAGLView *__glView = [EAGLView viewWithFrame: [window bounds] + pixelFormat: kEAGLColorFormatRGBA8 + depthFormat: GL_DEPTH_COMPONENT16 + preserveBackbuffer: NO + sharegroup: nil + multiSampling: NO + numberOfSamples: 0 ]; + + [__glView setMultipleTouchEnabled:YES]; + // Use RootViewController manage EAGLView + viewController = [[RootViewController alloc] initWithNibName:nil bundle:nil]; + viewController.wantsFullScreenLayout = YES; + viewController.view = __glView; + + // Set RootViewController to window + if ( [[UIDevice currentDevice].systemVersion floatValue] < 6.0) + { + // warning: addSubView doesn't work on iOS6 + [window addSubview: viewController.view]; + } + else + { + // use this method on ios6 + [window setRootViewController:viewController]; + } + + [window makeKeyAndVisible]; + + [[UIApplication sharedApplication] setStatusBarHidden: YES]; + + cocos2d::CCApplication::sharedApplication()->run(); + return YES; +} + + +- (void)applicationWillResignActive:(UIApplication *)application { + /* + Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. + */ + cocos2d::CCDirector::sharedDirector()->pause(); +} + +- (void)applicationDidBecomeActive:(UIApplication *)application { + /* + Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + */ + cocos2d::CCDirector::sharedDirector()->resume(); +} + +- (void)applicationDidEnterBackground:(UIApplication *)application { + /* + Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + If your application supports background execution, called instead of applicationWillTerminate: when the user quits. + */ + cocos2d::CCApplication::sharedApplication()->applicationDidEnterBackground(); +} + +- (void)applicationWillEnterForeground:(UIApplication *)application { + /* + Called as part of transition from the background to the inactive state: here you can undo many of the changes made on entering the background. + */ + cocos2d::CCApplication::sharedApplication()->applicationWillEnterForeground(); +} + +- (void)applicationWillTerminate:(UIApplication *)application { + /* + Called when the application is about to terminate. + See also applicationDidEnterBackground:. + */ +} + + +#pragma mark - +#pragma mark Memory management + +- (void)applicationDidReceiveMemoryWarning:(UIApplication *)application { + /* + Free up as much memory as possible by purging cached data objects that can be recreated (or reloaded from disk) later. + */ + cocos2d::CCDirector::sharedDirector()->purgeCachedData(); +} + + +- (void)dealloc { + [super dealloc]; +} + + +@end + diff --git a/proj.ios/Default-568h@2x.png b/proj.ios/Default-568h@2x.png new file mode 100644 index 0000000..66c6d1c Binary files /dev/null and b/proj.ios/Default-568h@2x.png differ diff --git a/proj.ios/Default.png b/proj.ios/Default.png new file mode 100644 index 0000000..dcb8072 Binary files /dev/null and b/proj.ios/Default.png differ diff --git a/proj.ios/Default@2x.png b/proj.ios/Default@2x.png new file mode 100644 index 0000000..8468988 Binary files /dev/null and b/proj.ios/Default@2x.png differ diff --git a/proj.ios/Icon-114.png b/proj.ios/Icon-114.png new file mode 100644 index 0000000..c380786 Binary files /dev/null and b/proj.ios/Icon-114.png differ diff --git a/proj.ios/Icon-120.png b/proj.ios/Icon-120.png new file mode 100644 index 0000000..a5b49cc Binary files /dev/null and b/proj.ios/Icon-120.png differ diff --git a/proj.ios/Icon-144.png b/proj.ios/Icon-144.png new file mode 100644 index 0000000..1526615 Binary files /dev/null and b/proj.ios/Icon-144.png differ diff --git a/proj.ios/Icon-152.png b/proj.ios/Icon-152.png new file mode 100644 index 0000000..8aa8250 Binary files /dev/null and b/proj.ios/Icon-152.png differ diff --git a/proj.ios/Icon-57.png b/proj.ios/Icon-57.png new file mode 100644 index 0000000..4fcc6fd Binary files /dev/null and b/proj.ios/Icon-57.png differ diff --git a/proj.ios/Icon-72.png b/proj.ios/Icon-72.png new file mode 100644 index 0000000..2c573c8 Binary files /dev/null and b/proj.ios/Icon-72.png differ diff --git a/proj.ios/Icon-76.png b/proj.ios/Icon-76.png new file mode 100644 index 0000000..8a1fa18 Binary files /dev/null and b/proj.ios/Icon-76.png differ diff --git a/proj.ios/Info.plist b/proj.ios/Info.plist new file mode 100644 index 0000000..9a45dce --- /dev/null +++ b/proj.ios/Info.plist @@ -0,0 +1,62 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleDisplayName + ${PRODUCT_NAME} + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIconFile + + CFBundleIconFiles + + Icon-57.png + Icon-114.png + Icon-72.png + Icon-144.png + Icon-76.png + Icon-120.png + Icon-152.png + + CFBundleIdentifier + com.ozggame.rpg + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + LSHasLocalizedDisplayName + + LSRequiresIPhoneOS + + UIAppFonts + + 方正粗圆简体.ttf + + UIPrerenderedIcon + + UIRequiredDeviceCapabilities + + accelerometer + + opengles-1 + + + UIStatusBarHidden + + UISupportedInterfaceOrientations + + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/project.pbxproj b/proj.ios/OzgGameRPG.xcodeproj/project.pbxproj new file mode 100644 index 0000000..5a8e77e --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/project.pbxproj @@ -0,0 +1,3053 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 150CD3951872B593007F1964 /* UITouchGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 150CD3931872B593007F1964 /* UITouchGroup.cpp */; }; + 150E36FF17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 150E36FD17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.cpp */; }; + 1514E39018784113003FC4EE /* CCActionEaseEx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1514E38F18784113003FC4EE /* CCActionEaseEx.cpp */; }; + 1583F16718D09FF900F3D630 /* UIListView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1583F15E18D09FF900F3D630 /* UIListView.cpp */; }; + 1583F16818D09FF900F3D630 /* UIPageView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1583F16018D09FF900F3D630 /* UIPageView.cpp */; }; + 1583F16918D09FF900F3D630 /* UIScrollView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1583F16318D09FF900F3D630 /* UIScrollView.cpp */; }; + 1583F16A18D09FF900F3D630 /* UIRichText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1583F16518D09FF900F3D630 /* UIRichText.cpp */; }; + 15C153F71683112E00D239F2 /* CCBAnimationManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1537C1683112E00D239F2 /* CCBAnimationManager.cpp */; }; + 15C153F81683112E00D239F2 /* CCBFileLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1537E1683112E00D239F2 /* CCBFileLoader.cpp */; }; + 15C153F91683112E00D239F2 /* CCBKeyframe.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153801683112E00D239F2 /* CCBKeyframe.cpp */; }; + 15C153FA1683112E00D239F2 /* CCBReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153831683112E00D239F2 /* CCBReader.cpp */; }; + 15C153FB1683112E00D239F2 /* CCBSequence.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153861683112E00D239F2 /* CCBSequence.cpp */; }; + 15C153FC1683112E00D239F2 /* CCBSequenceProperty.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153881683112E00D239F2 /* CCBSequenceProperty.cpp */; }; + 15C153FD1683112E00D239F2 /* CCBValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1538A1683112E00D239F2 /* CCBValue.cpp */; }; + 15C153FE1683112E00D239F2 /* CCControlButtonLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1538C1683112E00D239F2 /* CCControlButtonLoader.cpp */; }; + 15C153FF1683112E00D239F2 /* CCControlLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1538E1683112E00D239F2 /* CCControlLoader.cpp */; }; + 15C154001683112E00D239F2 /* CCData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153901683112E00D239F2 /* CCData.cpp */; }; + 15C154011683112E00D239F2 /* CCLabelBMFontLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153921683112E00D239F2 /* CCLabelBMFontLoader.cpp */; }; + 15C154021683112E00D239F2 /* CCLabelTTFLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153941683112E00D239F2 /* CCLabelTTFLoader.cpp */; }; + 15C154031683112E00D239F2 /* CCLayerColorLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153961683112E00D239F2 /* CCLayerColorLoader.cpp */; }; + 15C154041683112E00D239F2 /* CCLayerGradientLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153981683112E00D239F2 /* CCLayerGradientLoader.cpp */; }; + 15C154051683112E00D239F2 /* CCLayerLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1539A1683112E00D239F2 /* CCLayerLoader.cpp */; }; + 15C154061683112E00D239F2 /* CCMenuItemImageLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1539C1683112E00D239F2 /* CCMenuItemImageLoader.cpp */; }; + 15C154071683112E00D239F2 /* CCMenuItemLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1539E1683112E00D239F2 /* CCMenuItemLoader.cpp */; }; + 15C154081683112E00D239F2 /* CCNode+CCBRelativePositioning.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153A11683112E00D239F2 /* CCNode+CCBRelativePositioning.cpp */; }; + 15C154091683112E00D239F2 /* CCNodeLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153A31683112E00D239F2 /* CCNodeLoader.cpp */; }; + 15C1540A1683112E00D239F2 /* CCNodeLoaderLibrary.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153A51683112E00D239F2 /* CCNodeLoaderLibrary.cpp */; }; + 15C1540B1683112E00D239F2 /* CCParticleSystemQuadLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153A81683112E00D239F2 /* CCParticleSystemQuadLoader.cpp */; }; + 15C1540C1683112E00D239F2 /* CCScale9SpriteLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153AA1683112E00D239F2 /* CCScale9SpriteLoader.cpp */; }; + 15C1540D1683112E00D239F2 /* CCScrollViewLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153AC1683112E00D239F2 /* CCScrollViewLoader.cpp */; }; + 15C1540E1683112E00D239F2 /* CCSpriteLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153AE1683112E00D239F2 /* CCSpriteLoader.cpp */; }; + 15C1540F1683112E00D239F2 /* CCControl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153B41683112E00D239F2 /* CCControl.cpp */; }; + 15C154101683112E00D239F2 /* CCControlButton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153B61683112E00D239F2 /* CCControlButton.cpp */; }; + 15C154111683112E00D239F2 /* CCControlColourPicker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153B81683112E00D239F2 /* CCControlColourPicker.cpp */; }; + 15C154121683112E00D239F2 /* CCControlHuePicker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153BB1683112E00D239F2 /* CCControlHuePicker.cpp */; }; + 15C154131683112E00D239F2 /* CCControlPotentiometer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153BD1683112E00D239F2 /* CCControlPotentiometer.cpp */; }; + 15C154141683112E00D239F2 /* CCControlSaturationBrightnessPicker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153BF1683112E00D239F2 /* CCControlSaturationBrightnessPicker.cpp */; }; + 15C154151683112E00D239F2 /* CCControlSlider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153C11683112E00D239F2 /* CCControlSlider.cpp */; }; + 15C154161683112E00D239F2 /* CCControlStepper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153C31683112E00D239F2 /* CCControlStepper.cpp */; }; + 15C154171683112E00D239F2 /* CCControlSwitch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153C51683112E00D239F2 /* CCControlSwitch.cpp */; }; + 15C154181683112E00D239F2 /* CCControlUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153C71683112E00D239F2 /* CCControlUtils.cpp */; }; + 15C154191683112E00D239F2 /* CCInvocation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153C91683112E00D239F2 /* CCInvocation.cpp */; }; + 15C1541A1683112E00D239F2 /* CCScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153CB1683112E00D239F2 /* CCScale9Sprite.cpp */; }; + 15C1541B1683112E00D239F2 /* CCEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153CE1683112E00D239F2 /* CCEditBox.cpp */; }; + 15C1541D1683112E00D239F2 /* CCEditBoxImplIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 15C153D41683112E00D239F2 /* CCEditBoxImplIOS.mm */; }; + 15C1541F1683112E00D239F2 /* CCScrollView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153D81683112E00D239F2 /* CCScrollView.cpp */; }; + 15C154201683112E00D239F2 /* CCSorting.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153DA1683112E00D239F2 /* CCSorting.cpp */; }; + 15C154211683112E00D239F2 /* CCTableView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153DC1683112E00D239F2 /* CCTableView.cpp */; }; + 15C154221683112E00D239F2 /* CCTableViewCell.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153DE1683112E00D239F2 /* CCTableViewCell.cpp */; }; + 15C154231683112E00D239F2 /* HttpClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153E11683112E00D239F2 /* HttpClient.cpp */; }; + 15C154241683112E00D239F2 /* CCPhysicsDebugNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153E61683112E00D239F2 /* CCPhysicsDebugNode.cpp */; }; + 15C154251683112E00D239F2 /* CCPhysicsSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C153E81683112E00D239F2 /* CCPhysicsSprite.cpp */; }; + 15C154891683116B00D239F2 /* chipmunk.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1545C1683116B00D239F2 /* chipmunk.c */; }; + 15C1548B1683116B00D239F2 /* cpConstraint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1545F1683116B00D239F2 /* cpConstraint.c */; }; + 15C1548C1683116B00D239F2 /* cpDampedRotarySpring.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154601683116B00D239F2 /* cpDampedRotarySpring.c */; }; + 15C1548D1683116B00D239F2 /* cpDampedSpring.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154611683116B00D239F2 /* cpDampedSpring.c */; }; + 15C1548E1683116B00D239F2 /* cpGearJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154621683116B00D239F2 /* cpGearJoint.c */; }; + 15C1548F1683116B00D239F2 /* cpGrooveJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154631683116B00D239F2 /* cpGrooveJoint.c */; }; + 15C154901683116B00D239F2 /* cpPinJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154641683116B00D239F2 /* cpPinJoint.c */; }; + 15C154911683116B00D239F2 /* cpPivotJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154651683116B00D239F2 /* cpPivotJoint.c */; }; + 15C154921683116B00D239F2 /* cpRatchetJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154661683116B00D239F2 /* cpRatchetJoint.c */; }; + 15C154931683116B00D239F2 /* cpRotaryLimitJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154671683116B00D239F2 /* cpRotaryLimitJoint.c */; }; + 15C154941683116B00D239F2 /* cpSimpleMotor.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154681683116B00D239F2 /* cpSimpleMotor.c */; }; + 15C154951683116B00D239F2 /* cpSlideJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154691683116B00D239F2 /* cpSlideJoint.c */; }; + 15C154961683116B00D239F2 /* cpArbiter.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546A1683116B00D239F2 /* cpArbiter.c */; }; + 15C154971683116B00D239F2 /* cpArray.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546B1683116B00D239F2 /* cpArray.c */; }; + 15C154981683116B00D239F2 /* cpBB.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546C1683116B00D239F2 /* cpBB.c */; }; + 15C154991683116B00D239F2 /* cpBBTree.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546D1683116B00D239F2 /* cpBBTree.c */; }; + 15C1549A1683116B00D239F2 /* cpBody.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546E1683116B00D239F2 /* cpBody.c */; }; + 15C1549B1683116B00D239F2 /* cpCollision.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1546F1683116B00D239F2 /* cpCollision.c */; }; + 15C1549C1683116B00D239F2 /* cpHashSet.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154701683116B00D239F2 /* cpHashSet.c */; }; + 15C1549D1683116B00D239F2 /* cpPolyShape.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154711683116B00D239F2 /* cpPolyShape.c */; }; + 15C1549E1683116B00D239F2 /* cpShape.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154721683116B00D239F2 /* cpShape.c */; }; + 15C1549F1683116B00D239F2 /* cpSpace.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154731683116B00D239F2 /* cpSpace.c */; }; + 15C154A01683116B00D239F2 /* cpSpaceComponent.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154741683116B00D239F2 /* cpSpaceComponent.c */; }; + 15C154A11683116B00D239F2 /* cpSpaceHash.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154751683116B00D239F2 /* cpSpaceHash.c */; }; + 15C154A21683116B00D239F2 /* cpSpaceQuery.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154761683116B00D239F2 /* cpSpaceQuery.c */; }; + 15C154A31683116B00D239F2 /* cpSpaceStep.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154771683116B00D239F2 /* cpSpaceStep.c */; }; + 15C154A41683116B00D239F2 /* cpSpatialIndex.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154781683116B00D239F2 /* cpSpatialIndex.c */; }; + 15C154A51683116B00D239F2 /* cpSweep1D.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C154791683116B00D239F2 /* cpSweep1D.c */; }; + 15C154A61683116B00D239F2 /* cpVect.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C1547A1683116B00D239F2 /* cpVect.c */; }; + 15C1551F1683118600D239F2 /* b2BroadPhase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154AB1683118600D239F2 /* b2BroadPhase.cpp */; }; + 15C155201683118600D239F2 /* b2CollideCircle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154AD1683118600D239F2 /* b2CollideCircle.cpp */; }; + 15C155211683118600D239F2 /* b2CollideEdge.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154AE1683118600D239F2 /* b2CollideEdge.cpp */; }; + 15C155221683118600D239F2 /* b2CollidePolygon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154AF1683118600D239F2 /* b2CollidePolygon.cpp */; }; + 15C155231683118600D239F2 /* b2Collision.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154B01683118600D239F2 /* b2Collision.cpp */; }; + 15C155241683118600D239F2 /* b2Distance.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154B21683118600D239F2 /* b2Distance.cpp */; }; + 15C155251683118600D239F2 /* b2DynamicTree.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154B41683118600D239F2 /* b2DynamicTree.cpp */; }; + 15C155261683118600D239F2 /* b2TimeOfImpact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154B61683118600D239F2 /* b2TimeOfImpact.cpp */; }; + 15C155271683118600D239F2 /* b2ChainShape.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154B91683118600D239F2 /* b2ChainShape.cpp */; }; + 15C155281683118600D239F2 /* b2CircleShape.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154BB1683118600D239F2 /* b2CircleShape.cpp */; }; + 15C155291683118600D239F2 /* b2EdgeShape.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154BD1683118600D239F2 /* b2EdgeShape.cpp */; }; + 15C1552A1683118600D239F2 /* b2PolygonShape.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154BF1683118600D239F2 /* b2PolygonShape.cpp */; }; + 15C1552B1683118600D239F2 /* b2BlockAllocator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154C31683118600D239F2 /* b2BlockAllocator.cpp */; }; + 15C1552C1683118600D239F2 /* b2Draw.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154C51683118600D239F2 /* b2Draw.cpp */; }; + 15C1552D1683118600D239F2 /* b2Math.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154C81683118600D239F2 /* b2Math.cpp */; }; + 15C1552E1683118600D239F2 /* b2Settings.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154CA1683118600D239F2 /* b2Settings.cpp */; }; + 15C1552F1683118600D239F2 /* b2StackAllocator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154CC1683118600D239F2 /* b2StackAllocator.cpp */; }; + 15C155301683118600D239F2 /* b2Timer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154CE1683118600D239F2 /* b2Timer.cpp */; }; + 15C155311683118600D239F2 /* b2Body.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154D11683118600D239F2 /* b2Body.cpp */; }; + 15C155321683118600D239F2 /* b2ContactManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154D31683118600D239F2 /* b2ContactManager.cpp */; }; + 15C155331683118600D239F2 /* b2Fixture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154D51683118600D239F2 /* b2Fixture.cpp */; }; + 15C155341683118600D239F2 /* b2Island.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154D71683118600D239F2 /* b2Island.cpp */; }; + 15C155351683118600D239F2 /* b2World.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154DA1683118600D239F2 /* b2World.cpp */; }; + 15C155361683118600D239F2 /* b2WorldCallbacks.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154DC1683118600D239F2 /* b2WorldCallbacks.cpp */; }; + 15C155371683118600D239F2 /* b2ChainAndCircleContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154DF1683118600D239F2 /* b2ChainAndCircleContact.cpp */; }; + 15C155381683118600D239F2 /* b2ChainAndPolygonContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154E11683118600D239F2 /* b2ChainAndPolygonContact.cpp */; }; + 15C155391683118600D239F2 /* b2CircleContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154E31683118600D239F2 /* b2CircleContact.cpp */; }; + 15C1553A1683118600D239F2 /* b2Contact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154E51683118600D239F2 /* b2Contact.cpp */; }; + 15C1553B1683118600D239F2 /* b2ContactSolver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154E71683118600D239F2 /* b2ContactSolver.cpp */; }; + 15C1553C1683118600D239F2 /* b2EdgeAndCircleContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154E91683118600D239F2 /* b2EdgeAndCircleContact.cpp */; }; + 15C1553D1683118600D239F2 /* b2EdgeAndPolygonContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154EB1683118600D239F2 /* b2EdgeAndPolygonContact.cpp */; }; + 15C1553E1683118600D239F2 /* b2PolygonAndCircleContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154ED1683118600D239F2 /* b2PolygonAndCircleContact.cpp */; }; + 15C1553F1683118600D239F2 /* b2PolygonContact.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154EF1683118600D239F2 /* b2PolygonContact.cpp */; }; + 15C155401683118600D239F2 /* b2DistanceJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154F21683118600D239F2 /* b2DistanceJoint.cpp */; }; + 15C155411683118600D239F2 /* b2FrictionJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154F41683118600D239F2 /* b2FrictionJoint.cpp */; }; + 15C155421683118600D239F2 /* b2GearJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154F61683118600D239F2 /* b2GearJoint.cpp */; }; + 15C155431683118600D239F2 /* b2Joint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154F81683118600D239F2 /* b2Joint.cpp */; }; + 15C155441683118600D239F2 /* b2MouseJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154FA1683118600D239F2 /* b2MouseJoint.cpp */; }; + 15C155451683118600D239F2 /* b2PrismaticJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154FC1683118600D239F2 /* b2PrismaticJoint.cpp */; }; + 15C155461683118600D239F2 /* b2PulleyJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C154FE1683118600D239F2 /* b2PulleyJoint.cpp */; }; + 15C155471683118600D239F2 /* b2RevoluteJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C155001683118600D239F2 /* b2RevoluteJoint.cpp */; }; + 15C155481683118600D239F2 /* b2RopeJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C155021683118600D239F2 /* b2RopeJoint.cpp */; }; + 15C155491683118600D239F2 /* b2WeldJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C155041683118600D239F2 /* b2WeldJoint.cpp */; }; + 15C1554A1683118600D239F2 /* b2WheelJoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C155061683118600D239F2 /* b2WheelJoint.cpp */; }; + 15C155591683118600D239F2 /* b2Rope.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15C1551C1683118600D239F2 /* b2Rope.cpp */; }; + 15C155DA168311AA00D239F2 /* CDAudioManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 15C15575168311AA00D239F2 /* CDAudioManager.m */; }; + 15C155DB168311AA00D239F2 /* CDOpenALSupport.m in Sources */ = {isa = PBXBuildFile; fileRef = 15C15578168311AA00D239F2 /* CDOpenALSupport.m */; }; + 15C155DC168311AA00D239F2 /* CocosDenshion.m in Sources */ = {isa = PBXBuildFile; fileRef = 15C1557A168311AA00D239F2 /* CocosDenshion.m */; }; + 15C155DD168311AA00D239F2 /* SimpleAudioEngine.mm in Sources */ = {isa = PBXBuildFile; fileRef = 15C1557B168311AA00D239F2 /* SimpleAudioEngine.mm */; }; + 15C155DE168311AA00D239F2 /* SimpleAudioEngine_objc.m in Sources */ = {isa = PBXBuildFile; fileRef = 15C1557D168311AA00D239F2 /* SimpleAudioEngine_objc.m */; }; + 15C15685168311CB00D239F2 /* tolua_event.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C15652168311CB00D239F2 /* tolua_event.c */; }; + 15C15686168311CB00D239F2 /* tolua_is.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C15654168311CB00D239F2 /* tolua_is.c */; }; + 15C15687168311CB00D239F2 /* tolua_map.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C15655168311CB00D239F2 /* tolua_map.c */; }; + 15C15688168311CB00D239F2 /* tolua_push.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C15656168311CB00D239F2 /* tolua_push.c */; }; + 15C15689168311CB00D239F2 /* tolua_to.c in Sources */ = {isa = PBXBuildFile; fileRef = 15C15657168311CB00D239F2 /* tolua_to.c */; }; + 15C1568C168311EC00D239F2 /* libcocos2dx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 15C15346168310C700D239F2 /* libcocos2dx.a */; }; + 15C1568E1683131500D239F2 /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 15C1568D1683131500D239F2 /* libcurl.a */; }; + 15C156981683138E00D239F2 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156911683138E00D239F2 /* Default-568h@2x.png */; }; + 15C156991683138E00D239F2 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156921683138E00D239F2 /* Default.png */; }; + 15C1569A1683138E00D239F2 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156931683138E00D239F2 /* Default@2x.png */; }; + 15C1569B1683138E00D239F2 /* Icon-57.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156941683138E00D239F2 /* Icon-57.png */; }; + 15C1569C1683138E00D239F2 /* Icon-72.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156951683138E00D239F2 /* Icon-72.png */; }; + 15C1569D1683138E00D239F2 /* Icon-114.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156961683138E00D239F2 /* Icon-114.png */; }; + 15C1569E1683138E00D239F2 /* Icon-144.png in Resources */ = {isa = PBXBuildFile; fileRef = 15C156971683138E00D239F2 /* Icon-144.png */; }; + 15CA8CF518696744000032AB /* lua_cocos2dx_cocostudio_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15CA8CEF18696743000032AB /* lua_cocos2dx_cocostudio_manual.cpp */; }; + 15CA8CF618696744000032AB /* lua_cocos2dx_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15CA8CF118696743000032AB /* lua_cocos2dx_manual.cpp */; }; + 15CA8CF718696744000032AB /* LuaCocoStudio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15CA8CF318696743000032AB /* LuaCocoStudio.cpp */; }; + 1A40E7DF1727C47E006D4861 /* Animation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7B81727C47D006D4861 /* Animation.cpp */; }; + 1A40E7E01727C47E006D4861 /* AnimationState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7BA1727C47D006D4861 /* AnimationState.cpp */; }; + 1A40E7E11727C47E006D4861 /* AnimationStateData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7BC1727C47D006D4861 /* AnimationStateData.cpp */; }; + 1A40E7E21727C47E006D4861 /* Atlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7BE1727C47D006D4861 /* Atlas.cpp */; }; + 1A40E7E31727C47E006D4861 /* AtlasAttachmentLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7C01727C47D006D4861 /* AtlasAttachmentLoader.cpp */; }; + 1A40E7E41727C47E006D4861 /* Attachment.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7C21727C47D006D4861 /* Attachment.cpp */; }; + 1A40E7E51727C47E006D4861 /* AttachmentLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7C41727C47D006D4861 /* AttachmentLoader.cpp */; }; + 1A40E7E61727C47E006D4861 /* Bone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7C61727C47D006D4861 /* Bone.cpp */; }; + 1A40E7E71727C47E006D4861 /* BoneData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7C81727C47D006D4861 /* BoneData.cpp */; }; + 1A40E7E81727C47E006D4861 /* extension.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7CA1727C47E006D4861 /* extension.cpp */; }; + 1A40E7E91727C47E006D4861 /* Json.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7CC1727C47E006D4861 /* Json.cpp */; }; + 1A40E7EA1727C47E006D4861 /* RegionAttachment.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7CE1727C47E006D4861 /* RegionAttachment.cpp */; }; + 1A40E7EB1727C47E006D4861 /* Skeleton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7D01727C47E006D4861 /* Skeleton.cpp */; }; + 1A40E7EC1727C47E006D4861 /* SkeletonData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7D21727C47E006D4861 /* SkeletonData.cpp */; }; + 1A40E7ED1727C47E006D4861 /* SkeletonJson.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7D41727C47E006D4861 /* SkeletonJson.cpp */; }; + 1A40E7EE1727C47E006D4861 /* Skin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7D61727C47E006D4861 /* Skin.cpp */; }; + 1A40E7EF1727C47E006D4861 /* Slot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7D81727C47E006D4861 /* Slot.cpp */; }; + 1A40E7F01727C47E006D4861 /* SlotData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7DA1727C47E006D4861 /* SlotData.cpp */; }; + 1A40E7F11727C47E006D4861 /* spine-cocos2dx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A40E7DC1727C47E006D4861 /* spine-cocos2dx.cpp */; }; + 1A9CE91D1765A2C2000E3062 /* CCBProxy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9CE9171765A2C2000E3062 /* CCBProxy.cpp */; }; + 1A9CE91E1765A2C2000E3062 /* Lua_extensions_CCB.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9CE9191765A2C2000E3062 /* Lua_extensions_CCB.cpp */; }; + 1A9CE91F1765A2C2000E3062 /* Lua_web_socket.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A9CE91B1765A2C2000E3062 /* Lua_web_socket.cpp */; }; + 1A9D7E63171E38B2000B3B9A /* libluajit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9D7E62171E38B2000B3B9A /* libluajit.a */; }; + 1AB87024175E0A2D005D39BF /* WebSocket.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AB87022175E0A2D005D39BF /* WebSocket.cpp */; }; + 1AB87029175E0A40005D39BF /* CCSkeleton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AB87025175E0A40005D39BF /* CCSkeleton.cpp */; }; + 1AB8702A175E0A40005D39BF /* CCSkeletonAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AB87027175E0A40005D39BF /* CCSkeletonAnimation.cpp */; }; + 1AB87031175E0A5B005D39BF /* libwebsockets.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1AB87030175E0A5B005D39BF /* libwebsockets.a */; }; + 1AC3623516D47C5C000847F2 /* fonts in Resources */ = {isa = PBXBuildFile; fileRef = 1AC3622916D47C5C000847F2 /* fonts */; }; + 298B2A2E18D0671400C1920F /* ButtonReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A0518D0671400C1920F /* ButtonReader.cpp */; }; + 298B2A2F18D0671400C1920F /* CheckBoxReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A0818D0671400C1920F /* CheckBoxReader.cpp */; }; + 298B2A3018D0671400C1920F /* ImageViewReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A0B18D0671400C1920F /* ImageViewReader.cpp */; }; + 298B2A3118D0671400C1920F /* LabelAtlasReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A0E18D0671400C1920F /* LabelAtlasReader.cpp */; }; + 298B2A3218D0671400C1920F /* LabelBMFontReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A1118D0671400C1920F /* LabelBMFontReader.cpp */; }; + 298B2A3318D0671400C1920F /* LabelReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A1418D0671400C1920F /* LabelReader.cpp */; }; + 298B2A3418D0671400C1920F /* LayoutReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A1718D0671400C1920F /* LayoutReader.cpp */; }; + 298B2A3518D0671400C1920F /* ListViewReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A1A18D0671400C1920F /* ListViewReader.cpp */; }; + 298B2A3618D0671400C1920F /* LoadingBarReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A1D18D0671400C1920F /* LoadingBarReader.cpp */; }; + 298B2A3718D0671400C1920F /* PageViewReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A2018D0671400C1920F /* PageViewReader.cpp */; }; + 298B2A3818D0671400C1920F /* ScrollViewReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A2318D0671400C1920F /* ScrollViewReader.cpp */; }; + 298B2A3918D0671400C1920F /* SliderReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A2618D0671400C1920F /* SliderReader.cpp */; }; + 298B2A3A18D0671400C1920F /* TextFieldReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A2918D0671400C1920F /* TextFieldReader.cpp */; }; + 298B2A3B18D0671400C1920F /* WidgetReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298B2A2B18D0671400C1920F /* WidgetReader.cpp */; }; + 373F993E1869F07A0080E035 /* CCActionFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 373F99331869F07A0080E035 /* CCActionFrame.cpp */; }; + 373F993F1869F07A0080E035 /* CCActionFrameEasing.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 373F99351869F07A0080E035 /* CCActionFrameEasing.cpp */; }; + 373F99401869F07A0080E035 /* CCActionManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 373F99371869F07A0080E035 /* CCActionManager.cpp */; }; + 373F99411869F07A0080E035 /* CCActionNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 373F99391869F07A0080E035 /* CCActionNode.cpp */; }; + 373F99421869F07A0080E035 /* CCActionObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 373F993B1869F07A0080E035 /* CCActionObject.cpp */; }; + 375BD55F186846090024609E /* ObjectFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 375BD557186846090024609E /* ObjectFactory.cpp */; }; + 375BD560186846090024609E /* TriggerBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 375BD559186846090024609E /* TriggerBase.cpp */; }; + 375BD561186846090024609E /* TriggerMng.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 375BD55B186846090024609E /* TriggerMng.cpp */; }; + 375BD562186846090024609E /* TriggerObj.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 375BD55D186846090024609E /* TriggerObj.cpp */; }; + 46C1008C16BF786A00F74D54 /* CCLuaBridge.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1007A16BF786A00F74D54 /* CCLuaBridge.cpp */; }; + 46C1008D16BF786A00F74D54 /* CCLuaEngine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1007C16BF786A00F74D54 /* CCLuaEngine.cpp */; }; + 46C1008E16BF786A00F74D54 /* CCLuaStack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1007E16BF786A00F74D54 /* CCLuaStack.cpp */; }; + 46C1008F16BF786A00F74D54 /* CCLuaValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1008016BF786A00F74D54 /* CCLuaValue.cpp */; }; + 46C1009016BF786A00F74D54 /* Cocos2dxLuaLoader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1008216BF786A00F74D54 /* Cocos2dxLuaLoader.cpp */; }; + 46C1009116BF786A00F74D54 /* LuaCocos2d.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46C1008416BF786A00F74D54 /* LuaCocos2d.cpp */; }; + 46C1009216BF786A00F74D54 /* CCLuaObjcBridge.mm in Sources */ = {isa = PBXBuildFile; fileRef = 46C1008916BF786A00F74D54 /* CCLuaObjcBridge.mm */; }; + 46C1009316BF786A00F74D54 /* tolua_fix.c in Sources */ = {isa = PBXBuildFile; fileRef = 46C1008A16BF786A00F74D54 /* tolua_fix.c */; }; + 46C59AD317641FF300F43DC3 /* AudioEngine.lua in Resources */ = {isa = PBXBuildFile; fileRef = 46C59AD117641FF300F43DC3 /* AudioEngine.lua */; }; + 46C59AD417641FF300F43DC3 /* CCBReaderLoad.lua in Resources */ = {isa = PBXBuildFile; fileRef = 46C59AD217641FF300F43DC3 /* CCBReaderLoad.lua */; }; + 8909857018F253DE0021AE26 /* battle_msg_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 8909856F18F253DE0021AE26 /* battle_msg_style1.tmx */; }; + 895EC07318F05AE600C3814D /* RPGData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 895EC07118F05AE600C3814D /* RPGData.cpp */; }; + 8960C17F18E7D0BD0075EF99 /* alert_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 8960C17E18E7D0BD0075EF99 /* alert_style1.tmx */; }; + 8960C18218E7D51C0075EF99 /* RPGConfirmLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8960C18018E7D51C0075EF99 /* RPGConfirmLayer.cpp */; }; + 896BAEE618EF04CF006581FD /* audio_battle_end.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 896BAEE318EF04CF006581FD /* audio_battle_end.mp3 */; }; + 896BAEE718EF04CF006581FD /* audio_battle_menu.wav in Resources */ = {isa = PBXBuildFile; fileRef = 896BAEE418EF04CF006581FD /* audio_battle_menu.wav */; }; + 896BAEE818EF04CF006581FD /* audio_battle_start.wav in Resources */ = {isa = PBXBuildFile; fileRef = 896BAEE518EF04CF006581FD /* audio_battle_start.wav */; }; + 8999051A18F17A3D00012A0E /* RPGBattleMenu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8999051818F17A3D00012A0E /* RPGBattleMenu.cpp */; }; + 8999051D18F17E6C00012A0E /* battle_battlemenu_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 8999051C18F17E6C00012A0E /* battle_battlemenu_style1.tmx */; }; + 89CB7D7F18E9A47800A5921B /* map_menu1_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89CB7D7C18E9A47800A5921B /* map_menu1_style1.tmx */; }; + 89CB7D8018E9A47800A5921B /* map_menu2_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89CB7D7D18E9A47800A5921B /* map_menu2_style1.tmx */; }; + 89CB7D8118E9A47800A5921B /* map_menu3_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89CB7D7E18E9A47800A5921B /* map_menu3_style1.tmx */; }; + 89CB7D8818E9A87700A5921B /* dialog_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89CB7D8718E9A87700A5921B /* dialog_style1.tmx */; }; + 89CB7D8B18E9A8BF00A5921B /* RPGMapDialogLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89CB7D8918E9A8BF00A5921B /* RPGMapDialogLayer.cpp */; }; + 89E63C7518ED83C900BDD04F /* actor5_0.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C6B18ED83C900BDD04F /* actor5_0.png */; }; + 89E63C7618ED83C900BDD04F /* actor5_1.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C6C18ED83C900BDD04F /* actor5_1.png */; }; + 89E63C7718ED83C900BDD04F /* actor5_2.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C6D18ED83C900BDD04F /* actor5_2.png */; }; + 89E63C7818ED83C900BDD04F /* actor5_3.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C6E18ED83C900BDD04F /* actor5_3.png */; }; + 89E63C7918ED83C900BDD04F /* actor5_4.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C6F18ED83C900BDD04F /* actor5_4.png */; }; + 89E63C7A18ED83C900BDD04F /* actor8_0.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C7018ED83C900BDD04F /* actor8_0.png */; }; + 89E63C7B18ED83C900BDD04F /* actor8_1.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C7118ED83C900BDD04F /* actor8_1.png */; }; + 89E63C7C18ED83C900BDD04F /* actor8_2.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C7218ED83C900BDD04F /* actor8_2.png */; }; + 89E63C7D18ED83C900BDD04F /* actor8_3.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C7318ED83C900BDD04F /* actor8_3.png */; }; + 89E63C7E18ED83C900BDD04F /* actor8_4.png in Resources */ = {isa = PBXBuildFile; fileRef = 89E63C7418ED83C900BDD04F /* actor8_4.png */; }; + 89E63C8118EDA9E200BDD04F /* RPGBattlePlayerSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89E63C7F18EDA9E200BDD04F /* RPGBattlePlayerSprite.cpp */; }; + 89EA57BE18EAF1EC00A10956 /* monsters.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89EA57BC18EAF1EC00A10956 /* monsters.plist */; }; + 89EA57BF18EAF1EC00A10956 /* monsters.png in Resources */ = {isa = PBXBuildFile; fileRef = 89EA57BD18EAF1EC00A10956 /* monsters.png */; }; + 89EA57C118EAF2CB00A10956 /* battle_bg.png in Resources */ = {isa = PBXBuildFile; fileRef = 89EA57C018EAF2CB00A10956 /* battle_bg.png */; }; + 89EA57E018EB16F100A10956 /* Array.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57D718EB16F100A10956 /* Array.cpp */; }; + 89EA57E118EB16F100A10956 /* Convert.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57D818EB16F100A10956 /* Convert.cpp */; }; + 89EA57E218EB16F100A10956 /* Escaper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57D918EB16F100A10956 /* Escaper.cpp */; }; + 89EA57E318EB16F100A10956 /* IndentCanceller.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57DA18EB16F100A10956 /* IndentCanceller.cpp */; }; + 89EA57E418EB16F100A10956 /* Indenter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57DB18EB16F100A10956 /* Indenter.cpp */; }; + 89EA57E518EB16F100A10956 /* Object.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57DC18EB16F100A10956 /* Object.cpp */; }; + 89EA57E618EB16F100A10956 /* SolidusEscaper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57DD18EB16F100A10956 /* SolidusEscaper.cpp */; }; + 89EA57E718EB16F100A10956 /* Value.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89EA57DE18EB16F100A10956 /* Value.cpp */; }; + 89F5D0DA18E7C579009D703C /* OzgCCScrollBgNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0BE18E7C579009D703C /* OzgCCScrollBgNode.cpp */; }; + 89F5D0DB18E7C579009D703C /* OzgCCUtility.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0C018E7C579009D703C /* OzgCCUtility.cpp */; }; + 89F5D0DC18E7C579009D703C /* OzgFileUtility.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0C218E7C579009D703C /* OzgFileUtility.cpp */; }; + 89F5D0DD18E7C579009D703C /* OzgJoystickLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0C418E7C579009D703C /* OzgJoystickLayer.cpp */; }; + 89F5D0DE18E7C579009D703C /* RPGBaseSceneLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0C618E7C579009D703C /* RPGBaseSceneLayer.cpp */; }; + 89F5D0DF18E7C579009D703C /* RPGLoadingSceneLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0C818E7C579009D703C /* RPGLoadingSceneLayer.cpp */; }; + 89F5D0E018E7C579009D703C /* RPGMapMenuLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0CA18E7C579009D703C /* RPGMapMenuLayer.cpp */; }; + 89F5D0E118E7C579009D703C /* RPGMapNPCRoleSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0CC18E7C579009D703C /* RPGMapNPCRoleSprite.cpp */; }; + 89F5D0E218E7C579009D703C /* RPGMapRoleSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0CE18E7C579009D703C /* RPGMapRoleSprite.cpp */; }; + 89F5D0E518E7C579009D703C /* RPGBattleSceneLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0D418E7C579009D703C /* RPGBattleSceneLayer.cpp */; }; + 89F5D0E618E7C579009D703C /* RPGMapSceneLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0D618E7C579009D703C /* RPGMapSceneLayer.cpp */; }; + 89F5D0E718E7C579009D703C /* RPGStartSceneLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D0D818E7C579009D703C /* RPGStartSceneLayer.cpp */; }; + 89F5D0E918E7C59D009D703C /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 89F5D0E818E7C59D009D703C /* libsqlite3.dylib */; }; + 89F5D0EB18E7C5B4009D703C /* 方正粗圆简体.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0EA18E7C5B4009D703C /* 方正粗圆简体.ttf */; }; + 89F5D10618E7C5C0009D703C /* actor4_0.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0EC18E7C5C0009D703C /* actor4_0.png */; }; + 89F5D10718E7C5C0009D703C /* actor4_1.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0ED18E7C5C0009D703C /* actor4_1.png */; }; + 89F5D10818E7C5C0009D703C /* actor4_2.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0EE18E7C5C0009D703C /* actor4_2.png */; }; + 89F5D10918E7C5C0009D703C /* actor4_3.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0EF18E7C5C0009D703C /* actor4_3.png */; }; + 89F5D10A18E7C5C0009D703C /* actor4_4.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F018E7C5C0009D703C /* actor4_4.png */; }; + 89F5D10B18E7C5C0009D703C /* actor7_0.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F118E7C5C0009D703C /* actor7_0.png */; }; + 89F5D10C18E7C5C0009D703C /* actor7_1.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F218E7C5C0009D703C /* actor7_1.png */; }; + 89F5D10D18E7C5C0009D703C /* actor7_2.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F318E7C5C0009D703C /* actor7_2.png */; }; + 89F5D10E18E7C5C0009D703C /* actor7_3.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F418E7C5C0009D703C /* actor7_3.png */; }; + 89F5D10F18E7C5C0009D703C /* actor7_4.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D0F518E7C5C0009D703C /* actor7_4.png */; }; + 89F5D11A18E7C5C0009D703C /* actor111.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10018E7C5C0009D703C /* actor111.png */; }; + 89F5D11B18E7C5C0009D703C /* actor113.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10118E7C5C0009D703C /* actor113.png */; }; + 89F5D11C18E7C5C0009D703C /* actor114.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10218E7C5C0009D703C /* actor114.png */; }; + 89F5D11D18E7C5C0009D703C /* actor115.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10318E7C5C0009D703C /* actor115.png */; }; + 89F5D11E18E7C5C0009D703C /* actor117.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10418E7C5C0009D703C /* actor117.png */; }; + 89F5D11F18E7C5C0009D703C /* actor120.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D10518E7C5C0009D703C /* actor120.png */; }; + 89F5D12618E7C5CC009D703C /* audio_battle.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12018E7C5CC009D703C /* audio_battle.mp3 */; }; + 89F5D12718E7C5CC009D703C /* audio_effect_btn.wav in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12118E7C5CC009D703C /* audio_effect_btn.wav */; }; + 89F5D12818E7C5CC009D703C /* audio_map_01.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12218E7C5CC009D703C /* audio_map_01.mp3 */; }; + 89F5D12918E7C5CC009D703C /* audio_map_02.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12318E7C5CC009D703C /* audio_map_02.mp3 */; }; + 89F5D12A18E7C5CC009D703C /* audio_map_03.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12418E7C5CC009D703C /* audio_map_03.mp3 */; }; + 89F5D12B18E7C5CC009D703C /* audio_start.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12518E7C5CC009D703C /* audio_start.mp3 */; }; + 89F5D13D18E7C5DD009D703C /* joystick.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12C18E7C5DD009D703C /* joystick.plist */; }; + 89F5D13E18E7C5DD009D703C /* joystick.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12D18E7C5DD009D703C /* joystick.png */; }; + 89F5D13F18E7C5DD009D703C /* main.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12E18E7C5DD009D703C /* main.plist */; }; + 89F5D14018E7C5DD009D703C /* main.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D12F18E7C5DD009D703C /* main.png */; }; + 89F5D14118E7C5DD009D703C /* map_01.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13018E7C5DD009D703C /* map_01.tmx */; }; + 89F5D14218E7C5DD009D703C /* map_02.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13118E7C5DD009D703C /* map_02.tmx */; }; + 89F5D14318E7C5DD009D703C /* map_03.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13218E7C5DD009D703C /* map_03.tmx */; }; + 89F5D14718E7C5DD009D703C /* map.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13618E7C5DD009D703C /* map.png */; }; + 89F5D14818E7C5DD009D703C /* scene_battle_cns.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13718E7C5DD009D703C /* scene_battle_cns.plist */; }; + 89F5D14918E7C5DD009D703C /* scene_loading_cns.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13818E7C5DD009D703C /* scene_loading_cns.plist */; }; + 89F5D14A18E7C5DD009D703C /* scene_map_cns.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13918E7C5DD009D703C /* scene_map_cns.plist */; }; + 89F5D14B18E7C5DD009D703C /* scene_start_cns.plist in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13A18E7C5DD009D703C /* scene_start_cns.plist */; }; + 89F5D14C18E7C5DD009D703C /* start_bg.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13B18E7C5DD009D703C /* start_bg.png */; }; + 89F5D14D18E7C5DD009D703C /* Window_b_00.png in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D13C18E7C5DD009D703C /* Window_b_00.png */; }; + 89F5D14F18E7C5E5009D703C /* db.sys in Resources */ = {isa = PBXBuildFile; fileRef = 89F5D14E18E7C5E5009D703C /* db.sys */; }; + 89F5D15318E7C70F009D703C /* CppSQLite3.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 89F5D15118E7C70F009D703C /* CppSQLite3.cpp */; }; + 9E427D0518EBBA9F00DA4E79 /* map_menu4_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 9E427D0418EBBA9F00DA4E79 /* map_menu4_style1.tmx */; }; + 9E5C5F6E18EE59BB00A68C36 /* battle_menu_style1.tmx in Resources */ = {isa = PBXBuildFile; fileRef = 9E5C5F6D18EE59BB00A68C36 /* battle_menu_style1.tmx */; }; + 9E5C5F7118EE68BD00A68C36 /* RPGBattleMonsterSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9E5C5F6F18EE68BD00A68C36 /* RPGBattleMonsterSprite.cpp */; }; + ED35C0C718323498002A0750 /* CCArmatureAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C03818323497002A0750 /* CCArmatureAnimation.cpp */; }; + ED35C0C818323498002A0750 /* CCProcessBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C03A18323497002A0750 /* CCProcessBase.cpp */; }; + ED35C0C918323498002A0750 /* CCTween.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C03C18323497002A0750 /* CCTween.cpp */; }; + ED35C0CA18323498002A0750 /* CCArmature.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C03E18323497002A0750 /* CCArmature.cpp */; }; + ED35C0CB18323498002A0750 /* CCBone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04018323497002A0750 /* CCBone.cpp */; }; + ED35C0CC18323498002A0750 /* CCDatas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04318323497002A0750 /* CCDatas.cpp */; }; + ED35C0CD18323498002A0750 /* CCBatchNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04618323497002A0750 /* CCBatchNode.cpp */; }; + ED35C0CE18323498002A0750 /* CCDecorativeDisplay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04818323497002A0750 /* CCDecorativeDisplay.cpp */; }; + ED35C0CF18323498002A0750 /* CCDisplayFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04A18323497002A0750 /* CCDisplayFactory.cpp */; }; + ED35C0D018323498002A0750 /* CCDisplayManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04C18323497002A0750 /* CCDisplayManager.cpp */; }; + ED35C0D118323498002A0750 /* CCSkin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C04E18323497002A0750 /* CCSkin.cpp */; }; + ED35C0D218323498002A0750 /* CCColliderDetector.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05318323497002A0750 /* CCColliderDetector.cpp */; }; + ED35C0D318323498002A0750 /* CCArmatureDataManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05618323497002A0750 /* CCArmatureDataManager.cpp */; }; + ED35C0D418323498002A0750 /* CCArmatureDefine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05818323497002A0750 /* CCArmatureDefine.cpp */; }; + ED35C0D518323498002A0750 /* CCDataReaderHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05A18323497002A0750 /* CCDataReaderHelper.cpp */; }; + ED35C0D618323498002A0750 /* CCSpriteFrameCacheHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05C18323497002A0750 /* CCSpriteFrameCacheHelper.cpp */; }; + ED35C0D718323498002A0750 /* CCTransformHelp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C05E18323497002A0750 /* CCTransformHelp.cpp */; }; + ED35C0D818323498002A0750 /* CCTweenFunction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06018323497002A0750 /* CCTweenFunction.cpp */; }; + ED35C0D918323498002A0750 /* CCUtilMath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06218323497002A0750 /* CCUtilMath.cpp */; }; + ED35C0DA18323498002A0750 /* CCComAttribute.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06518323497002A0750 /* CCComAttribute.cpp */; }; + ED35C0DB18323498002A0750 /* CCComAudio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06718323497002A0750 /* CCComAudio.cpp */; }; + ED35C0DC18323498002A0750 /* CCComController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06918323497002A0750 /* CCComController.cpp */; }; + ED35C0DD18323498002A0750 /* CCComRender.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06B18323497002A0750 /* CCComRender.cpp */; }; + ED35C0DE18323498002A0750 /* CCInputDelegate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C06D18323497002A0750 /* CCInputDelegate.cpp */; }; + ED35C0E018323498002A0750 /* UIWidget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07318323497002A0750 /* UIWidget.cpp */; }; + ED35C0E118323498002A0750 /* UILayout.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07618323497002A0750 /* UILayout.cpp */; }; + ED35C0E218323498002A0750 /* UILayoutDefine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07818323497002A0750 /* UILayoutDefine.cpp */; }; + ED35C0E318323498002A0750 /* UILayoutParameter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07A18323497002A0750 /* UILayoutParameter.cpp */; }; + ED35C0E418323498002A0750 /* CocosGUI.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07D18323497002A0750 /* CocosGUI.cpp */; }; + ED35C0E518323498002A0750 /* UIHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C07F18323497002A0750 /* UIHelper.cpp */; }; + ED35C0EC18323498002A0750 /* UIButton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09218323497002A0750 /* UIButton.cpp */; }; + ED35C0ED18323498002A0750 /* UICheckBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09418323498002A0750 /* UICheckBox.cpp */; }; + ED35C0EE18323498002A0750 /* UIImageView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09618323498002A0750 /* UIImageView.cpp */; }; + ED35C0EF18323498002A0750 /* UILabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09818323498002A0750 /* UILabel.cpp */; }; + ED35C0F018323498002A0750 /* UILabelAtlas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09A18323498002A0750 /* UILabelAtlas.cpp */; }; + ED35C0F118323498002A0750 /* UILabelBMFont.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09C18323498002A0750 /* UILabelBMFont.cpp */; }; + ED35C0F218323498002A0750 /* UILoadingBar.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C09E18323498002A0750 /* UILoadingBar.cpp */; }; + ED35C0F318323498002A0750 /* UISlider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C0A018323498002A0750 /* UISlider.cpp */; }; + ED35C0F518323498002A0750 /* UITextField.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C0A418323498002A0750 /* UITextField.cpp */; }; + ED35C0F718323498002A0750 /* DictionaryHelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C0A918323498002A0750 /* DictionaryHelper.cpp */; }; + ED35C0FF18323498002A0750 /* GUIReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C0BE18323498002A0750 /* GUIReader.cpp */; }; + ED35C10018323498002A0750 /* SceneReader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = ED35C0C018323498002A0750 /* SceneReader.cpp */; }; + F293B3CD15EB7BE500256477 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3CC15EB7BE500256477 /* QuartzCore.framework */; }; + F293B3CF15EB7BE500256477 /* OpenGLES.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3CE15EB7BE500256477 /* OpenGLES.framework */; }; + F293B3D115EB7BE500256477 /* OpenAL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D015EB7BE500256477 /* OpenAL.framework */; }; + F293B3D315EB7BE500256477 /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D215EB7BE500256477 /* AudioToolbox.framework */; }; + F293B3D515EB7BE500256477 /* AVFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D415EB7BE500256477 /* AVFoundation.framework */; }; + F293B3D715EB7BE500256477 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D615EB7BE500256477 /* UIKit.framework */; }; + F293B3D915EB7BE500256477 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D815EB7BE500256477 /* Foundation.framework */; }; + F293B3DB15EB7BE500256477 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3DA15EB7BE500256477 /* CoreGraphics.framework */; }; + F293B6FC15EB823D00256477 /* AppController.mm in Sources */ = {isa = PBXBuildFile; fileRef = F293B6F715EB823D00256477 /* AppController.mm */; }; + F293B6FD15EB823D00256477 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = F293B6F815EB823D00256477 /* main.m */; }; + F293B6FE15EB823D00256477 /* RootViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = F293B6FA15EB823D00256477 /* RootViewController.mm */; }; + F293BB9C15EB831F00256477 /* AppDelegate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F293BB7E15EB831F00256477 /* AppDelegate.cpp */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 15C15345168310C700D239F2 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 15C1533E168310C700D239F2 /* cocos2dx.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = 1551A33F158F2AB200E66CFE; + remoteInfo = cocos2dx; + }; + 15C1568A168311DF00D239F2 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 15C1533E168310C700D239F2 /* cocos2dx.xcodeproj */; + proxyType = 1; + remoteGlobalIDString = 1551A33E158F2AB200E66CFE; + remoteInfo = cocos2dx; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 150CD3931872B593007F1964 /* UITouchGroup.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UITouchGroup.cpp; sourceTree = ""; }; + 150CD3941872B593007F1964 /* UITouchGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UITouchGroup.h; sourceTree = ""; }; + 150CD3981872B6B5007F1964 /* CCActionEaseEx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionEaseEx.h; sourceTree = ""; }; + 150E36FD17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_extensions_manual.cpp; sourceTree = ""; }; + 150E36FE17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lua_cocos2dx_extensions_manual.h; sourceTree = ""; }; + 1514E38F18784113003FC4EE /* CCActionEaseEx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionEaseEx.cpp; sourceTree = ""; }; + 1583F15C18D09FF900F3D630 /* CompatibleClasses.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CompatibleClasses.h; sourceTree = ""; }; + 1583F15E18D09FF900F3D630 /* UIListView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIListView.cpp; sourceTree = ""; }; + 1583F15F18D09FF900F3D630 /* UIListView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIListView.h; sourceTree = ""; }; + 1583F16018D09FF900F3D630 /* UIPageView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIPageView.cpp; sourceTree = ""; }; + 1583F16118D09FF900F3D630 /* UIPageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIPageView.h; sourceTree = ""; }; + 1583F16218D09FF900F3D630 /* UIScrollInterface.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIScrollInterface.h; sourceTree = ""; }; + 1583F16318D09FF900F3D630 /* UIScrollView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIScrollView.cpp; sourceTree = ""; }; + 1583F16418D09FF900F3D630 /* UIScrollView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIScrollView.h; sourceTree = ""; }; + 1583F16518D09FF900F3D630 /* UIRichText.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIRichText.cpp; sourceTree = ""; }; + 1583F16618D09FF900F3D630 /* UIRichText.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIRichText.h; sourceTree = ""; }; + 15C1533E168310C700D239F2 /* cocos2dx.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = cocos2dx.xcodeproj; path = ../../../cocos2dx/proj.ios/cocos2dx.xcodeproj; sourceTree = ""; }; + 15C1537C1683112E00D239F2 /* CCBAnimationManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBAnimationManager.cpp; sourceTree = ""; }; + 15C1537D1683112E00D239F2 /* CCBAnimationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBAnimationManager.h; sourceTree = ""; }; + 15C1537E1683112E00D239F2 /* CCBFileLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBFileLoader.cpp; sourceTree = ""; }; + 15C1537F1683112E00D239F2 /* CCBFileLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBFileLoader.h; sourceTree = ""; }; + 15C153801683112E00D239F2 /* CCBKeyframe.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBKeyframe.cpp; sourceTree = ""; }; + 15C153811683112E00D239F2 /* CCBKeyframe.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBKeyframe.h; sourceTree = ""; }; + 15C153821683112E00D239F2 /* CCBMemberVariableAssigner.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBMemberVariableAssigner.h; sourceTree = ""; }; + 15C153831683112E00D239F2 /* CCBReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBReader.cpp; sourceTree = ""; }; + 15C153841683112E00D239F2 /* CCBReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBReader.h; sourceTree = ""; }; + 15C153851683112E00D239F2 /* CCBSelectorResolver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBSelectorResolver.h; sourceTree = ""; }; + 15C153861683112E00D239F2 /* CCBSequence.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBSequence.cpp; sourceTree = ""; }; + 15C153871683112E00D239F2 /* CCBSequence.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBSequence.h; sourceTree = ""; }; + 15C153881683112E00D239F2 /* CCBSequenceProperty.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBSequenceProperty.cpp; sourceTree = ""; }; + 15C153891683112E00D239F2 /* CCBSequenceProperty.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBSequenceProperty.h; sourceTree = ""; }; + 15C1538A1683112E00D239F2 /* CCBValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBValue.cpp; sourceTree = ""; }; + 15C1538B1683112E00D239F2 /* CCBValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBValue.h; sourceTree = ""; }; + 15C1538C1683112E00D239F2 /* CCControlButtonLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlButtonLoader.cpp; sourceTree = ""; }; + 15C1538D1683112E00D239F2 /* CCControlButtonLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlButtonLoader.h; sourceTree = ""; }; + 15C1538E1683112E00D239F2 /* CCControlLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlLoader.cpp; sourceTree = ""; }; + 15C1538F1683112E00D239F2 /* CCControlLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlLoader.h; sourceTree = ""; }; + 15C153901683112E00D239F2 /* CCData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCData.cpp; sourceTree = ""; }; + 15C153911683112E00D239F2 /* CCData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCData.h; sourceTree = ""; }; + 15C153921683112E00D239F2 /* CCLabelBMFontLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLabelBMFontLoader.cpp; sourceTree = ""; }; + 15C153931683112E00D239F2 /* CCLabelBMFontLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabelBMFontLoader.h; sourceTree = ""; }; + 15C153941683112E00D239F2 /* CCLabelTTFLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLabelTTFLoader.cpp; sourceTree = ""; }; + 15C153951683112E00D239F2 /* CCLabelTTFLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLabelTTFLoader.h; sourceTree = ""; }; + 15C153961683112E00D239F2 /* CCLayerColorLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLayerColorLoader.cpp; sourceTree = ""; }; + 15C153971683112E00D239F2 /* CCLayerColorLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLayerColorLoader.h; sourceTree = ""; }; + 15C153981683112E00D239F2 /* CCLayerGradientLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLayerGradientLoader.cpp; sourceTree = ""; }; + 15C153991683112E00D239F2 /* CCLayerGradientLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLayerGradientLoader.h; sourceTree = ""; }; + 15C1539A1683112E00D239F2 /* CCLayerLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLayerLoader.cpp; sourceTree = ""; }; + 15C1539B1683112E00D239F2 /* CCLayerLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLayerLoader.h; sourceTree = ""; }; + 15C1539C1683112E00D239F2 /* CCMenuItemImageLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCMenuItemImageLoader.cpp; sourceTree = ""; }; + 15C1539D1683112E00D239F2 /* CCMenuItemImageLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMenuItemImageLoader.h; sourceTree = ""; }; + 15C1539E1683112E00D239F2 /* CCMenuItemLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCMenuItemLoader.cpp; sourceTree = ""; }; + 15C1539F1683112E00D239F2 /* CCMenuItemLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMenuItemLoader.h; sourceTree = ""; }; + 15C153A01683112E00D239F2 /* CCMenuLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCMenuLoader.h; sourceTree = ""; }; + 15C153A11683112E00D239F2 /* CCNode+CCBRelativePositioning.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "CCNode+CCBRelativePositioning.cpp"; sourceTree = ""; }; + 15C153A21683112E00D239F2 /* CCNode+CCBRelativePositioning.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "CCNode+CCBRelativePositioning.h"; sourceTree = ""; }; + 15C153A31683112E00D239F2 /* CCNodeLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCNodeLoader.cpp; sourceTree = ""; }; + 15C153A41683112E00D239F2 /* CCNodeLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNodeLoader.h; sourceTree = ""; }; + 15C153A51683112E00D239F2 /* CCNodeLoaderLibrary.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCNodeLoaderLibrary.cpp; sourceTree = ""; }; + 15C153A61683112E00D239F2 /* CCNodeLoaderLibrary.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNodeLoaderLibrary.h; sourceTree = ""; }; + 15C153A71683112E00D239F2 /* CCNodeLoaderListener.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCNodeLoaderListener.h; sourceTree = ""; }; + 15C153A81683112E00D239F2 /* CCParticleSystemQuadLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCParticleSystemQuadLoader.cpp; sourceTree = ""; }; + 15C153A91683112E00D239F2 /* CCParticleSystemQuadLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleSystemQuadLoader.h; sourceTree = ""; }; + 15C153AA1683112E00D239F2 /* CCScale9SpriteLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCScale9SpriteLoader.cpp; sourceTree = ""; }; + 15C153AB1683112E00D239F2 /* CCScale9SpriteLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCScale9SpriteLoader.h; sourceTree = ""; }; + 15C153AC1683112E00D239F2 /* CCScrollViewLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCScrollViewLoader.cpp; sourceTree = ""; }; + 15C153AD1683112E00D239F2 /* CCScrollViewLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCScrollViewLoader.h; sourceTree = ""; }; + 15C153AE1683112E00D239F2 /* CCSpriteLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSpriteLoader.cpp; sourceTree = ""; }; + 15C153AF1683112E00D239F2 /* CCSpriteLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSpriteLoader.h; sourceTree = ""; }; + 15C153B01683112E00D239F2 /* cocos-ext.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "cocos-ext.h"; sourceTree = ""; }; + 15C153B11683112E00D239F2 /* ExtensionMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExtensionMacros.h; sourceTree = ""; }; + 15C153B41683112E00D239F2 /* CCControl.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControl.cpp; sourceTree = ""; }; + 15C153B51683112E00D239F2 /* CCControl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControl.h; sourceTree = ""; }; + 15C153B61683112E00D239F2 /* CCControlButton.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlButton.cpp; sourceTree = ""; }; + 15C153B71683112E00D239F2 /* CCControlButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlButton.h; sourceTree = ""; }; + 15C153B81683112E00D239F2 /* CCControlColourPicker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlColourPicker.cpp; sourceTree = ""; }; + 15C153B91683112E00D239F2 /* CCControlColourPicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlColourPicker.h; sourceTree = ""; }; + 15C153BA1683112E00D239F2 /* CCControlExtensions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlExtensions.h; sourceTree = ""; }; + 15C153BB1683112E00D239F2 /* CCControlHuePicker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlHuePicker.cpp; sourceTree = ""; }; + 15C153BC1683112E00D239F2 /* CCControlHuePicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlHuePicker.h; sourceTree = ""; }; + 15C153BD1683112E00D239F2 /* CCControlPotentiometer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlPotentiometer.cpp; sourceTree = ""; }; + 15C153BE1683112E00D239F2 /* CCControlPotentiometer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlPotentiometer.h; sourceTree = ""; }; + 15C153BF1683112E00D239F2 /* CCControlSaturationBrightnessPicker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlSaturationBrightnessPicker.cpp; sourceTree = ""; }; + 15C153C01683112E00D239F2 /* CCControlSaturationBrightnessPicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlSaturationBrightnessPicker.h; sourceTree = ""; }; + 15C153C11683112E00D239F2 /* CCControlSlider.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlSlider.cpp; sourceTree = ""; }; + 15C153C21683112E00D239F2 /* CCControlSlider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlSlider.h; sourceTree = ""; }; + 15C153C31683112E00D239F2 /* CCControlStepper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlStepper.cpp; sourceTree = ""; }; + 15C153C41683112E00D239F2 /* CCControlStepper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlStepper.h; sourceTree = ""; }; + 15C153C51683112E00D239F2 /* CCControlSwitch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlSwitch.cpp; sourceTree = ""; }; + 15C153C61683112E00D239F2 /* CCControlSwitch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlSwitch.h; sourceTree = ""; }; + 15C153C71683112E00D239F2 /* CCControlUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlUtils.cpp; sourceTree = ""; }; + 15C153C81683112E00D239F2 /* CCControlUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlUtils.h; sourceTree = ""; }; + 15C153C91683112E00D239F2 /* CCInvocation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCInvocation.cpp; sourceTree = ""; }; + 15C153CA1683112E00D239F2 /* CCInvocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCInvocation.h; sourceTree = ""; }; + 15C153CB1683112E00D239F2 /* CCScale9Sprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCScale9Sprite.cpp; sourceTree = ""; }; + 15C153CC1683112E00D239F2 /* CCScale9Sprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCScale9Sprite.h; sourceTree = ""; }; + 15C153CE1683112E00D239F2 /* CCEditBox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCEditBox.cpp; sourceTree = ""; }; + 15C153CF1683112E00D239F2 /* CCEditBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEditBox.h; sourceTree = ""; }; + 15C153D01683112E00D239F2 /* CCEditBoxImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImpl.h; sourceTree = ""; }; + 15C153D31683112E00D239F2 /* CCEditBoxImplIOS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImplIOS.h; sourceTree = ""; }; + 15C153D41683112E00D239F2 /* CCEditBoxImplIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCEditBoxImplIOS.mm; sourceTree = ""; }; + 15C153D81683112E00D239F2 /* CCScrollView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCScrollView.cpp; sourceTree = ""; }; + 15C153D91683112E00D239F2 /* CCScrollView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCScrollView.h; sourceTree = ""; }; + 15C153DA1683112E00D239F2 /* CCSorting.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSorting.cpp; sourceTree = ""; }; + 15C153DB1683112E00D239F2 /* CCSorting.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSorting.h; sourceTree = ""; }; + 15C153DC1683112E00D239F2 /* CCTableView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTableView.cpp; sourceTree = ""; }; + 15C153DD1683112E00D239F2 /* CCTableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTableView.h; sourceTree = ""; }; + 15C153DE1683112E00D239F2 /* CCTableViewCell.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTableViewCell.cpp; sourceTree = ""; }; + 15C153DF1683112E00D239F2 /* CCTableViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTableViewCell.h; sourceTree = ""; }; + 15C153E11683112E00D239F2 /* HttpClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HttpClient.cpp; sourceTree = ""; }; + 15C153E21683112E00D239F2 /* HttpClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpClient.h; sourceTree = ""; }; + 15C153E31683112E00D239F2 /* HttpRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpRequest.h; sourceTree = ""; }; + 15C153E41683112E00D239F2 /* HttpResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HttpResponse.h; sourceTree = ""; }; + 15C153E61683112E00D239F2 /* CCPhysicsDebugNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsDebugNode.cpp; sourceTree = ""; }; + 15C153E71683112E00D239F2 /* CCPhysicsDebugNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsDebugNode.h; sourceTree = ""; }; + 15C153E81683112E00D239F2 /* CCPhysicsSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCPhysicsSprite.cpp; sourceTree = ""; }; + 15C153E91683112E00D239F2 /* CCPhysicsSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPhysicsSprite.h; sourceTree = ""; }; + 15C154341683116B00D239F2 /* chipmunk.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = chipmunk.h; sourceTree = ""; }; + 15C154351683116B00D239F2 /* chipmunk_ffi.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = chipmunk_ffi.h; sourceTree = ""; }; + 15C154361683116B00D239F2 /* chipmunk_private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = chipmunk_private.h; sourceTree = ""; }; + 15C154371683116B00D239F2 /* chipmunk_types.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = chipmunk_types.h; sourceTree = ""; }; + 15C154381683116B00D239F2 /* chipmunk_unsafe.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = chipmunk_unsafe.h; sourceTree = ""; }; + 15C1543A1683116B00D239F2 /* cpConstraint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpConstraint.h; sourceTree = ""; }; + 15C1543B1683116B00D239F2 /* cpDampedRotarySpring.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpDampedRotarySpring.h; sourceTree = ""; }; + 15C1543C1683116B00D239F2 /* cpDampedSpring.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpDampedSpring.h; sourceTree = ""; }; + 15C1543D1683116B00D239F2 /* cpGearJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpGearJoint.h; sourceTree = ""; }; + 15C1543E1683116B00D239F2 /* cpGrooveJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpGrooveJoint.h; sourceTree = ""; }; + 15C1543F1683116B00D239F2 /* cpPinJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpPinJoint.h; sourceTree = ""; }; + 15C154401683116B00D239F2 /* cpPivotJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpPivotJoint.h; sourceTree = ""; }; + 15C154411683116B00D239F2 /* cpRatchetJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpRatchetJoint.h; sourceTree = ""; }; + 15C154421683116B00D239F2 /* cpRotaryLimitJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpRotaryLimitJoint.h; sourceTree = ""; }; + 15C154431683116B00D239F2 /* cpSimpleMotor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpSimpleMotor.h; sourceTree = ""; }; + 15C154441683116B00D239F2 /* cpSlideJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpSlideJoint.h; sourceTree = ""; }; + 15C154451683116B00D239F2 /* util.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = util.h; sourceTree = ""; }; + 15C154461683116B00D239F2 /* cpArbiter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpArbiter.h; sourceTree = ""; }; + 15C154471683116B00D239F2 /* cpBB.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpBB.h; sourceTree = ""; }; + 15C154481683116B00D239F2 /* cpBody.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpBody.h; sourceTree = ""; }; + 15C154491683116B00D239F2 /* cpPolyShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpPolyShape.h; sourceTree = ""; }; + 15C1544A1683116B00D239F2 /* cpShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpShape.h; sourceTree = ""; }; + 15C1544B1683116B00D239F2 /* cpSpace.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpSpace.h; sourceTree = ""; }; + 15C1544C1683116B00D239F2 /* cpSpatialIndex.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpSpatialIndex.h; sourceTree = ""; }; + 15C1544D1683116B00D239F2 /* cpVect.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpVect.h; sourceTree = ""; }; + 15C1545C1683116B00D239F2 /* chipmunk.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = chipmunk.c; sourceTree = ""; }; + 15C1545D1683116B00D239F2 /* CMakeLists.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = CMakeLists.txt; sourceTree = ""; }; + 15C1545F1683116B00D239F2 /* cpConstraint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpConstraint.c; sourceTree = ""; }; + 15C154601683116B00D239F2 /* cpDampedRotarySpring.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpDampedRotarySpring.c; sourceTree = ""; }; + 15C154611683116B00D239F2 /* cpDampedSpring.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpDampedSpring.c; sourceTree = ""; }; + 15C154621683116B00D239F2 /* cpGearJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpGearJoint.c; sourceTree = ""; }; + 15C154631683116B00D239F2 /* cpGrooveJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpGrooveJoint.c; sourceTree = ""; }; + 15C154641683116B00D239F2 /* cpPinJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpPinJoint.c; sourceTree = ""; }; + 15C154651683116B00D239F2 /* cpPivotJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpPivotJoint.c; sourceTree = ""; }; + 15C154661683116B00D239F2 /* cpRatchetJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpRatchetJoint.c; sourceTree = ""; }; + 15C154671683116B00D239F2 /* cpRotaryLimitJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpRotaryLimitJoint.c; sourceTree = ""; }; + 15C154681683116B00D239F2 /* cpSimpleMotor.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSimpleMotor.c; sourceTree = ""; }; + 15C154691683116B00D239F2 /* cpSlideJoint.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSlideJoint.c; sourceTree = ""; }; + 15C1546A1683116B00D239F2 /* cpArbiter.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpArbiter.c; sourceTree = ""; }; + 15C1546B1683116B00D239F2 /* cpArray.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpArray.c; sourceTree = ""; }; + 15C1546C1683116B00D239F2 /* cpBB.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpBB.c; sourceTree = ""; }; + 15C1546D1683116B00D239F2 /* cpBBTree.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpBBTree.c; sourceTree = ""; }; + 15C1546E1683116B00D239F2 /* cpBody.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpBody.c; sourceTree = ""; }; + 15C1546F1683116B00D239F2 /* cpCollision.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpCollision.c; sourceTree = ""; }; + 15C154701683116B00D239F2 /* cpHashSet.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpHashSet.c; sourceTree = ""; }; + 15C154711683116B00D239F2 /* cpPolyShape.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpPolyShape.c; sourceTree = ""; }; + 15C154721683116B00D239F2 /* cpShape.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpShape.c; sourceTree = ""; }; + 15C154731683116B00D239F2 /* cpSpace.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpace.c; sourceTree = ""; }; + 15C154741683116B00D239F2 /* cpSpaceComponent.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpaceComponent.c; sourceTree = ""; }; + 15C154751683116B00D239F2 /* cpSpaceHash.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpaceHash.c; sourceTree = ""; }; + 15C154761683116B00D239F2 /* cpSpaceQuery.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpaceQuery.c; sourceTree = ""; }; + 15C154771683116B00D239F2 /* cpSpaceStep.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpaceStep.c; sourceTree = ""; }; + 15C154781683116B00D239F2 /* cpSpatialIndex.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSpatialIndex.c; sourceTree = ""; }; + 15C154791683116B00D239F2 /* cpSweep1D.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpSweep1D.c; sourceTree = ""; }; + 15C1547A1683116B00D239F2 /* cpVect.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = cpVect.c; sourceTree = ""; }; + 15C1547B1683116B00D239F2 /* prime.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = prime.h; sourceTree = ""; }; + 15C154A91683118600D239F2 /* Box2D.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Box2D.h; sourceTree = ""; }; + 15C154AB1683118600D239F2 /* b2BroadPhase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2BroadPhase.cpp; sourceTree = ""; }; + 15C154AC1683118600D239F2 /* b2BroadPhase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2BroadPhase.h; sourceTree = ""; }; + 15C154AD1683118600D239F2 /* b2CollideCircle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2CollideCircle.cpp; sourceTree = ""; }; + 15C154AE1683118600D239F2 /* b2CollideEdge.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2CollideEdge.cpp; sourceTree = ""; }; + 15C154AF1683118600D239F2 /* b2CollidePolygon.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2CollidePolygon.cpp; sourceTree = ""; }; + 15C154B01683118600D239F2 /* b2Collision.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Collision.cpp; sourceTree = ""; }; + 15C154B11683118600D239F2 /* b2Collision.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Collision.h; sourceTree = ""; }; + 15C154B21683118600D239F2 /* b2Distance.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Distance.cpp; sourceTree = ""; }; + 15C154B31683118600D239F2 /* b2Distance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Distance.h; sourceTree = ""; }; + 15C154B41683118600D239F2 /* b2DynamicTree.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2DynamicTree.cpp; sourceTree = ""; }; + 15C154B51683118600D239F2 /* b2DynamicTree.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2DynamicTree.h; sourceTree = ""; }; + 15C154B61683118600D239F2 /* b2TimeOfImpact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2TimeOfImpact.cpp; sourceTree = ""; }; + 15C154B71683118600D239F2 /* b2TimeOfImpact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2TimeOfImpact.h; sourceTree = ""; }; + 15C154B91683118600D239F2 /* b2ChainShape.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ChainShape.cpp; sourceTree = ""; }; + 15C154BA1683118600D239F2 /* b2ChainShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ChainShape.h; sourceTree = ""; }; + 15C154BB1683118600D239F2 /* b2CircleShape.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2CircleShape.cpp; sourceTree = ""; }; + 15C154BC1683118600D239F2 /* b2CircleShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2CircleShape.h; sourceTree = ""; }; + 15C154BD1683118600D239F2 /* b2EdgeShape.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2EdgeShape.cpp; sourceTree = ""; }; + 15C154BE1683118600D239F2 /* b2EdgeShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2EdgeShape.h; sourceTree = ""; }; + 15C154BF1683118600D239F2 /* b2PolygonShape.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2PolygonShape.cpp; sourceTree = ""; }; + 15C154C01683118600D239F2 /* b2PolygonShape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2PolygonShape.h; sourceTree = ""; }; + 15C154C11683118600D239F2 /* b2Shape.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Shape.h; sourceTree = ""; }; + 15C154C31683118600D239F2 /* b2BlockAllocator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2BlockAllocator.cpp; sourceTree = ""; }; + 15C154C41683118600D239F2 /* b2BlockAllocator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2BlockAllocator.h; sourceTree = ""; }; + 15C154C51683118600D239F2 /* b2Draw.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Draw.cpp; sourceTree = ""; }; + 15C154C61683118600D239F2 /* b2Draw.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Draw.h; sourceTree = ""; }; + 15C154C71683118600D239F2 /* b2GrowableStack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2GrowableStack.h; sourceTree = ""; }; + 15C154C81683118600D239F2 /* b2Math.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Math.cpp; sourceTree = ""; }; + 15C154C91683118600D239F2 /* b2Math.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Math.h; sourceTree = ""; }; + 15C154CA1683118600D239F2 /* b2Settings.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Settings.cpp; sourceTree = ""; }; + 15C154CB1683118600D239F2 /* b2Settings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Settings.h; sourceTree = ""; }; + 15C154CC1683118600D239F2 /* b2StackAllocator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2StackAllocator.cpp; sourceTree = ""; }; + 15C154CD1683118600D239F2 /* b2StackAllocator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2StackAllocator.h; sourceTree = ""; }; + 15C154CE1683118600D239F2 /* b2Timer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Timer.cpp; sourceTree = ""; }; + 15C154CF1683118600D239F2 /* b2Timer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Timer.h; sourceTree = ""; }; + 15C154D11683118600D239F2 /* b2Body.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Body.cpp; sourceTree = ""; }; + 15C154D21683118600D239F2 /* b2Body.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Body.h; sourceTree = ""; }; + 15C154D31683118600D239F2 /* b2ContactManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ContactManager.cpp; sourceTree = ""; }; + 15C154D41683118600D239F2 /* b2ContactManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ContactManager.h; sourceTree = ""; }; + 15C154D51683118600D239F2 /* b2Fixture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Fixture.cpp; sourceTree = ""; }; + 15C154D61683118600D239F2 /* b2Fixture.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Fixture.h; sourceTree = ""; }; + 15C154D71683118600D239F2 /* b2Island.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Island.cpp; sourceTree = ""; }; + 15C154D81683118600D239F2 /* b2Island.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Island.h; sourceTree = ""; }; + 15C154D91683118600D239F2 /* b2TimeStep.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2TimeStep.h; sourceTree = ""; }; + 15C154DA1683118600D239F2 /* b2World.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2World.cpp; sourceTree = ""; }; + 15C154DB1683118600D239F2 /* b2World.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2World.h; sourceTree = ""; }; + 15C154DC1683118600D239F2 /* b2WorldCallbacks.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2WorldCallbacks.cpp; sourceTree = ""; }; + 15C154DD1683118600D239F2 /* b2WorldCallbacks.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2WorldCallbacks.h; sourceTree = ""; }; + 15C154DF1683118600D239F2 /* b2ChainAndCircleContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ChainAndCircleContact.cpp; sourceTree = ""; }; + 15C154E01683118600D239F2 /* b2ChainAndCircleContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ChainAndCircleContact.h; sourceTree = ""; }; + 15C154E11683118600D239F2 /* b2ChainAndPolygonContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ChainAndPolygonContact.cpp; sourceTree = ""; }; + 15C154E21683118600D239F2 /* b2ChainAndPolygonContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ChainAndPolygonContact.h; sourceTree = ""; }; + 15C154E31683118600D239F2 /* b2CircleContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2CircleContact.cpp; sourceTree = ""; }; + 15C154E41683118600D239F2 /* b2CircleContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2CircleContact.h; sourceTree = ""; }; + 15C154E51683118600D239F2 /* b2Contact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Contact.cpp; sourceTree = ""; }; + 15C154E61683118600D239F2 /* b2Contact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Contact.h; sourceTree = ""; }; + 15C154E71683118600D239F2 /* b2ContactSolver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2ContactSolver.cpp; sourceTree = ""; }; + 15C154E81683118600D239F2 /* b2ContactSolver.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2ContactSolver.h; sourceTree = ""; }; + 15C154E91683118600D239F2 /* b2EdgeAndCircleContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2EdgeAndCircleContact.cpp; sourceTree = ""; }; + 15C154EA1683118600D239F2 /* b2EdgeAndCircleContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2EdgeAndCircleContact.h; sourceTree = ""; }; + 15C154EB1683118600D239F2 /* b2EdgeAndPolygonContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2EdgeAndPolygonContact.cpp; sourceTree = ""; }; + 15C154EC1683118600D239F2 /* b2EdgeAndPolygonContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2EdgeAndPolygonContact.h; sourceTree = ""; }; + 15C154ED1683118600D239F2 /* b2PolygonAndCircleContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2PolygonAndCircleContact.cpp; sourceTree = ""; }; + 15C154EE1683118600D239F2 /* b2PolygonAndCircleContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2PolygonAndCircleContact.h; sourceTree = ""; }; + 15C154EF1683118600D239F2 /* b2PolygonContact.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2PolygonContact.cpp; sourceTree = ""; }; + 15C154F01683118600D239F2 /* b2PolygonContact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2PolygonContact.h; sourceTree = ""; }; + 15C154F21683118600D239F2 /* b2DistanceJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2DistanceJoint.cpp; sourceTree = ""; }; + 15C154F31683118600D239F2 /* b2DistanceJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2DistanceJoint.h; sourceTree = ""; }; + 15C154F41683118600D239F2 /* b2FrictionJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2FrictionJoint.cpp; sourceTree = ""; }; + 15C154F51683118600D239F2 /* b2FrictionJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2FrictionJoint.h; sourceTree = ""; }; + 15C154F61683118600D239F2 /* b2GearJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2GearJoint.cpp; sourceTree = ""; }; + 15C154F71683118600D239F2 /* b2GearJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2GearJoint.h; sourceTree = ""; }; + 15C154F81683118600D239F2 /* b2Joint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Joint.cpp; sourceTree = ""; }; + 15C154F91683118600D239F2 /* b2Joint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Joint.h; sourceTree = ""; }; + 15C154FA1683118600D239F2 /* b2MouseJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2MouseJoint.cpp; sourceTree = ""; }; + 15C154FB1683118600D239F2 /* b2MouseJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2MouseJoint.h; sourceTree = ""; }; + 15C154FC1683118600D239F2 /* b2PrismaticJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2PrismaticJoint.cpp; sourceTree = ""; }; + 15C154FD1683118600D239F2 /* b2PrismaticJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2PrismaticJoint.h; sourceTree = ""; }; + 15C154FE1683118600D239F2 /* b2PulleyJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2PulleyJoint.cpp; sourceTree = ""; }; + 15C154FF1683118600D239F2 /* b2PulleyJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2PulleyJoint.h; sourceTree = ""; }; + 15C155001683118600D239F2 /* b2RevoluteJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2RevoluteJoint.cpp; sourceTree = ""; }; + 15C155011683118600D239F2 /* b2RevoluteJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2RevoluteJoint.h; sourceTree = ""; }; + 15C155021683118600D239F2 /* b2RopeJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2RopeJoint.cpp; sourceTree = ""; }; + 15C155031683118600D239F2 /* b2RopeJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2RopeJoint.h; sourceTree = ""; }; + 15C155041683118600D239F2 /* b2WeldJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2WeldJoint.cpp; sourceTree = ""; }; + 15C155051683118600D239F2 /* b2WeldJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2WeldJoint.h; sourceTree = ""; }; + 15C155061683118600D239F2 /* b2WheelJoint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2WheelJoint.cpp; sourceTree = ""; }; + 15C155071683118600D239F2 /* b2WheelJoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2WheelJoint.h; sourceTree = ""; }; + 15C1551C1683118600D239F2 /* b2Rope.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = b2Rope.cpp; sourceTree = ""; }; + 15C1551D1683118600D239F2 /* b2Rope.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = b2Rope.h; sourceTree = ""; }; + 15C15571168311AA00D239F2 /* Export.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Export.h; sourceTree = ""; }; + 15C15572168311AA00D239F2 /* SimpleAudioEngine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SimpleAudioEngine.h; sourceTree = ""; }; + 15C15574168311AA00D239F2 /* CDAudioManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDAudioManager.h; sourceTree = ""; }; + 15C15575168311AA00D239F2 /* CDAudioManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDAudioManager.m; sourceTree = ""; }; + 15C15576168311AA00D239F2 /* CDConfig.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDConfig.h; sourceTree = ""; }; + 15C15577168311AA00D239F2 /* CDOpenALSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CDOpenALSupport.h; sourceTree = ""; }; + 15C15578168311AA00D239F2 /* CDOpenALSupport.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CDOpenALSupport.m; sourceTree = ""; }; + 15C15579168311AA00D239F2 /* CocosDenshion.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CocosDenshion.h; sourceTree = ""; }; + 15C1557A168311AA00D239F2 /* CocosDenshion.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CocosDenshion.m; sourceTree = ""; }; + 15C1557B168311AA00D239F2 /* SimpleAudioEngine.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SimpleAudioEngine.mm; sourceTree = ""; }; + 15C1557C168311AA00D239F2 /* SimpleAudioEngine_objc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SimpleAudioEngine_objc.h; sourceTree = ""; }; + 15C1557D168311AA00D239F2 /* SimpleAudioEngine_objc.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SimpleAudioEngine_objc.m; sourceTree = ""; }; + 15C15651168311CB00D239F2 /* tolua++.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "tolua++.h"; sourceTree = ""; }; + 15C15652168311CB00D239F2 /* tolua_event.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_event.c; sourceTree = ""; }; + 15C15653168311CB00D239F2 /* tolua_event.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tolua_event.h; sourceTree = ""; }; + 15C15654168311CB00D239F2 /* tolua_is.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_is.c; sourceTree = ""; }; + 15C15655168311CB00D239F2 /* tolua_map.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_map.c; sourceTree = ""; }; + 15C15656168311CB00D239F2 /* tolua_push.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_push.c; sourceTree = ""; }; + 15C15657168311CB00D239F2 /* tolua_to.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_to.c; sourceTree = ""; }; + 15C1568D1683131500D239F2 /* libcurl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcurl.a; path = ../../../cocos2dx/platform/third_party/ios/libraries/libcurl.a; sourceTree = ""; }; + 15C156911683138E00D239F2 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = SOURCE_ROOT; }; + 15C156921683138E00D239F2 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = SOURCE_ROOT; }; + 15C156931683138E00D239F2 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = SOURCE_ROOT; }; + 15C156941683138E00D239F2 /* Icon-57.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Icon-57.png"; sourceTree = SOURCE_ROOT; }; + 15C156951683138E00D239F2 /* Icon-72.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Icon-72.png"; sourceTree = SOURCE_ROOT; }; + 15C156961683138E00D239F2 /* Icon-114.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Icon-114.png"; sourceTree = SOURCE_ROOT; }; + 15C156971683138E00D239F2 /* Icon-144.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Icon-144.png"; sourceTree = SOURCE_ROOT; }; + 15CA8CEF18696743000032AB /* lua_cocos2dx_cocostudio_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_cocostudio_manual.cpp; sourceTree = ""; }; + 15CA8CF018696743000032AB /* lua_cocos2dx_cocostudio_manual.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lua_cocos2dx_cocostudio_manual.h; sourceTree = ""; }; + 15CA8CF118696743000032AB /* lua_cocos2dx_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_manual.cpp; sourceTree = ""; }; + 15CA8CF218696743000032AB /* lua_cocos2dx_manual.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lua_cocos2dx_manual.h; sourceTree = ""; }; + 15CA8CF318696743000032AB /* LuaCocoStudio.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LuaCocoStudio.cpp; sourceTree = ""; }; + 15CA8CF418696743000032AB /* LuaCocoStudio.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LuaCocoStudio.h; sourceTree = ""; }; + 15CA8CFA186967FB000032AB /* document.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = document.h; sourceTree = ""; }; + 15CA8CFB186967FB000032AB /* filestream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = filestream.h; sourceTree = ""; }; + 15CA8CFD186967FB000032AB /* pow10.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pow10.h; sourceTree = ""; }; + 15CA8CFE186967FB000032AB /* stack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stack.h; sourceTree = ""; }; + 15CA8CFF186967FB000032AB /* strfunc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = strfunc.h; sourceTree = ""; }; + 15CA8D00186967FB000032AB /* prettywriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = prettywriter.h; sourceTree = ""; }; + 15CA8D01186967FB000032AB /* rapidjson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rapidjson.h; sourceTree = ""; }; + 15CA8D02186967FB000032AB /* reader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = reader.h; sourceTree = ""; }; + 15CA8D03186967FB000032AB /* stringbuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stringbuffer.h; sourceTree = ""; }; + 15CA8D04186967FB000032AB /* writer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = writer.h; sourceTree = ""; }; + 1A40E7B81727C47D006D4861 /* Animation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Animation.cpp; sourceTree = ""; }; + 1A40E7B91727C47D006D4861 /* Animation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Animation.h; sourceTree = ""; }; + 1A40E7BA1727C47D006D4861 /* AnimationState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AnimationState.cpp; sourceTree = ""; }; + 1A40E7BB1727C47D006D4861 /* AnimationState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationState.h; sourceTree = ""; }; + 1A40E7BC1727C47D006D4861 /* AnimationStateData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AnimationStateData.cpp; sourceTree = ""; }; + 1A40E7BD1727C47D006D4861 /* AnimationStateData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AnimationStateData.h; sourceTree = ""; }; + 1A40E7BE1727C47D006D4861 /* Atlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Atlas.cpp; sourceTree = ""; }; + 1A40E7BF1727C47D006D4861 /* Atlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Atlas.h; sourceTree = ""; }; + 1A40E7C01727C47D006D4861 /* AtlasAttachmentLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AtlasAttachmentLoader.cpp; sourceTree = ""; }; + 1A40E7C11727C47D006D4861 /* AtlasAttachmentLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AtlasAttachmentLoader.h; sourceTree = ""; }; + 1A40E7C21727C47D006D4861 /* Attachment.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Attachment.cpp; sourceTree = ""; }; + 1A40E7C31727C47D006D4861 /* Attachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Attachment.h; sourceTree = ""; }; + 1A40E7C41727C47D006D4861 /* AttachmentLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AttachmentLoader.cpp; sourceTree = ""; }; + 1A40E7C51727C47D006D4861 /* AttachmentLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AttachmentLoader.h; sourceTree = ""; }; + 1A40E7C61727C47D006D4861 /* Bone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Bone.cpp; sourceTree = ""; }; + 1A40E7C71727C47D006D4861 /* Bone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Bone.h; sourceTree = ""; }; + 1A40E7C81727C47D006D4861 /* BoneData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BoneData.cpp; sourceTree = ""; }; + 1A40E7C91727C47D006D4861 /* BoneData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BoneData.h; sourceTree = ""; }; + 1A40E7CA1727C47E006D4861 /* extension.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = extension.cpp; sourceTree = ""; }; + 1A40E7CB1727C47E006D4861 /* extension.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = extension.h; sourceTree = ""; }; + 1A40E7CC1727C47E006D4861 /* Json.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Json.cpp; sourceTree = ""; }; + 1A40E7CD1727C47E006D4861 /* Json.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Json.h; sourceTree = ""; }; + 1A40E7CE1727C47E006D4861 /* RegionAttachment.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RegionAttachment.cpp; sourceTree = ""; }; + 1A40E7CF1727C47E006D4861 /* RegionAttachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RegionAttachment.h; sourceTree = ""; }; + 1A40E7D01727C47E006D4861 /* Skeleton.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Skeleton.cpp; sourceTree = ""; }; + 1A40E7D11727C47E006D4861 /* Skeleton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Skeleton.h; sourceTree = ""; }; + 1A40E7D21727C47E006D4861 /* SkeletonData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SkeletonData.cpp; sourceTree = ""; }; + 1A40E7D31727C47E006D4861 /* SkeletonData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonData.h; sourceTree = ""; }; + 1A40E7D41727C47E006D4861 /* SkeletonJson.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SkeletonJson.cpp; sourceTree = ""; }; + 1A40E7D51727C47E006D4861 /* SkeletonJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkeletonJson.h; sourceTree = ""; }; + 1A40E7D61727C47E006D4861 /* Skin.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Skin.cpp; sourceTree = ""; }; + 1A40E7D71727C47E006D4861 /* Skin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Skin.h; sourceTree = ""; }; + 1A40E7D81727C47E006D4861 /* Slot.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Slot.cpp; sourceTree = ""; }; + 1A40E7D91727C47E006D4861 /* Slot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Slot.h; sourceTree = ""; }; + 1A40E7DA1727C47E006D4861 /* SlotData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SlotData.cpp; sourceTree = ""; }; + 1A40E7DB1727C47E006D4861 /* SlotData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlotData.h; sourceTree = ""; }; + 1A40E7DC1727C47E006D4861 /* spine-cocos2dx.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "spine-cocos2dx.cpp"; sourceTree = ""; }; + 1A40E7DD1727C47E006D4861 /* spine-cocos2dx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "spine-cocos2dx.h"; sourceTree = ""; }; + 1A40E7DE1727C47E006D4861 /* spine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = spine.h; sourceTree = ""; }; + 1A9CE9171765A2C2000E3062 /* CCBProxy.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBProxy.cpp; sourceTree = ""; }; + 1A9CE9181765A2C2000E3062 /* CCBProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBProxy.h; sourceTree = ""; }; + 1A9CE9191765A2C2000E3062 /* Lua_extensions_CCB.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Lua_extensions_CCB.cpp; sourceTree = ""; }; + 1A9CE91A1765A2C2000E3062 /* Lua_extensions_CCB.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Lua_extensions_CCB.h; sourceTree = ""; }; + 1A9CE91B1765A2C2000E3062 /* Lua_web_socket.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Lua_web_socket.cpp; sourceTree = ""; }; + 1A9CE91C1765A2C2000E3062 /* Lua_web_socket.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Lua_web_socket.h; sourceTree = ""; }; + 1A9D7E5D171E38B2000B3B9A /* lauxlib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lauxlib.h; sourceTree = ""; }; + 1A9D7E5E171E38B2000B3B9A /* lua.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lua.h; sourceTree = ""; }; + 1A9D7E5F171E38B2000B3B9A /* luaconf.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = luaconf.h; sourceTree = ""; }; + 1A9D7E60171E38B2000B3B9A /* lualib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lualib.h; sourceTree = ""; }; + 1A9D7E62171E38B2000B3B9A /* libluajit.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libluajit.a; sourceTree = ""; }; + 1AB87022175E0A2D005D39BF /* WebSocket.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebSocket.cpp; sourceTree = ""; }; + 1AB87023175E0A2D005D39BF /* WebSocket.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSocket.h; sourceTree = ""; }; + 1AB87025175E0A40005D39BF /* CCSkeleton.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSkeleton.cpp; sourceTree = ""; }; + 1AB87026175E0A40005D39BF /* CCSkeleton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSkeleton.h; sourceTree = ""; }; + 1AB87027175E0A40005D39BF /* CCSkeletonAnimation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSkeletonAnimation.cpp; sourceTree = ""; }; + 1AB87028175E0A40005D39BF /* CCSkeletonAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSkeletonAnimation.h; sourceTree = ""; }; + 1AB8702E175E0A5B005D39BF /* libwebsockets.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = libwebsockets.h; sourceTree = ""; }; + 1AB87030175E0A5B005D39BF /* libwebsockets.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libwebsockets.a; sourceTree = ""; }; + 1AC3622916D47C5C000847F2 /* fonts */ = {isa = PBXFileReference; lastKnownFileType = folder; name = fonts; path = ../Resources/fonts; sourceTree = ""; }; + 298B2A0518D0671400C1920F /* ButtonReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ButtonReader.cpp; sourceTree = ""; }; + 298B2A0618D0671400C1920F /* ButtonReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ButtonReader.h; sourceTree = ""; }; + 298B2A0818D0671400C1920F /* CheckBoxReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CheckBoxReader.cpp; sourceTree = ""; }; + 298B2A0918D0671400C1920F /* CheckBoxReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CheckBoxReader.h; sourceTree = ""; }; + 298B2A0B18D0671400C1920F /* ImageViewReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ImageViewReader.cpp; sourceTree = ""; }; + 298B2A0C18D0671400C1920F /* ImageViewReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ImageViewReader.h; sourceTree = ""; }; + 298B2A0E18D0671400C1920F /* LabelAtlasReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LabelAtlasReader.cpp; sourceTree = ""; }; + 298B2A0F18D0671400C1920F /* LabelAtlasReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LabelAtlasReader.h; sourceTree = ""; }; + 298B2A1118D0671400C1920F /* LabelBMFontReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LabelBMFontReader.cpp; sourceTree = ""; }; + 298B2A1218D0671400C1920F /* LabelBMFontReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LabelBMFontReader.h; sourceTree = ""; }; + 298B2A1418D0671400C1920F /* LabelReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LabelReader.cpp; sourceTree = ""; }; + 298B2A1518D0671400C1920F /* LabelReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LabelReader.h; sourceTree = ""; }; + 298B2A1718D0671400C1920F /* LayoutReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LayoutReader.cpp; sourceTree = ""; }; + 298B2A1818D0671400C1920F /* LayoutReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LayoutReader.h; sourceTree = ""; }; + 298B2A1A18D0671400C1920F /* ListViewReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ListViewReader.cpp; sourceTree = ""; }; + 298B2A1B18D0671400C1920F /* ListViewReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ListViewReader.h; sourceTree = ""; }; + 298B2A1D18D0671400C1920F /* LoadingBarReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LoadingBarReader.cpp; sourceTree = ""; }; + 298B2A1E18D0671400C1920F /* LoadingBarReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LoadingBarReader.h; sourceTree = ""; }; + 298B2A2018D0671400C1920F /* PageViewReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PageViewReader.cpp; sourceTree = ""; }; + 298B2A2118D0671400C1920F /* PageViewReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PageViewReader.h; sourceTree = ""; }; + 298B2A2318D0671400C1920F /* ScrollViewReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScrollViewReader.cpp; sourceTree = ""; }; + 298B2A2418D0671400C1920F /* ScrollViewReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScrollViewReader.h; sourceTree = ""; }; + 298B2A2618D0671400C1920F /* SliderReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SliderReader.cpp; sourceTree = ""; }; + 298B2A2718D0671400C1920F /* SliderReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SliderReader.h; sourceTree = ""; }; + 298B2A2918D0671400C1920F /* TextFieldReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TextFieldReader.cpp; sourceTree = ""; }; + 298B2A2A18D0671400C1920F /* TextFieldReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextFieldReader.h; sourceTree = ""; }; + 298B2A2B18D0671400C1920F /* WidgetReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WidgetReader.cpp; sourceTree = ""; }; + 298B2A2C18D0671400C1920F /* WidgetReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WidgetReader.h; sourceTree = ""; }; + 298B2A2D18D0671400C1920F /* WidgetReaderProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WidgetReaderProtocol.h; sourceTree = ""; }; + 373B91261878902900198F86 /* CCComBase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComBase.h; sourceTree = ""; }; + 373F99331869F07A0080E035 /* CCActionFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionFrame.cpp; sourceTree = ""; }; + 373F99341869F07A0080E035 /* CCActionFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionFrame.h; sourceTree = ""; }; + 373F99351869F07A0080E035 /* CCActionFrameEasing.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionFrameEasing.cpp; sourceTree = ""; }; + 373F99361869F07A0080E035 /* CCActionFrameEasing.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionFrameEasing.h; sourceTree = ""; }; + 373F99371869F07A0080E035 /* CCActionManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionManager.cpp; sourceTree = ""; }; + 373F99381869F07A0080E035 /* CCActionManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionManager.h; sourceTree = ""; }; + 373F99391869F07A0080E035 /* CCActionNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionNode.cpp; sourceTree = ""; }; + 373F993A1869F07A0080E035 /* CCActionNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionNode.h; sourceTree = ""; }; + 373F993B1869F07A0080E035 /* CCActionObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCActionObject.cpp; sourceTree = ""; }; + 373F993C1869F07A0080E035 /* CCActionObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCActionObject.h; sourceTree = ""; }; + 375BD557186846090024609E /* ObjectFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ObjectFactory.cpp; sourceTree = ""; }; + 375BD558186846090024609E /* ObjectFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectFactory.h; sourceTree = ""; }; + 375BD559186846090024609E /* TriggerBase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TriggerBase.cpp; sourceTree = ""; }; + 375BD55A186846090024609E /* TriggerBase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TriggerBase.h; sourceTree = ""; }; + 375BD55B186846090024609E /* TriggerMng.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TriggerMng.cpp; sourceTree = ""; }; + 375BD55C186846090024609E /* TriggerMng.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TriggerMng.h; sourceTree = ""; }; + 375BD55D186846090024609E /* TriggerObj.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TriggerObj.cpp; sourceTree = ""; }; + 375BD55E186846090024609E /* TriggerObj.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TriggerObj.h; sourceTree = ""; }; + 46C1007A16BF786A00F74D54 /* CCLuaBridge.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLuaBridge.cpp; sourceTree = ""; }; + 46C1007B16BF786A00F74D54 /* CCLuaBridge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLuaBridge.h; sourceTree = ""; }; + 46C1007C16BF786A00F74D54 /* CCLuaEngine.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLuaEngine.cpp; sourceTree = ""; }; + 46C1007D16BF786A00F74D54 /* CCLuaEngine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLuaEngine.h; sourceTree = ""; }; + 46C1007E16BF786A00F74D54 /* CCLuaStack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLuaStack.cpp; sourceTree = ""; }; + 46C1007F16BF786A00F74D54 /* CCLuaStack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLuaStack.h; sourceTree = ""; }; + 46C1008016BF786A00F74D54 /* CCLuaValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCLuaValue.cpp; sourceTree = ""; }; + 46C1008116BF786A00F74D54 /* CCLuaValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLuaValue.h; sourceTree = ""; }; + 46C1008216BF786A00F74D54 /* Cocos2dxLuaLoader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Cocos2dxLuaLoader.cpp; sourceTree = ""; }; + 46C1008316BF786A00F74D54 /* Cocos2dxLuaLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Cocos2dxLuaLoader.h; sourceTree = ""; }; + 46C1008416BF786A00F74D54 /* LuaCocos2d.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = LuaCocos2d.cpp; sourceTree = ""; }; + 46C1008516BF786A00F74D54 /* LuaCocos2d.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LuaCocos2d.h; sourceTree = ""; }; + 46C1008816BF786A00F74D54 /* CCLuaObjcBridge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCLuaObjcBridge.h; sourceTree = ""; }; + 46C1008916BF786A00F74D54 /* CCLuaObjcBridge.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCLuaObjcBridge.mm; sourceTree = ""; }; + 46C1008A16BF786A00F74D54 /* tolua_fix.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = tolua_fix.c; sourceTree = ""; }; + 46C1008B16BF786A00F74D54 /* tolua_fix.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tolua_fix.h; sourceTree = ""; }; + 46C59AD117641FF300F43DC3 /* AudioEngine.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = AudioEngine.lua; sourceTree = ""; }; + 46C59AD217641FF300F43DC3 /* CCBReaderLoad.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = CCBReaderLoad.lua; sourceTree = ""; }; + 8909856F18F253DE0021AE26 /* battle_msg_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = battle_msg_style1.tmx; sourceTree = ""; }; + 895EC07118F05AE600C3814D /* RPGData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGData.cpp; path = ../Classes/RPGData.cpp; sourceTree = ""; }; + 895EC07218F05AE600C3814D /* RPGData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGData.h; path = ../Classes/RPGData.h; sourceTree = ""; }; + 8960C17E18E7D0BD0075EF99 /* alert_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = alert_style1.tmx; sourceTree = ""; }; + 8960C18018E7D51C0075EF99 /* RPGConfirmLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGConfirmLayer.cpp; path = ../Classes/RPGConfirmLayer.cpp; sourceTree = ""; }; + 8960C18118E7D51C0075EF99 /* RPGConfirmLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGConfirmLayer.h; path = ../Classes/RPGConfirmLayer.h; sourceTree = ""; }; + 896BAEE318EF04CF006581FD /* audio_battle_end.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_battle_end.mp3; sourceTree = ""; }; + 896BAEE418EF04CF006581FD /* audio_battle_menu.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = audio_battle_menu.wav; sourceTree = ""; }; + 896BAEE518EF04CF006581FD /* audio_battle_start.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = audio_battle_start.wav; sourceTree = ""; }; + 8999051818F17A3D00012A0E /* RPGBattleMenu.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGBattleMenu.cpp; path = ../Classes/RPGBattleMenu.cpp; sourceTree = ""; }; + 8999051918F17A3D00012A0E /* RPGBattleMenu.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGBattleMenu.h; path = ../Classes/RPGBattleMenu.h; sourceTree = ""; }; + 8999051C18F17E6C00012A0E /* battle_battlemenu_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = battle_battlemenu_style1.tmx; sourceTree = ""; }; + 89CB7D7C18E9A47800A5921B /* map_menu1_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_menu1_style1.tmx; sourceTree = ""; }; + 89CB7D7D18E9A47800A5921B /* map_menu2_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_menu2_style1.tmx; sourceTree = ""; }; + 89CB7D7E18E9A47800A5921B /* map_menu3_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_menu3_style1.tmx; sourceTree = ""; }; + 89CB7D8718E9A87700A5921B /* dialog_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = dialog_style1.tmx; sourceTree = ""; }; + 89CB7D8918E9A8BF00A5921B /* RPGMapDialogLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGMapDialogLayer.cpp; path = ../Classes/RPGMapDialogLayer.cpp; sourceTree = ""; }; + 89CB7D8A18E9A8BF00A5921B /* RPGMapDialogLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGMapDialogLayer.h; path = ../Classes/RPGMapDialogLayer.h; sourceTree = ""; }; + 89E63C6B18ED83C900BDD04F /* actor5_0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor5_0.png; sourceTree = ""; }; + 89E63C6C18ED83C900BDD04F /* actor5_1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor5_1.png; sourceTree = ""; }; + 89E63C6D18ED83C900BDD04F /* actor5_2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor5_2.png; sourceTree = ""; }; + 89E63C6E18ED83C900BDD04F /* actor5_3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor5_3.png; sourceTree = ""; }; + 89E63C6F18ED83C900BDD04F /* actor5_4.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor5_4.png; sourceTree = ""; }; + 89E63C7018ED83C900BDD04F /* actor8_0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor8_0.png; sourceTree = ""; }; + 89E63C7118ED83C900BDD04F /* actor8_1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor8_1.png; sourceTree = ""; }; + 89E63C7218ED83C900BDD04F /* actor8_2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor8_2.png; sourceTree = ""; }; + 89E63C7318ED83C900BDD04F /* actor8_3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor8_3.png; sourceTree = ""; }; + 89E63C7418ED83C900BDD04F /* actor8_4.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor8_4.png; sourceTree = ""; }; + 89E63C7F18EDA9E200BDD04F /* RPGBattlePlayerSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGBattlePlayerSprite.cpp; path = ../Classes/RPGBattlePlayerSprite.cpp; sourceTree = ""; }; + 89E63C8018EDA9E200BDD04F /* RPGBattlePlayerSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGBattlePlayerSprite.h; path = ../Classes/RPGBattlePlayerSprite.h; sourceTree = ""; }; + 89EA57BC18EAF1EC00A10956 /* monsters.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = monsters.plist; sourceTree = ""; }; + 89EA57BD18EAF1EC00A10956 /* monsters.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = monsters.png; sourceTree = ""; }; + 89EA57C018EAF2CB00A10956 /* battle_bg.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = battle_bg.png; sourceTree = ""; }; + 89EA57CB18EB16F100A10956 /* Array.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Array.h; sourceTree = ""; }; + 89EA57CC18EB16F100A10956 /* Convert.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Convert.h; sourceTree = ""; }; + 89EA57CD18EB16F100A10956 /* Escaper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Escaper.h; sourceTree = ""; }; + 89EA57CE18EB16F100A10956 /* Grammar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Grammar.h; sourceTree = ""; }; + 89EA57CF18EB16F100A10956 /* IndentCanceller.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IndentCanceller.h; sourceTree = ""; }; + 89EA57D018EB16F100A10956 /* Indenter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Indenter.h; sourceTree = ""; }; + 89EA57D118EB16F100A10956 /* Object.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Object.h; sourceTree = ""; }; + 89EA57D218EB16F100A10956 /* OutputFilter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OutputFilter.h; sourceTree = ""; }; + 89EA57D318EB16F100A10956 /* SolidusEscaper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SolidusEscaper.h; sourceTree = ""; }; + 89EA57D418EB16F100A10956 /* Value.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Value.h; sourceTree = ""; }; + 89EA57D518EB16F100A10956 /* JsonBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JsonBox.h; sourceTree = ""; }; + 89EA57D718EB16F100A10956 /* Array.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Array.cpp; sourceTree = ""; }; + 89EA57D818EB16F100A10956 /* Convert.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Convert.cpp; sourceTree = ""; }; + 89EA57D918EB16F100A10956 /* Escaper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Escaper.cpp; sourceTree = ""; }; + 89EA57DA18EB16F100A10956 /* IndentCanceller.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IndentCanceller.cpp; sourceTree = ""; }; + 89EA57DB18EB16F100A10956 /* Indenter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Indenter.cpp; sourceTree = ""; }; + 89EA57DC18EB16F100A10956 /* Object.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Object.cpp; sourceTree = ""; }; + 89EA57DD18EB16F100A10956 /* SolidusEscaper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SolidusEscaper.cpp; sourceTree = ""; }; + 89EA57DE18EB16F100A10956 /* Value.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Value.cpp; sourceTree = ""; }; + 89F5D0BD18E7C579009D703C /* GameCfg.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GameCfg.h; path = ../Classes/GameCfg.h; sourceTree = ""; }; + 89F5D0BE18E7C579009D703C /* OzgCCScrollBgNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = OzgCCScrollBgNode.cpp; path = ../Classes/OzgCCScrollBgNode.cpp; sourceTree = ""; }; + 89F5D0BF18E7C579009D703C /* OzgCCScrollBgNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OzgCCScrollBgNode.h; path = ../Classes/OzgCCScrollBgNode.h; sourceTree = ""; }; + 89F5D0C018E7C579009D703C /* OzgCCUtility.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = OzgCCUtility.cpp; path = ../Classes/OzgCCUtility.cpp; sourceTree = ""; }; + 89F5D0C118E7C579009D703C /* OzgCCUtility.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OzgCCUtility.h; path = ../Classes/OzgCCUtility.h; sourceTree = ""; }; + 89F5D0C218E7C579009D703C /* OzgFileUtility.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = OzgFileUtility.cpp; path = ../Classes/OzgFileUtility.cpp; sourceTree = ""; }; + 89F5D0C318E7C579009D703C /* OzgFileUtility.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OzgFileUtility.h; path = ../Classes/OzgFileUtility.h; sourceTree = ""; }; + 89F5D0C418E7C579009D703C /* OzgJoystickLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = OzgJoystickLayer.cpp; path = ../Classes/OzgJoystickLayer.cpp; sourceTree = ""; }; + 89F5D0C518E7C579009D703C /* OzgJoystickLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OzgJoystickLayer.h; path = ../Classes/OzgJoystickLayer.h; sourceTree = ""; }; + 89F5D0C618E7C579009D703C /* RPGBaseSceneLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGBaseSceneLayer.cpp; path = ../Classes/RPGBaseSceneLayer.cpp; sourceTree = ""; }; + 89F5D0C718E7C579009D703C /* RPGBaseSceneLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGBaseSceneLayer.h; path = ../Classes/RPGBaseSceneLayer.h; sourceTree = ""; }; + 89F5D0C818E7C579009D703C /* RPGLoadingSceneLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGLoadingSceneLayer.cpp; path = ../Classes/RPGLoadingSceneLayer.cpp; sourceTree = ""; }; + 89F5D0C918E7C579009D703C /* RPGLoadingSceneLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGLoadingSceneLayer.h; path = ../Classes/RPGLoadingSceneLayer.h; sourceTree = ""; }; + 89F5D0CA18E7C579009D703C /* RPGMapMenuLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGMapMenuLayer.cpp; path = ../Classes/RPGMapMenuLayer.cpp; sourceTree = ""; }; + 89F5D0CB18E7C579009D703C /* RPGMapMenuLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGMapMenuLayer.h; path = ../Classes/RPGMapMenuLayer.h; sourceTree = ""; }; + 89F5D0CC18E7C579009D703C /* RPGMapNPCRoleSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGMapNPCRoleSprite.cpp; path = ../Classes/RPGMapNPCRoleSprite.cpp; sourceTree = ""; }; + 89F5D0CD18E7C579009D703C /* RPGMapNPCRoleSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGMapNPCRoleSprite.h; path = ../Classes/RPGMapNPCRoleSprite.h; sourceTree = ""; }; + 89F5D0CE18E7C579009D703C /* RPGMapRoleSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGMapRoleSprite.cpp; path = ../Classes/RPGMapRoleSprite.cpp; sourceTree = ""; }; + 89F5D0CF18E7C579009D703C /* RPGMapRoleSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGMapRoleSprite.h; path = ../Classes/RPGMapRoleSprite.h; sourceTree = ""; }; + 89F5D0D418E7C579009D703C /* RPGBattleSceneLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGBattleSceneLayer.cpp; path = ../Classes/RPGBattleSceneLayer.cpp; sourceTree = ""; }; + 89F5D0D518E7C579009D703C /* RPGBattleSceneLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGBattleSceneLayer.h; path = ../Classes/RPGBattleSceneLayer.h; sourceTree = ""; }; + 89F5D0D618E7C579009D703C /* RPGMapSceneLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGMapSceneLayer.cpp; path = ../Classes/RPGMapSceneLayer.cpp; sourceTree = ""; }; + 89F5D0D718E7C579009D703C /* RPGMapSceneLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGMapSceneLayer.h; path = ../Classes/RPGMapSceneLayer.h; sourceTree = ""; }; + 89F5D0D818E7C579009D703C /* RPGStartSceneLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGStartSceneLayer.cpp; path = ../Classes/RPGStartSceneLayer.cpp; sourceTree = ""; }; + 89F5D0D918E7C579009D703C /* RPGStartSceneLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGStartSceneLayer.h; path = ../Classes/RPGStartSceneLayer.h; sourceTree = ""; }; + 89F5D0E818E7C59D009D703C /* libsqlite3.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libsqlite3.dylib; path = usr/lib/libsqlite3.dylib; sourceTree = SDKROOT; }; + 89F5D0EA18E7C5B4009D703C /* 方正粗圆简体.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "方正粗圆简体.ttf"; sourceTree = ""; }; + 89F5D0EC18E7C5C0009D703C /* actor4_0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor4_0.png; sourceTree = ""; }; + 89F5D0ED18E7C5C0009D703C /* actor4_1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor4_1.png; sourceTree = ""; }; + 89F5D0EE18E7C5C0009D703C /* actor4_2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor4_2.png; sourceTree = ""; }; + 89F5D0EF18E7C5C0009D703C /* actor4_3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor4_3.png; sourceTree = ""; }; + 89F5D0F018E7C5C0009D703C /* actor4_4.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor4_4.png; sourceTree = ""; }; + 89F5D0F118E7C5C0009D703C /* actor7_0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor7_0.png; sourceTree = ""; }; + 89F5D0F218E7C5C0009D703C /* actor7_1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor7_1.png; sourceTree = ""; }; + 89F5D0F318E7C5C0009D703C /* actor7_2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor7_2.png; sourceTree = ""; }; + 89F5D0F418E7C5C0009D703C /* actor7_3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor7_3.png; sourceTree = ""; }; + 89F5D0F518E7C5C0009D703C /* actor7_4.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor7_4.png; sourceTree = ""; }; + 89F5D10018E7C5C0009D703C /* actor111.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor111.png; sourceTree = ""; }; + 89F5D10118E7C5C0009D703C /* actor113.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor113.png; sourceTree = ""; }; + 89F5D10218E7C5C0009D703C /* actor114.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor114.png; sourceTree = ""; }; + 89F5D10318E7C5C0009D703C /* actor115.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor115.png; sourceTree = ""; }; + 89F5D10418E7C5C0009D703C /* actor117.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor117.png; sourceTree = ""; }; + 89F5D10518E7C5C0009D703C /* actor120.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = actor120.png; sourceTree = ""; }; + 89F5D12018E7C5CC009D703C /* audio_battle.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_battle.mp3; sourceTree = ""; }; + 89F5D12118E7C5CC009D703C /* audio_effect_btn.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = audio_effect_btn.wav; sourceTree = ""; }; + 89F5D12218E7C5CC009D703C /* audio_map_01.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_map_01.mp3; sourceTree = ""; }; + 89F5D12318E7C5CC009D703C /* audio_map_02.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_map_02.mp3; sourceTree = ""; }; + 89F5D12418E7C5CC009D703C /* audio_map_03.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_map_03.mp3; sourceTree = ""; }; + 89F5D12518E7C5CC009D703C /* audio_start.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; path = audio_start.mp3; sourceTree = ""; }; + 89F5D12C18E7C5DD009D703C /* joystick.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = joystick.plist; sourceTree = ""; }; + 89F5D12D18E7C5DD009D703C /* joystick.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = joystick.png; sourceTree = ""; }; + 89F5D12E18E7C5DD009D703C /* main.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = main.plist; sourceTree = ""; }; + 89F5D12F18E7C5DD009D703C /* main.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = main.png; sourceTree = ""; }; + 89F5D13018E7C5DD009D703C /* map_01.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_01.tmx; sourceTree = ""; }; + 89F5D13118E7C5DD009D703C /* map_02.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_02.tmx; sourceTree = ""; }; + 89F5D13218E7C5DD009D703C /* map_03.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_03.tmx; sourceTree = ""; }; + 89F5D13618E7C5DD009D703C /* map.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = map.png; sourceTree = ""; }; + 89F5D13718E7C5DD009D703C /* scene_battle_cns.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = scene_battle_cns.plist; sourceTree = ""; }; + 89F5D13818E7C5DD009D703C /* scene_loading_cns.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = scene_loading_cns.plist; sourceTree = ""; }; + 89F5D13918E7C5DD009D703C /* scene_map_cns.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = scene_map_cns.plist; sourceTree = ""; }; + 89F5D13A18E7C5DD009D703C /* scene_start_cns.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = scene_start_cns.plist; sourceTree = ""; }; + 89F5D13B18E7C5DD009D703C /* start_bg.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = start_bg.png; sourceTree = ""; }; + 89F5D13C18E7C5DD009D703C /* Window_b_00.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Window_b_00.png; sourceTree = ""; }; + 89F5D14E18E7C5E5009D703C /* db.sys */ = {isa = PBXFileReference; lastKnownFileType = file; path = db.sys; sourceTree = ""; }; + 89F5D15118E7C70F009D703C /* CppSQLite3.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CppSQLite3.cpp; sourceTree = ""; }; + 89F5D15218E7C70F009D703C /* CppSQLite3.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CppSQLite3.h; sourceTree = ""; }; + 9E427D0418EBBA9F00DA4E79 /* map_menu4_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = map_menu4_style1.tmx; sourceTree = ""; }; + 9E5C5F6D18EE59BB00A68C36 /* battle_menu_style1.tmx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = battle_menu_style1.tmx; sourceTree = ""; }; + 9E5C5F6F18EE68BD00A68C36 /* RPGBattleMonsterSprite.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RPGBattleMonsterSprite.cpp; path = ../Classes/RPGBattleMonsterSprite.cpp; sourceTree = ""; }; + 9E5C5F7018EE68BD00A68C36 /* RPGBattleMonsterSprite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RPGBattleMonsterSprite.h; path = ../Classes/RPGBattleMonsterSprite.h; sourceTree = ""; }; + ED35C03818323497002A0750 /* CCArmatureAnimation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCArmatureAnimation.cpp; sourceTree = ""; }; + ED35C03918323497002A0750 /* CCArmatureAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCArmatureAnimation.h; sourceTree = ""; }; + ED35C03A18323497002A0750 /* CCProcessBase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCProcessBase.cpp; sourceTree = ""; }; + ED35C03B18323497002A0750 /* CCProcessBase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCProcessBase.h; sourceTree = ""; }; + ED35C03C18323497002A0750 /* CCTween.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTween.cpp; sourceTree = ""; }; + ED35C03D18323497002A0750 /* CCTween.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTween.h; sourceTree = ""; }; + ED35C03E18323497002A0750 /* CCArmature.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCArmature.cpp; sourceTree = ""; }; + ED35C03F18323497002A0750 /* CCArmature.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCArmature.h; sourceTree = ""; }; + ED35C04018323497002A0750 /* CCBone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBone.cpp; sourceTree = ""; }; + ED35C04118323497002A0750 /* CCBone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBone.h; sourceTree = ""; }; + ED35C04318323497002A0750 /* CCDatas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDatas.cpp; sourceTree = ""; }; + ED35C04418323497002A0750 /* CCDatas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDatas.h; sourceTree = ""; }; + ED35C04618323497002A0750 /* CCBatchNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCBatchNode.cpp; sourceTree = ""; }; + ED35C04718323497002A0750 /* CCBatchNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCBatchNode.h; sourceTree = ""; }; + ED35C04818323497002A0750 /* CCDecorativeDisplay.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDecorativeDisplay.cpp; sourceTree = ""; }; + ED35C04918323497002A0750 /* CCDecorativeDisplay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDecorativeDisplay.h; sourceTree = ""; }; + ED35C04A18323497002A0750 /* CCDisplayFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDisplayFactory.cpp; sourceTree = ""; }; + ED35C04B18323497002A0750 /* CCDisplayFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDisplayFactory.h; sourceTree = ""; }; + ED35C04C18323497002A0750 /* CCDisplayManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDisplayManager.cpp; sourceTree = ""; }; + ED35C04D18323497002A0750 /* CCDisplayManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDisplayManager.h; sourceTree = ""; }; + ED35C04E18323497002A0750 /* CCSkin.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSkin.cpp; sourceTree = ""; }; + ED35C04F18323497002A0750 /* CCSkin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSkin.h; sourceTree = ""; }; + ED35C05118323497002A0750 /* sigslot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sigslot.h; sourceTree = ""; }; + ED35C05318323497002A0750 /* CCColliderDetector.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCColliderDetector.cpp; sourceTree = ""; }; + ED35C05418323497002A0750 /* CCColliderDetector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCColliderDetector.h; sourceTree = ""; }; + ED35C05618323497002A0750 /* CCArmatureDataManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCArmatureDataManager.cpp; sourceTree = ""; }; + ED35C05718323497002A0750 /* CCArmatureDataManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCArmatureDataManager.h; sourceTree = ""; }; + ED35C05818323497002A0750 /* CCArmatureDefine.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCArmatureDefine.cpp; sourceTree = ""; }; + ED35C05918323497002A0750 /* CCArmatureDefine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCArmatureDefine.h; sourceTree = ""; }; + ED35C05A18323497002A0750 /* CCDataReaderHelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCDataReaderHelper.cpp; sourceTree = ""; }; + ED35C05B18323497002A0750 /* CCDataReaderHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDataReaderHelper.h; sourceTree = ""; }; + ED35C05C18323497002A0750 /* CCSpriteFrameCacheHelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCSpriteFrameCacheHelper.cpp; sourceTree = ""; }; + ED35C05D18323497002A0750 /* CCSpriteFrameCacheHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCSpriteFrameCacheHelper.h; sourceTree = ""; }; + ED35C05E18323497002A0750 /* CCTransformHelp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTransformHelp.cpp; sourceTree = ""; }; + ED35C05F18323497002A0750 /* CCTransformHelp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTransformHelp.h; sourceTree = ""; }; + ED35C06018323497002A0750 /* CCTweenFunction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCTweenFunction.cpp; sourceTree = ""; }; + ED35C06118323497002A0750 /* CCTweenFunction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCTweenFunction.h; sourceTree = ""; }; + ED35C06218323497002A0750 /* CCUtilMath.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCUtilMath.cpp; sourceTree = ""; }; + ED35C06318323497002A0750 /* CCUtilMath.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUtilMath.h; sourceTree = ""; }; + ED35C06518323497002A0750 /* CCComAttribute.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComAttribute.cpp; sourceTree = ""; }; + ED35C06618323497002A0750 /* CCComAttribute.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComAttribute.h; sourceTree = ""; }; + ED35C06718323497002A0750 /* CCComAudio.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComAudio.cpp; sourceTree = ""; }; + ED35C06818323497002A0750 /* CCComAudio.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComAudio.h; sourceTree = ""; }; + ED35C06918323497002A0750 /* CCComController.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComController.cpp; sourceTree = ""; }; + ED35C06A18323497002A0750 /* CCComController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComController.h; sourceTree = ""; }; + ED35C06B18323497002A0750 /* CCComRender.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCComRender.cpp; sourceTree = ""; }; + ED35C06C18323497002A0750 /* CCComRender.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCComRender.h; sourceTree = ""; }; + ED35C06D18323497002A0750 /* CCInputDelegate.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCInputDelegate.cpp; sourceTree = ""; }; + ED35C06E18323497002A0750 /* CCInputDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCInputDelegate.h; sourceTree = ""; }; + ED35C07318323497002A0750 /* UIWidget.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIWidget.cpp; sourceTree = ""; }; + ED35C07418323497002A0750 /* UIWidget.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWidget.h; sourceTree = ""; }; + ED35C07618323497002A0750 /* UILayout.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILayout.cpp; sourceTree = ""; }; + ED35C07718323497002A0750 /* UILayout.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILayout.h; sourceTree = ""; }; + ED35C07818323497002A0750 /* UILayoutDefine.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILayoutDefine.cpp; sourceTree = ""; }; + ED35C07918323497002A0750 /* UILayoutDefine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILayoutDefine.h; sourceTree = ""; }; + ED35C07A18323497002A0750 /* UILayoutParameter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILayoutParameter.cpp; sourceTree = ""; }; + ED35C07B18323497002A0750 /* UILayoutParameter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILayoutParameter.h; sourceTree = ""; }; + ED35C07D18323497002A0750 /* CocosGUI.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CocosGUI.cpp; sourceTree = ""; }; + ED35C07E18323497002A0750 /* CocosGUI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CocosGUI.h; sourceTree = ""; }; + ED35C07F18323497002A0750 /* UIHelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIHelper.cpp; sourceTree = ""; }; + ED35C08018323497002A0750 /* UIHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIHelper.h; sourceTree = ""; }; + ED35C09218323497002A0750 /* UIButton.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIButton.cpp; sourceTree = ""; }; + ED35C09318323498002A0750 /* UIButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIButton.h; sourceTree = ""; }; + ED35C09418323498002A0750 /* UICheckBox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UICheckBox.cpp; sourceTree = ""; }; + ED35C09518323498002A0750 /* UICheckBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UICheckBox.h; sourceTree = ""; }; + ED35C09618323498002A0750 /* UIImageView.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIImageView.cpp; sourceTree = ""; }; + ED35C09718323498002A0750 /* UIImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIImageView.h; sourceTree = ""; }; + ED35C09818323498002A0750 /* UILabel.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILabel.cpp; sourceTree = ""; }; + ED35C09918323498002A0750 /* UILabel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILabel.h; sourceTree = ""; }; + ED35C09A18323498002A0750 /* UILabelAtlas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILabelAtlas.cpp; sourceTree = ""; }; + ED35C09B18323498002A0750 /* UILabelAtlas.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILabelAtlas.h; sourceTree = ""; }; + ED35C09C18323498002A0750 /* UILabelBMFont.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILabelBMFont.cpp; sourceTree = ""; }; + ED35C09D18323498002A0750 /* UILabelBMFont.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILabelBMFont.h; sourceTree = ""; }; + ED35C09E18323498002A0750 /* UILoadingBar.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UILoadingBar.cpp; sourceTree = ""; }; + ED35C09F18323498002A0750 /* UILoadingBar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UILoadingBar.h; sourceTree = ""; }; + ED35C0A018323498002A0750 /* UISlider.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UISlider.cpp; sourceTree = ""; }; + ED35C0A118323498002A0750 /* UISlider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UISlider.h; sourceTree = ""; }; + ED35C0A418323498002A0750 /* UITextField.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UITextField.cpp; sourceTree = ""; }; + ED35C0A518323498002A0750 /* UITextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UITextField.h; sourceTree = ""; }; + ED35C0A918323498002A0750 /* DictionaryHelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DictionaryHelper.cpp; sourceTree = ""; }; + ED35C0AA18323498002A0750 /* DictionaryHelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DictionaryHelper.h; sourceTree = ""; }; + ED35C0BE18323498002A0750 /* GUIReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GUIReader.cpp; sourceTree = ""; }; + ED35C0BF18323498002A0750 /* GUIReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GUIReader.h; sourceTree = ""; }; + ED35C0C018323498002A0750 /* SceneReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SceneReader.cpp; sourceTree = ""; }; + ED35C0C118323498002A0750 /* SceneReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SceneReader.h; sourceTree = ""; }; + F293B3C815EB7BE500256477 /* OzgGameRPG.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = OzgGameRPG.app; sourceTree = BUILT_PRODUCTS_DIR; }; + F293B3CC15EB7BE500256477 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; + F293B3CE15EB7BE500256477 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; }; + F293B3D015EB7BE500256477 /* OpenAL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenAL.framework; path = System/Library/Frameworks/OpenAL.framework; sourceTree = SDKROOT; }; + F293B3D215EB7BE500256477 /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; }; + F293B3D415EB7BE500256477 /* AVFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AVFoundation.framework; path = System/Library/Frameworks/AVFoundation.framework; sourceTree = SDKROOT; }; + F293B3D615EB7BE500256477 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; + F293B3D815EB7BE500256477 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; + F293B3DA15EB7BE500256477 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; + F293B6F615EB823D00256477 /* AppController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppController.h; sourceTree = ""; }; + F293B6F715EB823D00256477 /* AppController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AppController.mm; sourceTree = ""; }; + F293B6F815EB823D00256477 /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + F293B6F915EB823D00256477 /* RootViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RootViewController.h; sourceTree = ""; }; + F293B6FA15EB823D00256477 /* RootViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RootViewController.mm; sourceTree = ""; }; + F293B6FB15EB823D00256477 /* OzgGameRPG_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OzgGameRPG_Prefix.pch; sourceTree = ""; }; + F293BB7E15EB831F00256477 /* AppDelegate.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = AppDelegate.cpp; path = ../Classes/AppDelegate.cpp; sourceTree = ""; }; + F293BB7F15EB831F00256477 /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = ../Classes/AppDelegate.h; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + F293B3C515EB7BE500256477 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 89F5D0E918E7C59D009D703C /* libsqlite3.dylib in Frameworks */, + 15C1568E1683131500D239F2 /* libcurl.a in Frameworks */, + 15C1568C168311EC00D239F2 /* libcocos2dx.a in Frameworks */, + F293B3CD15EB7BE500256477 /* QuartzCore.framework in Frameworks */, + F293B3CF15EB7BE500256477 /* OpenGLES.framework in Frameworks */, + F293B3D115EB7BE500256477 /* OpenAL.framework in Frameworks */, + F293B3D315EB7BE500256477 /* AudioToolbox.framework in Frameworks */, + F293B3D515EB7BE500256477 /* AVFoundation.framework in Frameworks */, + F293B3D715EB7BE500256477 /* UIKit.framework in Frameworks */, + F293B3D915EB7BE500256477 /* Foundation.framework in Frameworks */, + F293B3DB15EB7BE500256477 /* CoreGraphics.framework in Frameworks */, + 1A9D7E63171E38B2000B3B9A /* libluajit.a in Frameworks */, + 1AB87031175E0A5B005D39BF /* libwebsockets.a in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 1583F15B18D09FF900F3D630 /* Compatible */ = { + isa = PBXGroup; + children = ( + 1583F15C18D09FF900F3D630 /* CompatibleClasses.h */, + ); + path = Compatible; + sourceTree = ""; + }; + 1583F15D18D09FF900F3D630 /* ScrollWidget */ = { + isa = PBXGroup; + children = ( + 1583F15E18D09FF900F3D630 /* UIListView.cpp */, + 1583F15F18D09FF900F3D630 /* UIListView.h */, + 1583F16018D09FF900F3D630 /* UIPageView.cpp */, + 1583F16118D09FF900F3D630 /* UIPageView.h */, + 1583F16218D09FF900F3D630 /* UIScrollInterface.h */, + 1583F16318D09FF900F3D630 /* UIScrollView.cpp */, + 1583F16418D09FF900F3D630 /* UIScrollView.h */, + ); + path = ScrollWidget; + sourceTree = ""; + }; + 15C1533F168310C700D239F2 /* Products */ = { + isa = PBXGroup; + children = ( + 15C15346168310C700D239F2 /* libcocos2dx.a */, + ); + name = Products; + sourceTree = ""; + }; + 15C153791683112E00D239F2 /* extensions */ = { + isa = PBXGroup; + children = ( + ED35C02A18323496002A0750 /* CocoStudio */, + 15C1537B1683112E00D239F2 /* CCBReader */, + 15C153B01683112E00D239F2 /* cocos-ext.h */, + 15C153B11683112E00D239F2 /* ExtensionMacros.h */, + 15C153B21683112E00D239F2 /* GUI */, + 15C153E01683112E00D239F2 /* network */, + 15C153E51683112E00D239F2 /* physics_nodes */, + 1A40E7B71727C47D006D4861 /* spine */, + ); + name = extensions; + path = ../../../extensions; + sourceTree = ""; + }; + 15C1537B1683112E00D239F2 /* CCBReader */ = { + isa = PBXGroup; + children = ( + 15C1537C1683112E00D239F2 /* CCBAnimationManager.cpp */, + 15C1537D1683112E00D239F2 /* CCBAnimationManager.h */, + 15C1537E1683112E00D239F2 /* CCBFileLoader.cpp */, + 15C1537F1683112E00D239F2 /* CCBFileLoader.h */, + 15C153801683112E00D239F2 /* CCBKeyframe.cpp */, + 15C153811683112E00D239F2 /* CCBKeyframe.h */, + 15C153821683112E00D239F2 /* CCBMemberVariableAssigner.h */, + 15C153831683112E00D239F2 /* CCBReader.cpp */, + 15C153841683112E00D239F2 /* CCBReader.h */, + 15C153851683112E00D239F2 /* CCBSelectorResolver.h */, + 15C153861683112E00D239F2 /* CCBSequence.cpp */, + 15C153871683112E00D239F2 /* CCBSequence.h */, + 15C153881683112E00D239F2 /* CCBSequenceProperty.cpp */, + 15C153891683112E00D239F2 /* CCBSequenceProperty.h */, + 15C1538A1683112E00D239F2 /* CCBValue.cpp */, + 15C1538B1683112E00D239F2 /* CCBValue.h */, + 15C1538C1683112E00D239F2 /* CCControlButtonLoader.cpp */, + 15C1538D1683112E00D239F2 /* CCControlButtonLoader.h */, + 15C1538E1683112E00D239F2 /* CCControlLoader.cpp */, + 15C1538F1683112E00D239F2 /* CCControlLoader.h */, + 15C153901683112E00D239F2 /* CCData.cpp */, + 15C153911683112E00D239F2 /* CCData.h */, + 15C153921683112E00D239F2 /* CCLabelBMFontLoader.cpp */, + 15C153931683112E00D239F2 /* CCLabelBMFontLoader.h */, + 15C153941683112E00D239F2 /* CCLabelTTFLoader.cpp */, + 15C153951683112E00D239F2 /* CCLabelTTFLoader.h */, + 15C153961683112E00D239F2 /* CCLayerColorLoader.cpp */, + 15C153971683112E00D239F2 /* CCLayerColorLoader.h */, + 15C153981683112E00D239F2 /* CCLayerGradientLoader.cpp */, + 15C153991683112E00D239F2 /* CCLayerGradientLoader.h */, + 15C1539A1683112E00D239F2 /* CCLayerLoader.cpp */, + 15C1539B1683112E00D239F2 /* CCLayerLoader.h */, + 15C1539C1683112E00D239F2 /* CCMenuItemImageLoader.cpp */, + 15C1539D1683112E00D239F2 /* CCMenuItemImageLoader.h */, + 15C1539E1683112E00D239F2 /* CCMenuItemLoader.cpp */, + 15C1539F1683112E00D239F2 /* CCMenuItemLoader.h */, + 15C153A01683112E00D239F2 /* CCMenuLoader.h */, + 15C153A11683112E00D239F2 /* CCNode+CCBRelativePositioning.cpp */, + 15C153A21683112E00D239F2 /* CCNode+CCBRelativePositioning.h */, + 15C153A31683112E00D239F2 /* CCNodeLoader.cpp */, + 15C153A41683112E00D239F2 /* CCNodeLoader.h */, + 15C153A51683112E00D239F2 /* CCNodeLoaderLibrary.cpp */, + 15C153A61683112E00D239F2 /* CCNodeLoaderLibrary.h */, + 15C153A71683112E00D239F2 /* CCNodeLoaderListener.h */, + 15C153A81683112E00D239F2 /* CCParticleSystemQuadLoader.cpp */, + 15C153A91683112E00D239F2 /* CCParticleSystemQuadLoader.h */, + 15C153AA1683112E00D239F2 /* CCScale9SpriteLoader.cpp */, + 15C153AB1683112E00D239F2 /* CCScale9SpriteLoader.h */, + 15C153AC1683112E00D239F2 /* CCScrollViewLoader.cpp */, + 15C153AD1683112E00D239F2 /* CCScrollViewLoader.h */, + 15C153AE1683112E00D239F2 /* CCSpriteLoader.cpp */, + 15C153AF1683112E00D239F2 /* CCSpriteLoader.h */, + ); + path = CCBReader; + sourceTree = ""; + }; + 15C153B21683112E00D239F2 /* GUI */ = { + isa = PBXGroup; + children = ( + 15C153B31683112E00D239F2 /* CCControlExtension */, + 15C153CD1683112E00D239F2 /* CCEditBox */, + 15C153D71683112E00D239F2 /* CCScrollView */, + ); + path = GUI; + sourceTree = ""; + }; + 15C153B31683112E00D239F2 /* CCControlExtension */ = { + isa = PBXGroup; + children = ( + 15C153B41683112E00D239F2 /* CCControl.cpp */, + 15C153B51683112E00D239F2 /* CCControl.h */, + 15C153B61683112E00D239F2 /* CCControlButton.cpp */, + 15C153B71683112E00D239F2 /* CCControlButton.h */, + 15C153B81683112E00D239F2 /* CCControlColourPicker.cpp */, + 15C153B91683112E00D239F2 /* CCControlColourPicker.h */, + 15C153BA1683112E00D239F2 /* CCControlExtensions.h */, + 15C153BB1683112E00D239F2 /* CCControlHuePicker.cpp */, + 15C153BC1683112E00D239F2 /* CCControlHuePicker.h */, + 15C153BD1683112E00D239F2 /* CCControlPotentiometer.cpp */, + 15C153BE1683112E00D239F2 /* CCControlPotentiometer.h */, + 15C153BF1683112E00D239F2 /* CCControlSaturationBrightnessPicker.cpp */, + 15C153C01683112E00D239F2 /* CCControlSaturationBrightnessPicker.h */, + 15C153C11683112E00D239F2 /* CCControlSlider.cpp */, + 15C153C21683112E00D239F2 /* CCControlSlider.h */, + 15C153C31683112E00D239F2 /* CCControlStepper.cpp */, + 15C153C41683112E00D239F2 /* CCControlStepper.h */, + 15C153C51683112E00D239F2 /* CCControlSwitch.cpp */, + 15C153C61683112E00D239F2 /* CCControlSwitch.h */, + 15C153C71683112E00D239F2 /* CCControlUtils.cpp */, + 15C153C81683112E00D239F2 /* CCControlUtils.h */, + 15C153C91683112E00D239F2 /* CCInvocation.cpp */, + 15C153CA1683112E00D239F2 /* CCInvocation.h */, + 15C153CB1683112E00D239F2 /* CCScale9Sprite.cpp */, + 15C153CC1683112E00D239F2 /* CCScale9Sprite.h */, + ); + path = CCControlExtension; + sourceTree = ""; + }; + 15C153CD1683112E00D239F2 /* CCEditBox */ = { + isa = PBXGroup; + children = ( + 15C153CE1683112E00D239F2 /* CCEditBox.cpp */, + 15C153CF1683112E00D239F2 /* CCEditBox.h */, + 15C153D01683112E00D239F2 /* CCEditBoxImpl.h */, + 15C153D31683112E00D239F2 /* CCEditBoxImplIOS.h */, + 15C153D41683112E00D239F2 /* CCEditBoxImplIOS.mm */, + ); + path = CCEditBox; + sourceTree = ""; + }; + 15C153D71683112E00D239F2 /* CCScrollView */ = { + isa = PBXGroup; + children = ( + 15C153D81683112E00D239F2 /* CCScrollView.cpp */, + 15C153D91683112E00D239F2 /* CCScrollView.h */, + 15C153DA1683112E00D239F2 /* CCSorting.cpp */, + 15C153DB1683112E00D239F2 /* CCSorting.h */, + 15C153DC1683112E00D239F2 /* CCTableView.cpp */, + 15C153DD1683112E00D239F2 /* CCTableView.h */, + 15C153DE1683112E00D239F2 /* CCTableViewCell.cpp */, + 15C153DF1683112E00D239F2 /* CCTableViewCell.h */, + ); + path = CCScrollView; + sourceTree = ""; + }; + 15C153E01683112E00D239F2 /* network */ = { + isa = PBXGroup; + children = ( + 15C153E11683112E00D239F2 /* HttpClient.cpp */, + 15C153E21683112E00D239F2 /* HttpClient.h */, + 15C153E31683112E00D239F2 /* HttpRequest.h */, + 15C153E41683112E00D239F2 /* HttpResponse.h */, + 1AB87022175E0A2D005D39BF /* WebSocket.cpp */, + 1AB87023175E0A2D005D39BF /* WebSocket.h */, + ); + path = network; + sourceTree = ""; + }; + 15C153E51683112E00D239F2 /* physics_nodes */ = { + isa = PBXGroup; + children = ( + 15C153E61683112E00D239F2 /* CCPhysicsDebugNode.cpp */, + 15C153E71683112E00D239F2 /* CCPhysicsDebugNode.h */, + 15C153E81683112E00D239F2 /* CCPhysicsSprite.cpp */, + 15C153E91683112E00D239F2 /* CCPhysicsSprite.h */, + ); + path = physics_nodes; + sourceTree = ""; + }; + 15C1542E1683116B00D239F2 /* chipmunk */ = { + isa = PBXGroup; + children = ( + 15C154321683116B00D239F2 /* include */, + 15C1545B1683116B00D239F2 /* src */, + ); + name = chipmunk; + path = ../../../external/chipmunk; + sourceTree = ""; + }; + 15C154321683116B00D239F2 /* include */ = { + isa = PBXGroup; + children = ( + 15C154331683116B00D239F2 /* chipmunk */, + ); + path = include; + sourceTree = ""; + }; + 15C154331683116B00D239F2 /* chipmunk */ = { + isa = PBXGroup; + children = ( + 15C154341683116B00D239F2 /* chipmunk.h */, + 15C154351683116B00D239F2 /* chipmunk_ffi.h */, + 15C154361683116B00D239F2 /* chipmunk_private.h */, + 15C154371683116B00D239F2 /* chipmunk_types.h */, + 15C154381683116B00D239F2 /* chipmunk_unsafe.h */, + 15C154391683116B00D239F2 /* constraints */, + 15C154461683116B00D239F2 /* cpArbiter.h */, + 15C154471683116B00D239F2 /* cpBB.h */, + 15C154481683116B00D239F2 /* cpBody.h */, + 15C154491683116B00D239F2 /* cpPolyShape.h */, + 15C1544A1683116B00D239F2 /* cpShape.h */, + 15C1544B1683116B00D239F2 /* cpSpace.h */, + 15C1544C1683116B00D239F2 /* cpSpatialIndex.h */, + 15C1544D1683116B00D239F2 /* cpVect.h */, + ); + path = chipmunk; + sourceTree = ""; + }; + 15C154391683116B00D239F2 /* constraints */ = { + isa = PBXGroup; + children = ( + 15C1543A1683116B00D239F2 /* cpConstraint.h */, + 15C1543B1683116B00D239F2 /* cpDampedRotarySpring.h */, + 15C1543C1683116B00D239F2 /* cpDampedSpring.h */, + 15C1543D1683116B00D239F2 /* cpGearJoint.h */, + 15C1543E1683116B00D239F2 /* cpGrooveJoint.h */, + 15C1543F1683116B00D239F2 /* cpPinJoint.h */, + 15C154401683116B00D239F2 /* cpPivotJoint.h */, + 15C154411683116B00D239F2 /* cpRatchetJoint.h */, + 15C154421683116B00D239F2 /* cpRotaryLimitJoint.h */, + 15C154431683116B00D239F2 /* cpSimpleMotor.h */, + 15C154441683116B00D239F2 /* cpSlideJoint.h */, + 15C154451683116B00D239F2 /* util.h */, + ); + path = constraints; + sourceTree = ""; + }; + 15C1545B1683116B00D239F2 /* src */ = { + isa = PBXGroup; + children = ( + 15C1545C1683116B00D239F2 /* chipmunk.c */, + 15C1545D1683116B00D239F2 /* CMakeLists.txt */, + 15C1545E1683116B00D239F2 /* constraints */, + 15C1546A1683116B00D239F2 /* cpArbiter.c */, + 15C1546B1683116B00D239F2 /* cpArray.c */, + 15C1546C1683116B00D239F2 /* cpBB.c */, + 15C1546D1683116B00D239F2 /* cpBBTree.c */, + 15C1546E1683116B00D239F2 /* cpBody.c */, + 15C1546F1683116B00D239F2 /* cpCollision.c */, + 15C154701683116B00D239F2 /* cpHashSet.c */, + 15C154711683116B00D239F2 /* cpPolyShape.c */, + 15C154721683116B00D239F2 /* cpShape.c */, + 15C154731683116B00D239F2 /* cpSpace.c */, + 15C154741683116B00D239F2 /* cpSpaceComponent.c */, + 15C154751683116B00D239F2 /* cpSpaceHash.c */, + 15C154761683116B00D239F2 /* cpSpaceQuery.c */, + 15C154771683116B00D239F2 /* cpSpaceStep.c */, + 15C154781683116B00D239F2 /* cpSpatialIndex.c */, + 15C154791683116B00D239F2 /* cpSweep1D.c */, + 15C1547A1683116B00D239F2 /* cpVect.c */, + 15C1547B1683116B00D239F2 /* prime.h */, + ); + path = src; + sourceTree = ""; + }; + 15C1545E1683116B00D239F2 /* constraints */ = { + isa = PBXGroup; + children = ( + 15C1545F1683116B00D239F2 /* cpConstraint.c */, + 15C154601683116B00D239F2 /* cpDampedRotarySpring.c */, + 15C154611683116B00D239F2 /* cpDampedSpring.c */, + 15C154621683116B00D239F2 /* cpGearJoint.c */, + 15C154631683116B00D239F2 /* cpGrooveJoint.c */, + 15C154641683116B00D239F2 /* cpPinJoint.c */, + 15C154651683116B00D239F2 /* cpPivotJoint.c */, + 15C154661683116B00D239F2 /* cpRatchetJoint.c */, + 15C154671683116B00D239F2 /* cpRotaryLimitJoint.c */, + 15C154681683116B00D239F2 /* cpSimpleMotor.c */, + 15C154691683116B00D239F2 /* cpSlideJoint.c */, + ); + path = constraints; + sourceTree = ""; + }; + 15C154A71683118600D239F2 /* Box2D */ = { + isa = PBXGroup; + children = ( + 15C154A91683118600D239F2 /* Box2D.h */, + 15C154AA1683118600D239F2 /* Collision */, + 15C154C21683118600D239F2 /* Common */, + 15C154D01683118600D239F2 /* Dynamics */, + 15C1551B1683118600D239F2 /* Rope */, + ); + name = Box2D; + path = ../../../external/Box2D; + sourceTree = ""; + }; + 15C154AA1683118600D239F2 /* Collision */ = { + isa = PBXGroup; + children = ( + 15C154AB1683118600D239F2 /* b2BroadPhase.cpp */, + 15C154AC1683118600D239F2 /* b2BroadPhase.h */, + 15C154AD1683118600D239F2 /* b2CollideCircle.cpp */, + 15C154AE1683118600D239F2 /* b2CollideEdge.cpp */, + 15C154AF1683118600D239F2 /* b2CollidePolygon.cpp */, + 15C154B01683118600D239F2 /* b2Collision.cpp */, + 15C154B11683118600D239F2 /* b2Collision.h */, + 15C154B21683118600D239F2 /* b2Distance.cpp */, + 15C154B31683118600D239F2 /* b2Distance.h */, + 15C154B41683118600D239F2 /* b2DynamicTree.cpp */, + 15C154B51683118600D239F2 /* b2DynamicTree.h */, + 15C154B61683118600D239F2 /* b2TimeOfImpact.cpp */, + 15C154B71683118600D239F2 /* b2TimeOfImpact.h */, + 15C154B81683118600D239F2 /* Shapes */, + ); + path = Collision; + sourceTree = ""; + }; + 15C154B81683118600D239F2 /* Shapes */ = { + isa = PBXGroup; + children = ( + 15C154B91683118600D239F2 /* b2ChainShape.cpp */, + 15C154BA1683118600D239F2 /* b2ChainShape.h */, + 15C154BB1683118600D239F2 /* b2CircleShape.cpp */, + 15C154BC1683118600D239F2 /* b2CircleShape.h */, + 15C154BD1683118600D239F2 /* b2EdgeShape.cpp */, + 15C154BE1683118600D239F2 /* b2EdgeShape.h */, + 15C154BF1683118600D239F2 /* b2PolygonShape.cpp */, + 15C154C01683118600D239F2 /* b2PolygonShape.h */, + 15C154C11683118600D239F2 /* b2Shape.h */, + ); + path = Shapes; + sourceTree = ""; + }; + 15C154C21683118600D239F2 /* Common */ = { + isa = PBXGroup; + children = ( + 15C154C31683118600D239F2 /* b2BlockAllocator.cpp */, + 15C154C41683118600D239F2 /* b2BlockAllocator.h */, + 15C154C51683118600D239F2 /* b2Draw.cpp */, + 15C154C61683118600D239F2 /* b2Draw.h */, + 15C154C71683118600D239F2 /* b2GrowableStack.h */, + 15C154C81683118600D239F2 /* b2Math.cpp */, + 15C154C91683118600D239F2 /* b2Math.h */, + 15C154CA1683118600D239F2 /* b2Settings.cpp */, + 15C154CB1683118600D239F2 /* b2Settings.h */, + 15C154CC1683118600D239F2 /* b2StackAllocator.cpp */, + 15C154CD1683118600D239F2 /* b2StackAllocator.h */, + 15C154CE1683118600D239F2 /* b2Timer.cpp */, + 15C154CF1683118600D239F2 /* b2Timer.h */, + ); + path = Common; + sourceTree = ""; + }; + 15C154D01683118600D239F2 /* Dynamics */ = { + isa = PBXGroup; + children = ( + 15C154D11683118600D239F2 /* b2Body.cpp */, + 15C154D21683118600D239F2 /* b2Body.h */, + 15C154D31683118600D239F2 /* b2ContactManager.cpp */, + 15C154D41683118600D239F2 /* b2ContactManager.h */, + 15C154D51683118600D239F2 /* b2Fixture.cpp */, + 15C154D61683118600D239F2 /* b2Fixture.h */, + 15C154D71683118600D239F2 /* b2Island.cpp */, + 15C154D81683118600D239F2 /* b2Island.h */, + 15C154D91683118600D239F2 /* b2TimeStep.h */, + 15C154DA1683118600D239F2 /* b2World.cpp */, + 15C154DB1683118600D239F2 /* b2World.h */, + 15C154DC1683118600D239F2 /* b2WorldCallbacks.cpp */, + 15C154DD1683118600D239F2 /* b2WorldCallbacks.h */, + 15C154DE1683118600D239F2 /* Contacts */, + 15C154F11683118600D239F2 /* Joints */, + ); + path = Dynamics; + sourceTree = ""; + }; + 15C154DE1683118600D239F2 /* Contacts */ = { + isa = PBXGroup; + children = ( + 15C154DF1683118600D239F2 /* b2ChainAndCircleContact.cpp */, + 15C154E01683118600D239F2 /* b2ChainAndCircleContact.h */, + 15C154E11683118600D239F2 /* b2ChainAndPolygonContact.cpp */, + 15C154E21683118600D239F2 /* b2ChainAndPolygonContact.h */, + 15C154E31683118600D239F2 /* b2CircleContact.cpp */, + 15C154E41683118600D239F2 /* b2CircleContact.h */, + 15C154E51683118600D239F2 /* b2Contact.cpp */, + 15C154E61683118600D239F2 /* b2Contact.h */, + 15C154E71683118600D239F2 /* b2ContactSolver.cpp */, + 15C154E81683118600D239F2 /* b2ContactSolver.h */, + 15C154E91683118600D239F2 /* b2EdgeAndCircleContact.cpp */, + 15C154EA1683118600D239F2 /* b2EdgeAndCircleContact.h */, + 15C154EB1683118600D239F2 /* b2EdgeAndPolygonContact.cpp */, + 15C154EC1683118600D239F2 /* b2EdgeAndPolygonContact.h */, + 15C154ED1683118600D239F2 /* b2PolygonAndCircleContact.cpp */, + 15C154EE1683118600D239F2 /* b2PolygonAndCircleContact.h */, + 15C154EF1683118600D239F2 /* b2PolygonContact.cpp */, + 15C154F01683118600D239F2 /* b2PolygonContact.h */, + ); + path = Contacts; + sourceTree = ""; + }; + 15C154F11683118600D239F2 /* Joints */ = { + isa = PBXGroup; + children = ( + 15C154F21683118600D239F2 /* b2DistanceJoint.cpp */, + 15C154F31683118600D239F2 /* b2DistanceJoint.h */, + 15C154F41683118600D239F2 /* b2FrictionJoint.cpp */, + 15C154F51683118600D239F2 /* b2FrictionJoint.h */, + 15C154F61683118600D239F2 /* b2GearJoint.cpp */, + 15C154F71683118600D239F2 /* b2GearJoint.h */, + 15C154F81683118600D239F2 /* b2Joint.cpp */, + 15C154F91683118600D239F2 /* b2Joint.h */, + 15C154FA1683118600D239F2 /* b2MouseJoint.cpp */, + 15C154FB1683118600D239F2 /* b2MouseJoint.h */, + 15C154FC1683118600D239F2 /* b2PrismaticJoint.cpp */, + 15C154FD1683118600D239F2 /* b2PrismaticJoint.h */, + 15C154FE1683118600D239F2 /* b2PulleyJoint.cpp */, + 15C154FF1683118600D239F2 /* b2PulleyJoint.h */, + 15C155001683118600D239F2 /* b2RevoluteJoint.cpp */, + 15C155011683118600D239F2 /* b2RevoluteJoint.h */, + 15C155021683118600D239F2 /* b2RopeJoint.cpp */, + 15C155031683118600D239F2 /* b2RopeJoint.h */, + 15C155041683118600D239F2 /* b2WeldJoint.cpp */, + 15C155051683118600D239F2 /* b2WeldJoint.h */, + 15C155061683118600D239F2 /* b2WheelJoint.cpp */, + 15C155071683118600D239F2 /* b2WheelJoint.h */, + ); + path = Joints; + sourceTree = ""; + }; + 15C1551B1683118600D239F2 /* Rope */ = { + isa = PBXGroup; + children = ( + 15C1551C1683118600D239F2 /* b2Rope.cpp */, + 15C1551D1683118600D239F2 /* b2Rope.h */, + ); + path = Rope; + sourceTree = ""; + }; + 15C1555A168311AA00D239F2 /* CocosDenshion */ = { + isa = PBXGroup; + children = ( + 15C15570168311AA00D239F2 /* include */, + 15C15573168311AA00D239F2 /* ios */, + ); + name = CocosDenshion; + path = ../../../CocosDenshion; + sourceTree = ""; + }; + 15C15570168311AA00D239F2 /* include */ = { + isa = PBXGroup; + children = ( + 15C15571168311AA00D239F2 /* Export.h */, + 15C15572168311AA00D239F2 /* SimpleAudioEngine.h */, + ); + path = include; + sourceTree = ""; + }; + 15C15573168311AA00D239F2 /* ios */ = { + isa = PBXGroup; + children = ( + 15C15574168311AA00D239F2 /* CDAudioManager.h */, + 15C15575168311AA00D239F2 /* CDAudioManager.m */, + 15C15576168311AA00D239F2 /* CDConfig.h */, + 15C15577168311AA00D239F2 /* CDOpenALSupport.h */, + 15C15578168311AA00D239F2 /* CDOpenALSupport.m */, + 15C15579168311AA00D239F2 /* CocosDenshion.h */, + 15C1557A168311AA00D239F2 /* CocosDenshion.m */, + 15C1557B168311AA00D239F2 /* SimpleAudioEngine.mm */, + 15C1557C168311AA00D239F2 /* SimpleAudioEngine_objc.h */, + 15C1557D168311AA00D239F2 /* SimpleAudioEngine_objc.m */, + ); + path = ios; + sourceTree = ""; + }; + 15C155FF168311CB00D239F2 /* lua */ = { + isa = PBXGroup; + children = ( + 46C59AD017641FF300F43DC3 /* script */, + 46C1007916BF786A00F74D54 /* cocos2dx_support */, + 1A9D7E5B171E38A2000B3B9A /* luajit */, + 15C15650168311CB00D239F2 /* tolua */, + ); + name = lua; + path = ../../../scripting/lua; + sourceTree = ""; + }; + 15C15650168311CB00D239F2 /* tolua */ = { + isa = PBXGroup; + children = ( + 15C15651168311CB00D239F2 /* tolua++.h */, + 15C15652168311CB00D239F2 /* tolua_event.c */, + 15C15653168311CB00D239F2 /* tolua_event.h */, + 15C15654168311CB00D239F2 /* tolua_is.c */, + 15C15655168311CB00D239F2 /* tolua_map.c */, + 15C15656168311CB00D239F2 /* tolua_push.c */, + 15C15657168311CB00D239F2 /* tolua_to.c */, + ); + path = tolua; + sourceTree = ""; + }; + 15CA8CF9186967FB000032AB /* rapidjson */ = { + isa = PBXGroup; + children = ( + 15CA8CFA186967FB000032AB /* document.h */, + 15CA8CFB186967FB000032AB /* filestream.h */, + 15CA8CFC186967FB000032AB /* internal */, + 15CA8D00186967FB000032AB /* prettywriter.h */, + 15CA8D01186967FB000032AB /* rapidjson.h */, + 15CA8D02186967FB000032AB /* reader.h */, + 15CA8D03186967FB000032AB /* stringbuffer.h */, + 15CA8D04186967FB000032AB /* writer.h */, + ); + path = rapidjson; + sourceTree = ""; + }; + 15CA8CFC186967FB000032AB /* internal */ = { + isa = PBXGroup; + children = ( + 15CA8CFD186967FB000032AB /* pow10.h */, + 15CA8CFE186967FB000032AB /* stack.h */, + 15CA8CFF186967FB000032AB /* strfunc.h */, + ); + path = internal; + sourceTree = ""; + }; + 1A40E7B71727C47D006D4861 /* spine */ = { + isa = PBXGroup; + children = ( + 1A40E7B81727C47D006D4861 /* Animation.cpp */, + 1A40E7B91727C47D006D4861 /* Animation.h */, + 1A40E7BA1727C47D006D4861 /* AnimationState.cpp */, + 1A40E7BB1727C47D006D4861 /* AnimationState.h */, + 1A40E7BC1727C47D006D4861 /* AnimationStateData.cpp */, + 1A40E7BD1727C47D006D4861 /* AnimationStateData.h */, + 1A40E7BE1727C47D006D4861 /* Atlas.cpp */, + 1A40E7BF1727C47D006D4861 /* Atlas.h */, + 1A40E7C01727C47D006D4861 /* AtlasAttachmentLoader.cpp */, + 1A40E7C11727C47D006D4861 /* AtlasAttachmentLoader.h */, + 1A40E7C21727C47D006D4861 /* Attachment.cpp */, + 1A40E7C31727C47D006D4861 /* Attachment.h */, + 1A40E7C41727C47D006D4861 /* AttachmentLoader.cpp */, + 1A40E7C51727C47D006D4861 /* AttachmentLoader.h */, + 1A40E7C61727C47D006D4861 /* Bone.cpp */, + 1A40E7C71727C47D006D4861 /* Bone.h */, + 1A40E7C81727C47D006D4861 /* BoneData.cpp */, + 1A40E7C91727C47D006D4861 /* BoneData.h */, + 1AB87025175E0A40005D39BF /* CCSkeleton.cpp */, + 1AB87026175E0A40005D39BF /* CCSkeleton.h */, + 1AB87027175E0A40005D39BF /* CCSkeletonAnimation.cpp */, + 1AB87028175E0A40005D39BF /* CCSkeletonAnimation.h */, + 1A40E7CA1727C47E006D4861 /* extension.cpp */, + 1A40E7CB1727C47E006D4861 /* extension.h */, + 1A40E7CC1727C47E006D4861 /* Json.cpp */, + 1A40E7CD1727C47E006D4861 /* Json.h */, + 1A40E7CE1727C47E006D4861 /* RegionAttachment.cpp */, + 1A40E7CF1727C47E006D4861 /* RegionAttachment.h */, + 1A40E7D01727C47E006D4861 /* Skeleton.cpp */, + 1A40E7D11727C47E006D4861 /* Skeleton.h */, + 1A40E7D21727C47E006D4861 /* SkeletonData.cpp */, + 1A40E7D31727C47E006D4861 /* SkeletonData.h */, + 1A40E7D41727C47E006D4861 /* SkeletonJson.cpp */, + 1A40E7D51727C47E006D4861 /* SkeletonJson.h */, + 1A40E7D61727C47E006D4861 /* Skin.cpp */, + 1A40E7D71727C47E006D4861 /* Skin.h */, + 1A40E7D81727C47E006D4861 /* Slot.cpp */, + 1A40E7D91727C47E006D4861 /* Slot.h */, + 1A40E7DA1727C47E006D4861 /* SlotData.cpp */, + 1A40E7DB1727C47E006D4861 /* SlotData.h */, + 1A40E7DC1727C47E006D4861 /* spine-cocos2dx.cpp */, + 1A40E7DD1727C47E006D4861 /* spine-cocos2dx.h */, + 1A40E7DE1727C47E006D4861 /* spine.h */, + ); + path = spine; + sourceTree = ""; + }; + 1A9D7E5B171E38A2000B3B9A /* luajit */ = { + isa = PBXGroup; + children = ( + 1A9D7E5C171E38B2000B3B9A /* include */, + 1A9D7E61171E38B2000B3B9A /* ios */, + ); + name = luajit; + sourceTree = ""; + }; + 1A9D7E5C171E38B2000B3B9A /* include */ = { + isa = PBXGroup; + children = ( + 1A9D7E5D171E38B2000B3B9A /* lauxlib.h */, + 1A9D7E5E171E38B2000B3B9A /* lua.h */, + 1A9D7E5F171E38B2000B3B9A /* luaconf.h */, + 1A9D7E60171E38B2000B3B9A /* lualib.h */, + ); + name = include; + path = luajit/include; + sourceTree = ""; + }; + 1A9D7E61171E38B2000B3B9A /* ios */ = { + isa = PBXGroup; + children = ( + 1A9D7E62171E38B2000B3B9A /* libluajit.a */, + ); + name = ios; + path = luajit/ios; + sourceTree = ""; + }; + 1AB8702B175E0A5B005D39BF /* libwebsockets */ = { + isa = PBXGroup; + children = ( + 1AB8702C175E0A5B005D39BF /* ios */, + ); + name = libwebsockets; + path = ../../../external/libwebsockets; + sourceTree = ""; + }; + 1AB8702C175E0A5B005D39BF /* ios */ = { + isa = PBXGroup; + children = ( + 1AB8702D175E0A5B005D39BF /* include */, + 1AB8702F175E0A5B005D39BF /* lib */, + ); + path = ios; + sourceTree = ""; + }; + 1AB8702D175E0A5B005D39BF /* include */ = { + isa = PBXGroup; + children = ( + 1AB8702E175E0A5B005D39BF /* libwebsockets.h */, + ); + path = include; + sourceTree = ""; + }; + 1AB8702F175E0A5B005D39BF /* lib */ = { + isa = PBXGroup; + children = ( + 1AB87030175E0A5B005D39BF /* libwebsockets.a */, + ); + path = lib; + sourceTree = ""; + }; + 298B2A0318D0671400C1920F /* WidgetReader */ = { + isa = PBXGroup; + children = ( + 298B2A0418D0671400C1920F /* ButtonReader */, + 298B2A0718D0671400C1920F /* CheckBoxReader */, + 298B2A0A18D0671400C1920F /* ImageViewReader */, + 298B2A0D18D0671400C1920F /* LabelAtlasReader */, + 298B2A1018D0671400C1920F /* LabelBMFontReader */, + 298B2A1318D0671400C1920F /* LabelReader */, + 298B2A1618D0671400C1920F /* LayoutReader */, + 298B2A1918D0671400C1920F /* ListViewReader */, + 298B2A1C18D0671400C1920F /* LoadingBarReader */, + 298B2A1F18D0671400C1920F /* PageViewReader */, + 298B2A2218D0671400C1920F /* ScrollViewReader */, + 298B2A2518D0671400C1920F /* SliderReader */, + 298B2A2818D0671400C1920F /* TextFieldReader */, + 298B2A2B18D0671400C1920F /* WidgetReader.cpp */, + 298B2A2C18D0671400C1920F /* WidgetReader.h */, + 298B2A2D18D0671400C1920F /* WidgetReaderProtocol.h */, + ); + path = WidgetReader; + sourceTree = ""; + }; + 298B2A0418D0671400C1920F /* ButtonReader */ = { + isa = PBXGroup; + children = ( + 298B2A0518D0671400C1920F /* ButtonReader.cpp */, + 298B2A0618D0671400C1920F /* ButtonReader.h */, + ); + path = ButtonReader; + sourceTree = ""; + }; + 298B2A0718D0671400C1920F /* CheckBoxReader */ = { + isa = PBXGroup; + children = ( + 298B2A0818D0671400C1920F /* CheckBoxReader.cpp */, + 298B2A0918D0671400C1920F /* CheckBoxReader.h */, + ); + path = CheckBoxReader; + sourceTree = ""; + }; + 298B2A0A18D0671400C1920F /* ImageViewReader */ = { + isa = PBXGroup; + children = ( + 298B2A0B18D0671400C1920F /* ImageViewReader.cpp */, + 298B2A0C18D0671400C1920F /* ImageViewReader.h */, + ); + path = ImageViewReader; + sourceTree = ""; + }; + 298B2A0D18D0671400C1920F /* LabelAtlasReader */ = { + isa = PBXGroup; + children = ( + 298B2A0E18D0671400C1920F /* LabelAtlasReader.cpp */, + 298B2A0F18D0671400C1920F /* LabelAtlasReader.h */, + ); + path = LabelAtlasReader; + sourceTree = ""; + }; + 298B2A1018D0671400C1920F /* LabelBMFontReader */ = { + isa = PBXGroup; + children = ( + 298B2A1118D0671400C1920F /* LabelBMFontReader.cpp */, + 298B2A1218D0671400C1920F /* LabelBMFontReader.h */, + ); + path = LabelBMFontReader; + sourceTree = ""; + }; + 298B2A1318D0671400C1920F /* LabelReader */ = { + isa = PBXGroup; + children = ( + 298B2A1418D0671400C1920F /* LabelReader.cpp */, + 298B2A1518D0671400C1920F /* LabelReader.h */, + ); + path = LabelReader; + sourceTree = ""; + }; + 298B2A1618D0671400C1920F /* LayoutReader */ = { + isa = PBXGroup; + children = ( + 298B2A1718D0671400C1920F /* LayoutReader.cpp */, + 298B2A1818D0671400C1920F /* LayoutReader.h */, + ); + path = LayoutReader; + sourceTree = ""; + }; + 298B2A1918D0671400C1920F /* ListViewReader */ = { + isa = PBXGroup; + children = ( + 298B2A1A18D0671400C1920F /* ListViewReader.cpp */, + 298B2A1B18D0671400C1920F /* ListViewReader.h */, + ); + path = ListViewReader; + sourceTree = ""; + }; + 298B2A1C18D0671400C1920F /* LoadingBarReader */ = { + isa = PBXGroup; + children = ( + 298B2A1D18D0671400C1920F /* LoadingBarReader.cpp */, + 298B2A1E18D0671400C1920F /* LoadingBarReader.h */, + ); + path = LoadingBarReader; + sourceTree = ""; + }; + 298B2A1F18D0671400C1920F /* PageViewReader */ = { + isa = PBXGroup; + children = ( + 298B2A2018D0671400C1920F /* PageViewReader.cpp */, + 298B2A2118D0671400C1920F /* PageViewReader.h */, + ); + path = PageViewReader; + sourceTree = ""; + }; + 298B2A2218D0671400C1920F /* ScrollViewReader */ = { + isa = PBXGroup; + children = ( + 298B2A2318D0671400C1920F /* ScrollViewReader.cpp */, + 298B2A2418D0671400C1920F /* ScrollViewReader.h */, + ); + path = ScrollViewReader; + sourceTree = ""; + }; + 298B2A2518D0671400C1920F /* SliderReader */ = { + isa = PBXGroup; + children = ( + 298B2A2618D0671400C1920F /* SliderReader.cpp */, + 298B2A2718D0671400C1920F /* SliderReader.h */, + ); + path = SliderReader; + sourceTree = ""; + }; + 298B2A2818D0671400C1920F /* TextFieldReader */ = { + isa = PBXGroup; + children = ( + 298B2A2918D0671400C1920F /* TextFieldReader.cpp */, + 298B2A2A18D0671400C1920F /* TextFieldReader.h */, + ); + path = TextFieldReader; + sourceTree = ""; + }; + 373F99301869F07A0080E035 /* Action */ = { + isa = PBXGroup; + children = ( + 1514E38F18784113003FC4EE /* CCActionEaseEx.cpp */, + 150CD3981872B6B5007F1964 /* CCActionEaseEx.h */, + 373F99331869F07A0080E035 /* CCActionFrame.cpp */, + 373F99341869F07A0080E035 /* CCActionFrame.h */, + 373F99351869F07A0080E035 /* CCActionFrameEasing.cpp */, + 373F99361869F07A0080E035 /* CCActionFrameEasing.h */, + 373F99371869F07A0080E035 /* CCActionManager.cpp */, + 373F99381869F07A0080E035 /* CCActionManager.h */, + 373F99391869F07A0080E035 /* CCActionNode.cpp */, + 373F993A1869F07A0080E035 /* CCActionNode.h */, + 373F993B1869F07A0080E035 /* CCActionObject.cpp */, + 373F993C1869F07A0080E035 /* CCActionObject.h */, + ); + path = Action; + sourceTree = ""; + }; + 375BD556186846090024609E /* Trigger */ = { + isa = PBXGroup; + children = ( + 375BD557186846090024609E /* ObjectFactory.cpp */, + 375BD558186846090024609E /* ObjectFactory.h */, + 375BD559186846090024609E /* TriggerBase.cpp */, + 375BD55A186846090024609E /* TriggerBase.h */, + 375BD55B186846090024609E /* TriggerMng.cpp */, + 375BD55C186846090024609E /* TriggerMng.h */, + 375BD55D186846090024609E /* TriggerObj.cpp */, + 375BD55E186846090024609E /* TriggerObj.h */, + ); + path = Trigger; + sourceTree = ""; + }; + 46C1007916BF786A00F74D54 /* cocos2dx_support */ = { + isa = PBXGroup; + children = ( + 15CA8CEF18696743000032AB /* lua_cocos2dx_cocostudio_manual.cpp */, + 15CA8CF018696743000032AB /* lua_cocos2dx_cocostudio_manual.h */, + 15CA8CF118696743000032AB /* lua_cocos2dx_manual.cpp */, + 15CA8CF218696743000032AB /* lua_cocos2dx_manual.h */, + 15CA8CF318696743000032AB /* LuaCocoStudio.cpp */, + 15CA8CF418696743000032AB /* LuaCocoStudio.h */, + 150E36FD17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.cpp */, + 150E36FE17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.h */, + 1A9CE9171765A2C2000E3062 /* CCBProxy.cpp */, + 1A9CE9181765A2C2000E3062 /* CCBProxy.h */, + 46C1007A16BF786A00F74D54 /* CCLuaBridge.cpp */, + 46C1007B16BF786A00F74D54 /* CCLuaBridge.h */, + 46C1007C16BF786A00F74D54 /* CCLuaEngine.cpp */, + 46C1007D16BF786A00F74D54 /* CCLuaEngine.h */, + 46C1007E16BF786A00F74D54 /* CCLuaStack.cpp */, + 46C1007F16BF786A00F74D54 /* CCLuaStack.h */, + 46C1008016BF786A00F74D54 /* CCLuaValue.cpp */, + 46C1008116BF786A00F74D54 /* CCLuaValue.h */, + 46C1008216BF786A00F74D54 /* Cocos2dxLuaLoader.cpp */, + 46C1008316BF786A00F74D54 /* Cocos2dxLuaLoader.h */, + 1A9CE9191765A2C2000E3062 /* Lua_extensions_CCB.cpp */, + 1A9CE91A1765A2C2000E3062 /* Lua_extensions_CCB.h */, + 1A9CE91B1765A2C2000E3062 /* Lua_web_socket.cpp */, + 1A9CE91C1765A2C2000E3062 /* Lua_web_socket.h */, + 46C1008416BF786A00F74D54 /* LuaCocos2d.cpp */, + 46C1008516BF786A00F74D54 /* LuaCocos2d.h */, + 46C1008616BF786A00F74D54 /* platform */, + 46C1008A16BF786A00F74D54 /* tolua_fix.c */, + 46C1008B16BF786A00F74D54 /* tolua_fix.h */, + ); + path = cocos2dx_support; + sourceTree = ""; + }; + 46C1008616BF786A00F74D54 /* platform */ = { + isa = PBXGroup; + children = ( + 46C1008716BF786A00F74D54 /* ios */, + ); + path = platform; + sourceTree = ""; + }; + 46C1008716BF786A00F74D54 /* ios */ = { + isa = PBXGroup; + children = ( + 46C1008816BF786A00F74D54 /* CCLuaObjcBridge.h */, + 46C1008916BF786A00F74D54 /* CCLuaObjcBridge.mm */, + ); + path = ios; + sourceTree = ""; + }; + 46C59AD017641FF300F43DC3 /* script */ = { + isa = PBXGroup; + children = ( + 46C59AD117641FF300F43DC3 /* AudioEngine.lua */, + 46C59AD217641FF300F43DC3 /* CCBReaderLoad.lua */, + ); + path = script; + sourceTree = ""; + }; + 89EA57C718EB16F100A10956 /* JsonBox */ = { + isa = PBXGroup; + children = ( + 89EA57C918EB16F100A10956 /* include */, + 89EA57D618EB16F100A10956 /* src */, + ); + path = JsonBox; + sourceTree = ""; + }; + 89EA57C918EB16F100A10956 /* include */ = { + isa = PBXGroup; + children = ( + 89EA57CA18EB16F100A10956 /* JsonBox */, + 89EA57D518EB16F100A10956 /* JsonBox.h */, + ); + path = include; + sourceTree = ""; + }; + 89EA57CA18EB16F100A10956 /* JsonBox */ = { + isa = PBXGroup; + children = ( + 89EA57CB18EB16F100A10956 /* Array.h */, + 89EA57CC18EB16F100A10956 /* Convert.h */, + 89EA57CD18EB16F100A10956 /* Escaper.h */, + 89EA57CE18EB16F100A10956 /* Grammar.h */, + 89EA57CF18EB16F100A10956 /* IndentCanceller.h */, + 89EA57D018EB16F100A10956 /* Indenter.h */, + 89EA57D118EB16F100A10956 /* Object.h */, + 89EA57D218EB16F100A10956 /* OutputFilter.h */, + 89EA57D318EB16F100A10956 /* SolidusEscaper.h */, + 89EA57D418EB16F100A10956 /* Value.h */, + ); + path = JsonBox; + sourceTree = ""; + }; + 89EA57D618EB16F100A10956 /* src */ = { + isa = PBXGroup; + children = ( + 89EA57D718EB16F100A10956 /* Array.cpp */, + 89EA57D818EB16F100A10956 /* Convert.cpp */, + 89EA57D918EB16F100A10956 /* Escaper.cpp */, + 89EA57DA18EB16F100A10956 /* IndentCanceller.cpp */, + 89EA57DB18EB16F100A10956 /* Indenter.cpp */, + 89EA57DC18EB16F100A10956 /* Object.cpp */, + 89EA57DD18EB16F100A10956 /* SolidusEscaper.cpp */, + 89EA57DE18EB16F100A10956 /* Value.cpp */, + ); + path = src; + sourceTree = ""; + }; + 89F5D15018E7C70F009D703C /* libs */ = { + isa = PBXGroup; + children = ( + 89EA57C718EB16F100A10956 /* JsonBox */, + 89F5D15118E7C70F009D703C /* CppSQLite3.cpp */, + 89F5D15218E7C70F009D703C /* CppSQLite3.h */, + ); + name = libs; + path = ../libs; + sourceTree = ""; + }; + ED35C02A18323496002A0750 /* CocoStudio */ = { + isa = PBXGroup; + children = ( + 373F99301869F07A0080E035 /* Action */, + 375BD556186846090024609E /* Trigger */, + ED35C03618323497002A0750 /* Armature */, + ED35C06418323497002A0750 /* Components */, + ED35C06F18323497002A0750 /* GUI */, + ED35C0A618323498002A0750 /* Json */, + ED35C0BD18323498002A0750 /* Reader */, + ); + path = CocoStudio; + sourceTree = ""; + }; + ED35C03618323497002A0750 /* Armature */ = { + isa = PBXGroup; + children = ( + ED35C03718323497002A0750 /* animation */, + ED35C03E18323497002A0750 /* CCArmature.cpp */, + ED35C03F18323497002A0750 /* CCArmature.h */, + ED35C04018323497002A0750 /* CCBone.cpp */, + ED35C04118323497002A0750 /* CCBone.h */, + ED35C04218323497002A0750 /* datas */, + ED35C04518323497002A0750 /* display */, + ED35C05018323497002A0750 /* external_tool */, + ED35C05218323497002A0750 /* physics */, + ED35C05518323497002A0750 /* utils */, + ); + path = Armature; + sourceTree = ""; + }; + ED35C03718323497002A0750 /* animation */ = { + isa = PBXGroup; + children = ( + ED35C03818323497002A0750 /* CCArmatureAnimation.cpp */, + ED35C03918323497002A0750 /* CCArmatureAnimation.h */, + ED35C03A18323497002A0750 /* CCProcessBase.cpp */, + ED35C03B18323497002A0750 /* CCProcessBase.h */, + ED35C03C18323497002A0750 /* CCTween.cpp */, + ED35C03D18323497002A0750 /* CCTween.h */, + ); + path = animation; + sourceTree = ""; + }; + ED35C04218323497002A0750 /* datas */ = { + isa = PBXGroup; + children = ( + ED35C04318323497002A0750 /* CCDatas.cpp */, + ED35C04418323497002A0750 /* CCDatas.h */, + ); + path = datas; + sourceTree = ""; + }; + ED35C04518323497002A0750 /* display */ = { + isa = PBXGroup; + children = ( + ED35C04618323497002A0750 /* CCBatchNode.cpp */, + ED35C04718323497002A0750 /* CCBatchNode.h */, + ED35C04818323497002A0750 /* CCDecorativeDisplay.cpp */, + ED35C04918323497002A0750 /* CCDecorativeDisplay.h */, + ED35C04A18323497002A0750 /* CCDisplayFactory.cpp */, + ED35C04B18323497002A0750 /* CCDisplayFactory.h */, + ED35C04C18323497002A0750 /* CCDisplayManager.cpp */, + ED35C04D18323497002A0750 /* CCDisplayManager.h */, + ED35C04E18323497002A0750 /* CCSkin.cpp */, + ED35C04F18323497002A0750 /* CCSkin.h */, + ); + path = display; + sourceTree = ""; + }; + ED35C05018323497002A0750 /* external_tool */ = { + isa = PBXGroup; + children = ( + ED35C05118323497002A0750 /* sigslot.h */, + ); + path = external_tool; + sourceTree = ""; + }; + ED35C05218323497002A0750 /* physics */ = { + isa = PBXGroup; + children = ( + ED35C05318323497002A0750 /* CCColliderDetector.cpp */, + ED35C05418323497002A0750 /* CCColliderDetector.h */, + ); + path = physics; + sourceTree = ""; + }; + ED35C05518323497002A0750 /* utils */ = { + isa = PBXGroup; + children = ( + ED35C05618323497002A0750 /* CCArmatureDataManager.cpp */, + ED35C05718323497002A0750 /* CCArmatureDataManager.h */, + ED35C05818323497002A0750 /* CCArmatureDefine.cpp */, + ED35C05918323497002A0750 /* CCArmatureDefine.h */, + ED35C05A18323497002A0750 /* CCDataReaderHelper.cpp */, + ED35C05B18323497002A0750 /* CCDataReaderHelper.h */, + ED35C05C18323497002A0750 /* CCSpriteFrameCacheHelper.cpp */, + ED35C05D18323497002A0750 /* CCSpriteFrameCacheHelper.h */, + ED35C05E18323497002A0750 /* CCTransformHelp.cpp */, + ED35C05F18323497002A0750 /* CCTransformHelp.h */, + ED35C06018323497002A0750 /* CCTweenFunction.cpp */, + ED35C06118323497002A0750 /* CCTweenFunction.h */, + ED35C06218323497002A0750 /* CCUtilMath.cpp */, + ED35C06318323497002A0750 /* CCUtilMath.h */, + ); + path = utils; + sourceTree = ""; + }; + ED35C06418323497002A0750 /* Components */ = { + isa = PBXGroup; + children = ( + 373B91261878902900198F86 /* CCComBase.h */, + ED35C06518323497002A0750 /* CCComAttribute.cpp */, + ED35C06618323497002A0750 /* CCComAttribute.h */, + ED35C06718323497002A0750 /* CCComAudio.cpp */, + ED35C06818323497002A0750 /* CCComAudio.h */, + ED35C06918323497002A0750 /* CCComController.cpp */, + ED35C06A18323497002A0750 /* CCComController.h */, + ED35C06B18323497002A0750 /* CCComRender.cpp */, + ED35C06C18323497002A0750 /* CCComRender.h */, + ED35C06D18323497002A0750 /* CCInputDelegate.cpp */, + ED35C06E18323497002A0750 /* CCInputDelegate.h */, + ); + path = Components; + sourceTree = ""; + }; + ED35C06F18323497002A0750 /* GUI */ = { + isa = PBXGroup; + children = ( + ED35C07018323497002A0750 /* BaseClasses */, + ED35C07518323497002A0750 /* Layouts */, + ED35C07C18323497002A0750 /* System */, + ED35C08518323497002A0750 /* UIWidgets */, + ); + path = GUI; + sourceTree = ""; + }; + ED35C07018323497002A0750 /* BaseClasses */ = { + isa = PBXGroup; + children = ( + ED35C07318323497002A0750 /* UIWidget.cpp */, + ED35C07418323497002A0750 /* UIWidget.h */, + ); + path = BaseClasses; + sourceTree = ""; + }; + ED35C07518323497002A0750 /* Layouts */ = { + isa = PBXGroup; + children = ( + ED35C07618323497002A0750 /* UILayout.cpp */, + ED35C07718323497002A0750 /* UILayout.h */, + ED35C07818323497002A0750 /* UILayoutDefine.cpp */, + ED35C07918323497002A0750 /* UILayoutDefine.h */, + ED35C07A18323497002A0750 /* UILayoutParameter.cpp */, + ED35C07B18323497002A0750 /* UILayoutParameter.h */, + ); + path = Layouts; + sourceTree = ""; + }; + ED35C07C18323497002A0750 /* System */ = { + isa = PBXGroup; + children = ( + 150CD3931872B593007F1964 /* UITouchGroup.cpp */, + 150CD3941872B593007F1964 /* UITouchGroup.h */, + ED35C07D18323497002A0750 /* CocosGUI.cpp */, + ED35C07E18323497002A0750 /* CocosGUI.h */, + ED35C07F18323497002A0750 /* UIHelper.cpp */, + ED35C08018323497002A0750 /* UIHelper.h */, + ); + path = System; + sourceTree = ""; + }; + ED35C08518323497002A0750 /* UIWidgets */ = { + isa = PBXGroup; + children = ( + 1583F15B18D09FF900F3D630 /* Compatible */, + 1583F15D18D09FF900F3D630 /* ScrollWidget */, + 1583F16518D09FF900F3D630 /* UIRichText.cpp */, + 1583F16618D09FF900F3D630 /* UIRichText.h */, + ED35C09218323497002A0750 /* UIButton.cpp */, + ED35C09318323498002A0750 /* UIButton.h */, + ED35C09418323498002A0750 /* UICheckBox.cpp */, + ED35C09518323498002A0750 /* UICheckBox.h */, + ED35C09618323498002A0750 /* UIImageView.cpp */, + ED35C09718323498002A0750 /* UIImageView.h */, + ED35C09818323498002A0750 /* UILabel.cpp */, + ED35C09918323498002A0750 /* UILabel.h */, + ED35C09A18323498002A0750 /* UILabelAtlas.cpp */, + ED35C09B18323498002A0750 /* UILabelAtlas.h */, + ED35C09C18323498002A0750 /* UILabelBMFont.cpp */, + ED35C09D18323498002A0750 /* UILabelBMFont.h */, + ED35C09E18323498002A0750 /* UILoadingBar.cpp */, + ED35C09F18323498002A0750 /* UILoadingBar.h */, + ED35C0A018323498002A0750 /* UISlider.cpp */, + ED35C0A118323498002A0750 /* UISlider.h */, + ED35C0A418323498002A0750 /* UITextField.cpp */, + ED35C0A518323498002A0750 /* UITextField.h */, + ); + path = UIWidgets; + sourceTree = ""; + }; + ED35C0A618323498002A0750 /* Json */ = { + isa = PBXGroup; + children = ( + 15CA8CF9186967FB000032AB /* rapidjson */, + ED35C0A918323498002A0750 /* DictionaryHelper.cpp */, + ED35C0AA18323498002A0750 /* DictionaryHelper.h */, + ); + path = Json; + sourceTree = ""; + }; + ED35C0BD18323498002A0750 /* Reader */ = { + isa = PBXGroup; + children = ( + 298B2A0318D0671400C1920F /* WidgetReader */, + ED35C0BE18323498002A0750 /* GUIReader.cpp */, + ED35C0BF18323498002A0750 /* GUIReader.h */, + ED35C0C018323498002A0750 /* SceneReader.cpp */, + ED35C0C118323498002A0750 /* SceneReader.h */, + ); + path = Reader; + sourceTree = ""; + }; + F293B3BD15EB7BE500256477 = { + isa = PBXGroup; + children = ( + 89F5D15018E7C70F009D703C /* libs */, + 15C1533E168310C700D239F2 /* cocos2dx.xcodeproj */, + 15C154A71683118600D239F2 /* Box2D */, + 15C1542E1683116B00D239F2 /* chipmunk */, + F293BB7C15EB830F00256477 /* Classes */, + 15C1555A168311AA00D239F2 /* CocosDenshion */, + 15C153791683112E00D239F2 /* extensions */, + F293B3CB15EB7BE500256477 /* Frameworks */, + 1AB8702B175E0A5B005D39BF /* libwebsockets */, + 15C155FF168311CB00D239F2 /* lua */, + F293B6E815EB807E00256477 /* Other Sources */, + F293B3C915EB7BE500256477 /* Products */, + F293BC4615EB859D00256477 /* Resources */, + ); + sourceTree = ""; + }; + F293B3C915EB7BE500256477 /* Products */ = { + isa = PBXGroup; + children = ( + F293B3C815EB7BE500256477 /* OzgGameRPG.app */, + ); + name = Products; + sourceTree = ""; + }; + F293B3CB15EB7BE500256477 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 89F5D0E818E7C59D009D703C /* libsqlite3.dylib */, + 15C1568D1683131500D239F2 /* libcurl.a */, + F293B3CC15EB7BE500256477 /* QuartzCore.framework */, + F293B3CE15EB7BE500256477 /* OpenGLES.framework */, + F293B3D015EB7BE500256477 /* OpenAL.framework */, + F293B3D215EB7BE500256477 /* AudioToolbox.framework */, + F293B3D415EB7BE500256477 /* AVFoundation.framework */, + F293B3D615EB7BE500256477 /* UIKit.framework */, + F293B3D815EB7BE500256477 /* Foundation.framework */, + F293B3DA15EB7BE500256477 /* CoreGraphics.framework */, + ); + name = Frameworks; + sourceTree = ""; + }; + F293B6E815EB807E00256477 /* Other Sources */ = { + isa = PBXGroup; + children = ( + F293B6F615EB823D00256477 /* AppController.h */, + F293B6F715EB823D00256477 /* AppController.mm */, + F293B6F815EB823D00256477 /* main.m */, + F293B6F915EB823D00256477 /* RootViewController.h */, + F293B6FA15EB823D00256477 /* RootViewController.mm */, + F293B6FB15EB823D00256477 /* OzgGameRPG_Prefix.pch */, + ); + name = "Other Sources"; + sourceTree = ""; + }; + F293BB7C15EB830F00256477 /* Classes */ = { + isa = PBXGroup; + children = ( + 89F5D0BD18E7C579009D703C /* GameCfg.h */, + 89F5D0BE18E7C579009D703C /* OzgCCScrollBgNode.cpp */, + 89F5D0BF18E7C579009D703C /* OzgCCScrollBgNode.h */, + 89F5D0C018E7C579009D703C /* OzgCCUtility.cpp */, + 89F5D0C118E7C579009D703C /* OzgCCUtility.h */, + 89F5D0C218E7C579009D703C /* OzgFileUtility.cpp */, + 89F5D0C318E7C579009D703C /* OzgFileUtility.h */, + 89F5D0C418E7C579009D703C /* OzgJoystickLayer.cpp */, + 89F5D0C518E7C579009D703C /* OzgJoystickLayer.h */, + 89F5D0C618E7C579009D703C /* RPGBaseSceneLayer.cpp */, + 89F5D0C718E7C579009D703C /* RPGBaseSceneLayer.h */, + 89F5D0C818E7C579009D703C /* RPGLoadingSceneLayer.cpp */, + 89F5D0C918E7C579009D703C /* RPGLoadingSceneLayer.h */, + 89F5D0CA18E7C579009D703C /* RPGMapMenuLayer.cpp */, + 89F5D0CB18E7C579009D703C /* RPGMapMenuLayer.h */, + 89CB7D8918E9A8BF00A5921B /* RPGMapDialogLayer.cpp */, + 89CB7D8A18E9A8BF00A5921B /* RPGMapDialogLayer.h */, + 89F5D0CC18E7C579009D703C /* RPGMapNPCRoleSprite.cpp */, + 89F5D0CD18E7C579009D703C /* RPGMapNPCRoleSprite.h */, + 89F5D0CE18E7C579009D703C /* RPGMapRoleSprite.cpp */, + 89F5D0CF18E7C579009D703C /* RPGMapRoleSprite.h */, + 89E63C7F18EDA9E200BDD04F /* RPGBattlePlayerSprite.cpp */, + 89E63C8018EDA9E200BDD04F /* RPGBattlePlayerSprite.h */, + 9E5C5F6F18EE68BD00A68C36 /* RPGBattleMonsterSprite.cpp */, + 9E5C5F7018EE68BD00A68C36 /* RPGBattleMonsterSprite.h */, + 895EC07118F05AE600C3814D /* RPGData.cpp */, + 895EC07218F05AE600C3814D /* RPGData.h */, + 8999051818F17A3D00012A0E /* RPGBattleMenu.cpp */, + 8999051918F17A3D00012A0E /* RPGBattleMenu.h */, + 89F5D0D418E7C579009D703C /* RPGBattleSceneLayer.cpp */, + 89F5D0D518E7C579009D703C /* RPGBattleSceneLayer.h */, + 89F5D0D618E7C579009D703C /* RPGMapSceneLayer.cpp */, + 89F5D0D718E7C579009D703C /* RPGMapSceneLayer.h */, + 89F5D0D818E7C579009D703C /* RPGStartSceneLayer.cpp */, + 89F5D0D918E7C579009D703C /* RPGStartSceneLayer.h */, + 8960C18018E7D51C0075EF99 /* RPGConfirmLayer.cpp */, + 8960C18118E7D51C0075EF99 /* RPGConfirmLayer.h */, + F293BB7E15EB831F00256477 /* AppDelegate.cpp */, + F293BB7F15EB831F00256477 /* AppDelegate.h */, + ); + name = Classes; + sourceTree = ""; + }; + F293BC4615EB859D00256477 /* Resources */ = { + isa = PBXGroup; + children = ( + 8909856F18F253DE0021AE26 /* battle_msg_style1.tmx */, + 896BAEE318EF04CF006581FD /* audio_battle_end.mp3 */, + 896BAEE418EF04CF006581FD /* audio_battle_menu.wav */, + 896BAEE518EF04CF006581FD /* audio_battle_start.wav */, + 9E5C5F6D18EE59BB00A68C36 /* battle_menu_style1.tmx */, + 8999051C18F17E6C00012A0E /* battle_battlemenu_style1.tmx */, + 89EA57C018EAF2CB00A10956 /* battle_bg.png */, + 89EA57BC18EAF1EC00A10956 /* monsters.plist */, + 89EA57BD18EAF1EC00A10956 /* monsters.png */, + 89CB7D8718E9A87700A5921B /* dialog_style1.tmx */, + 89CB7D7C18E9A47800A5921B /* map_menu1_style1.tmx */, + 89CB7D7D18E9A47800A5921B /* map_menu2_style1.tmx */, + 89CB7D7E18E9A47800A5921B /* map_menu3_style1.tmx */, + 9E427D0418EBBA9F00DA4E79 /* map_menu4_style1.tmx */, + 89F5D14E18E7C5E5009D703C /* db.sys */, + 89F5D12C18E7C5DD009D703C /* joystick.plist */, + 89F5D12D18E7C5DD009D703C /* joystick.png */, + 89F5D12E18E7C5DD009D703C /* main.plist */, + 89F5D12F18E7C5DD009D703C /* main.png */, + 8960C17E18E7D0BD0075EF99 /* alert_style1.tmx */, + 89F5D13018E7C5DD009D703C /* map_01.tmx */, + 89F5D13118E7C5DD009D703C /* map_02.tmx */, + 89F5D13218E7C5DD009D703C /* map_03.tmx */, + 89F5D13618E7C5DD009D703C /* map.png */, + 89F5D13718E7C5DD009D703C /* scene_battle_cns.plist */, + 89F5D13818E7C5DD009D703C /* scene_loading_cns.plist */, + 89F5D13918E7C5DD009D703C /* scene_map_cns.plist */, + 89F5D13A18E7C5DD009D703C /* scene_start_cns.plist */, + 89F5D13B18E7C5DD009D703C /* start_bg.png */, + 89F5D13C18E7C5DD009D703C /* Window_b_00.png */, + 89F5D12018E7C5CC009D703C /* audio_battle.mp3 */, + 89F5D12118E7C5CC009D703C /* audio_effect_btn.wav */, + 89F5D12218E7C5CC009D703C /* audio_map_01.mp3 */, + 89F5D12318E7C5CC009D703C /* audio_map_02.mp3 */, + 89F5D12418E7C5CC009D703C /* audio_map_03.mp3 */, + 89F5D12518E7C5CC009D703C /* audio_start.mp3 */, + 89F5D0EC18E7C5C0009D703C /* actor4_0.png */, + 89F5D0ED18E7C5C0009D703C /* actor4_1.png */, + 89F5D0EE18E7C5C0009D703C /* actor4_2.png */, + 89F5D0EF18E7C5C0009D703C /* actor4_3.png */, + 89F5D0F018E7C5C0009D703C /* actor4_4.png */, + 89E63C6B18ED83C900BDD04F /* actor5_0.png */, + 89E63C6C18ED83C900BDD04F /* actor5_1.png */, + 89E63C6D18ED83C900BDD04F /* actor5_2.png */, + 89E63C6E18ED83C900BDD04F /* actor5_3.png */, + 89E63C6F18ED83C900BDD04F /* actor5_4.png */, + 89F5D0F118E7C5C0009D703C /* actor7_0.png */, + 89F5D0F218E7C5C0009D703C /* actor7_1.png */, + 89F5D0F318E7C5C0009D703C /* actor7_2.png */, + 89F5D0F418E7C5C0009D703C /* actor7_3.png */, + 89F5D0F518E7C5C0009D703C /* actor7_4.png */, + 89E63C7018ED83C900BDD04F /* actor8_0.png */, + 89E63C7118ED83C900BDD04F /* actor8_1.png */, + 89E63C7218ED83C900BDD04F /* actor8_2.png */, + 89E63C7318ED83C900BDD04F /* actor8_3.png */, + 89E63C7418ED83C900BDD04F /* actor8_4.png */, + 89F5D10018E7C5C0009D703C /* actor111.png */, + 89F5D10118E7C5C0009D703C /* actor113.png */, + 89F5D10218E7C5C0009D703C /* actor114.png */, + 89F5D10318E7C5C0009D703C /* actor115.png */, + 89F5D10418E7C5C0009D703C /* actor117.png */, + 89F5D10518E7C5C0009D703C /* actor120.png */, + 89F5D0EA18E7C5B4009D703C /* 方正粗圆简体.ttf */, + 1AC3622916D47C5C000847F2 /* fonts */, + 15C156911683138E00D239F2 /* Default-568h@2x.png */, + 15C156921683138E00D239F2 /* Default.png */, + 15C156931683138E00D239F2 /* Default@2x.png */, + 15C156941683138E00D239F2 /* Icon-57.png */, + 15C156951683138E00D239F2 /* Icon-72.png */, + 15C156961683138E00D239F2 /* Icon-114.png */, + 15C156971683138E00D239F2 /* Icon-144.png */, + ); + name = Resources; + path = ../Resources; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + F293B3C715EB7BE500256477 /* OzgGameRPG */ = { + isa = PBXNativeTarget; + buildConfigurationList = F293B6C415EB7BEA00256477 /* Build configuration list for PBXNativeTarget "OzgGameRPG" */; + buildPhases = ( + F293B3C415EB7BE500256477 /* Sources */, + F293B3C515EB7BE500256477 /* Frameworks */, + F293B3C615EB7BE500256477 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 15C1568B168311DF00D239F2 /* PBXTargetDependency */, + ); + name = OzgGameRPG; + productName = OzgGameRPG; + productReference = F293B3C815EB7BE500256477 /* OzgGameRPG.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + F293B3BF15EB7BE500256477 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0430; + }; + buildConfigurationList = F293B3C215EB7BE500256477 /* Build configuration list for PBXProject "OzgGameRPG" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = F293B3BD15EB7BE500256477; + productRefGroup = F293B3C915EB7BE500256477 /* Products */; + projectDirPath = ""; + projectReferences = ( + { + ProductGroup = 15C1533F168310C700D239F2 /* Products */; + ProjectRef = 15C1533E168310C700D239F2 /* cocos2dx.xcodeproj */; + }, + ); + projectRoot = ""; + targets = ( + F293B3C715EB7BE500256477 /* OzgGameRPG */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXReferenceProxy section */ + 15C15346168310C700D239F2 /* libcocos2dx.a */ = { + isa = PBXReferenceProxy; + fileType = archive.ar; + path = libcocos2dx.a; + remoteRef = 15C15345168310C700D239F2 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; +/* End PBXReferenceProxy section */ + +/* Begin PBXResourcesBuildPhase section */ + F293B3C615EB7BE500256477 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 89F5D14718E7C5DD009D703C /* map.png in Resources */, + 8999051D18F17E6C00012A0E /* battle_battlemenu_style1.tmx in Resources */, + 89F5D11C18E7C5C0009D703C /* actor114.png in Resources */, + 89F5D11D18E7C5C0009D703C /* actor115.png in Resources */, + 896BAEE818EF04CF006581FD /* audio_battle_start.wav in Resources */, + 89CB7D8118E9A47800A5921B /* map_menu3_style1.tmx in Resources */, + 89F5D10B18E7C5C0009D703C /* actor7_0.png in Resources */, + 89F5D14B18E7C5DD009D703C /* scene_start_cns.plist in Resources */, + 896BAEE618EF04CF006581FD /* audio_battle_end.mp3 in Resources */, + 89F5D10E18E7C5C0009D703C /* actor7_3.png in Resources */, + 89CB7D8818E9A87700A5921B /* dialog_style1.tmx in Resources */, + 89F5D11B18E7C5C0009D703C /* actor113.png in Resources */, + 89F5D14C18E7C5DD009D703C /* start_bg.png in Resources */, + 89F5D12718E7C5CC009D703C /* audio_effect_btn.wav in Resources */, + 89E63C7A18ED83C900BDD04F /* actor8_0.png in Resources */, + 15C156981683138E00D239F2 /* Default-568h@2x.png in Resources */, + 89F5D14F18E7C5E5009D703C /* db.sys in Resources */, + 896BAEE718EF04CF006581FD /* audio_battle_menu.wav in Resources */, + 15C156991683138E00D239F2 /* Default.png in Resources */, + 89F5D13F18E7C5DD009D703C /* main.plist in Resources */, + 89F5D14018E7C5DD009D703C /* main.png in Resources */, + 89F5D12618E7C5CC009D703C /* audio_battle.mp3 in Resources */, + 89F5D11F18E7C5C0009D703C /* actor120.png in Resources */, + 89F5D14218E7C5DD009D703C /* map_02.tmx in Resources */, + 89F5D14D18E7C5DD009D703C /* Window_b_00.png in Resources */, + 9E427D0518EBBA9F00DA4E79 /* map_menu4_style1.tmx in Resources */, + 89F5D13E18E7C5DD009D703C /* joystick.png in Resources */, + 89E63C7818ED83C900BDD04F /* actor5_3.png in Resources */, + 89F5D10718E7C5C0009D703C /* actor4_1.png in Resources */, + 89CB7D8018E9A47800A5921B /* map_menu2_style1.tmx in Resources */, + 89E63C7E18ED83C900BDD04F /* actor8_4.png in Resources */, + 89E63C7C18ED83C900BDD04F /* actor8_2.png in Resources */, + 89F5D12B18E7C5CC009D703C /* audio_start.mp3 in Resources */, + 15C1569A1683138E00D239F2 /* Default@2x.png in Resources */, + 89E63C7718ED83C900BDD04F /* actor5_2.png in Resources */, + 89CB7D7F18E9A47800A5921B /* map_menu1_style1.tmx in Resources */, + 89F5D12A18E7C5CC009D703C /* audio_map_03.mp3 in Resources */, + 89E63C7D18ED83C900BDD04F /* actor8_3.png in Resources */, + 89F5D11A18E7C5C0009D703C /* actor111.png in Resources */, + 89E63C7B18ED83C900BDD04F /* actor8_1.png in Resources */, + 15C1569B1683138E00D239F2 /* Icon-57.png in Resources */, + 15C1569C1683138E00D239F2 /* Icon-72.png in Resources */, + 89EA57BE18EAF1EC00A10956 /* monsters.plist in Resources */, + 15C1569D1683138E00D239F2 /* Icon-114.png in Resources */, + 89F5D0EB18E7C5B4009D703C /* 方正粗圆简体.ttf in Resources */, + 89EA57C118EAF2CB00A10956 /* battle_bg.png in Resources */, + 89F5D13D18E7C5DD009D703C /* joystick.plist in Resources */, + 89E63C7518ED83C900BDD04F /* actor5_0.png in Resources */, + 15C1569E1683138E00D239F2 /* Icon-144.png in Resources */, + 89F5D10F18E7C5C0009D703C /* actor7_4.png in Resources */, + 9E5C5F6E18EE59BB00A68C36 /* battle_menu_style1.tmx in Resources */, + 1AC3623516D47C5C000847F2 /* fonts in Resources */, + 89F5D14118E7C5DD009D703C /* map_01.tmx in Resources */, + 89F5D10C18E7C5C0009D703C /* actor7_1.png in Resources */, + 89F5D12918E7C5CC009D703C /* audio_map_02.mp3 in Resources */, + 46C59AD317641FF300F43DC3 /* AudioEngine.lua in Resources */, + 89F5D12818E7C5CC009D703C /* audio_map_01.mp3 in Resources */, + 89F5D10918E7C5C0009D703C /* actor4_3.png in Resources */, + 8909857018F253DE0021AE26 /* battle_msg_style1.tmx in Resources */, + 89F5D14318E7C5DD009D703C /* map_03.tmx in Resources */, + 89F5D10818E7C5C0009D703C /* actor4_2.png in Resources */, + 89E63C7918ED83C900BDD04F /* actor5_4.png in Resources */, + 89F5D14818E7C5DD009D703C /* scene_battle_cns.plist in Resources */, + 89E63C7618ED83C900BDD04F /* actor5_1.png in Resources */, + 89F5D14918E7C5DD009D703C /* scene_loading_cns.plist in Resources */, + 89F5D11E18E7C5C0009D703C /* actor117.png in Resources */, + 89F5D14A18E7C5DD009D703C /* scene_map_cns.plist in Resources */, + 8960C17F18E7D0BD0075EF99 /* alert_style1.tmx in Resources */, + 46C59AD417641FF300F43DC3 /* CCBReaderLoad.lua in Resources */, + 89F5D10D18E7C5C0009D703C /* actor7_2.png in Resources */, + 89EA57BF18EAF1EC00A10956 /* monsters.png in Resources */, + 89F5D10618E7C5C0009D703C /* actor4_0.png in Resources */, + 89F5D10A18E7C5C0009D703C /* actor4_4.png in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + F293B3C415EB7BE500256477 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + F293B6FC15EB823D00256477 /* AppController.mm in Sources */, + F293B6FD15EB823D00256477 /* main.m in Sources */, + 373F993F1869F07A0080E035 /* CCActionFrameEasing.cpp in Sources */, + F293B6FE15EB823D00256477 /* RootViewController.mm in Sources */, + 89F5D0E718E7C579009D703C /* RPGStartSceneLayer.cpp in Sources */, + F293BB9C15EB831F00256477 /* AppDelegate.cpp in Sources */, + 15C153F71683112E00D239F2 /* CCBAnimationManager.cpp in Sources */, + 89F5D15318E7C70F009D703C /* CppSQLite3.cpp in Sources */, + 89EA57E518EB16F100A10956 /* Object.cpp in Sources */, + 150CD3951872B593007F1964 /* UITouchGroup.cpp in Sources */, + ED35C0D518323498002A0750 /* CCDataReaderHelper.cpp in Sources */, + ED35C0D218323498002A0750 /* CCColliderDetector.cpp in Sources */, + 15C153F81683112E00D239F2 /* CCBFileLoader.cpp in Sources */, + 15C153F91683112E00D239F2 /* CCBKeyframe.cpp in Sources */, + ED35C0D618323498002A0750 /* CCSpriteFrameCacheHelper.cpp in Sources */, + 15C153FA1683112E00D239F2 /* CCBReader.cpp in Sources */, + 15C153FB1683112E00D239F2 /* CCBSequence.cpp in Sources */, + 15C153FC1683112E00D239F2 /* CCBSequenceProperty.cpp in Sources */, + 15C153FD1683112E00D239F2 /* CCBValue.cpp in Sources */, + 15C153FE1683112E00D239F2 /* CCControlButtonLoader.cpp in Sources */, + ED35C0E318323498002A0750 /* UILayoutParameter.cpp in Sources */, + ED35C0F018323498002A0750 /* UILabelAtlas.cpp in Sources */, + 15C153FF1683112E00D239F2 /* CCControlLoader.cpp in Sources */, + 15C154001683112E00D239F2 /* CCData.cpp in Sources */, + 375BD561186846090024609E /* TriggerMng.cpp in Sources */, + 15C154011683112E00D239F2 /* CCLabelBMFontLoader.cpp in Sources */, + 15C154021683112E00D239F2 /* CCLabelTTFLoader.cpp in Sources */, + 298B2A3B18D0671400C1920F /* WidgetReader.cpp in Sources */, + 15C154031683112E00D239F2 /* CCLayerColorLoader.cpp in Sources */, + 89F5D0E518E7C579009D703C /* RPGBattleSceneLayer.cpp in Sources */, + 15C154041683112E00D239F2 /* CCLayerGradientLoader.cpp in Sources */, + 15C154051683112E00D239F2 /* CCLayerLoader.cpp in Sources */, + 15C154061683112E00D239F2 /* CCMenuItemImageLoader.cpp in Sources */, + 15C154071683112E00D239F2 /* CCMenuItemLoader.cpp in Sources */, + 15C154081683112E00D239F2 /* CCNode+CCBRelativePositioning.cpp in Sources */, + 15C154091683112E00D239F2 /* CCNodeLoader.cpp in Sources */, + 15C1540A1683112E00D239F2 /* CCNodeLoaderLibrary.cpp in Sources */, + 15C1540B1683112E00D239F2 /* CCParticleSystemQuadLoader.cpp in Sources */, + 15C1540C1683112E00D239F2 /* CCScale9SpriteLoader.cpp in Sources */, + 15C1540D1683112E00D239F2 /* CCScrollViewLoader.cpp in Sources */, + 89EA57E118EB16F100A10956 /* Convert.cpp in Sources */, + 15C1540E1683112E00D239F2 /* CCSpriteLoader.cpp in Sources */, + ED35C0D918323498002A0750 /* CCUtilMath.cpp in Sources */, + 298B2A3818D0671400C1920F /* ScrollViewReader.cpp in Sources */, + 15C1540F1683112E00D239F2 /* CCControl.cpp in Sources */, + 15C154101683112E00D239F2 /* CCControlButton.cpp in Sources */, + 298B2A3518D0671400C1920F /* ListViewReader.cpp in Sources */, + 89EA57E418EB16F100A10956 /* Indenter.cpp in Sources */, + 15C154111683112E00D239F2 /* CCControlColourPicker.cpp in Sources */, + 15C154121683112E00D239F2 /* CCControlHuePicker.cpp in Sources */, + ED35C0EC18323498002A0750 /* UIButton.cpp in Sources */, + 15C154131683112E00D239F2 /* CCControlPotentiometer.cpp in Sources */, + 15C154141683112E00D239F2 /* CCControlSaturationBrightnessPicker.cpp in Sources */, + 15C154151683112E00D239F2 /* CCControlSlider.cpp in Sources */, + 15C154161683112E00D239F2 /* CCControlStepper.cpp in Sources */, + 15C154171683112E00D239F2 /* CCControlSwitch.cpp in Sources */, + 8999051A18F17A3D00012A0E /* RPGBattleMenu.cpp in Sources */, + 298B2A3218D0671400C1920F /* LabelBMFontReader.cpp in Sources */, + 15C154181683112E00D239F2 /* CCControlUtils.cpp in Sources */, + 15C154191683112E00D239F2 /* CCInvocation.cpp in Sources */, + 15C1541A1683112E00D239F2 /* CCScale9Sprite.cpp in Sources */, + ED35C0F518323498002A0750 /* UITextField.cpp in Sources */, + 15C1541B1683112E00D239F2 /* CCEditBox.cpp in Sources */, + 373F99411869F07A0080E035 /* CCActionNode.cpp in Sources */, + 15C1541D1683112E00D239F2 /* CCEditBoxImplIOS.mm in Sources */, + 15C1541F1683112E00D239F2 /* CCScrollView.cpp in Sources */, + 15C154201683112E00D239F2 /* CCSorting.cpp in Sources */, + 298B2A3718D0671400C1920F /* PageViewReader.cpp in Sources */, + 15C154211683112E00D239F2 /* CCTableView.cpp in Sources */, + 15C154221683112E00D239F2 /* CCTableViewCell.cpp in Sources */, + ED35C0CD18323498002A0750 /* CCBatchNode.cpp in Sources */, + 15C154231683112E00D239F2 /* HttpClient.cpp in Sources */, + ED35C0D018323498002A0750 /* CCDisplayManager.cpp in Sources */, + 15C154241683112E00D239F2 /* CCPhysicsDebugNode.cpp in Sources */, + 89EA57E318EB16F100A10956 /* IndentCanceller.cpp in Sources */, + ED35C0C818323498002A0750 /* CCProcessBase.cpp in Sources */, + 15C154251683112E00D239F2 /* CCPhysicsSprite.cpp in Sources */, + 298B2A2F18D0671400C1920F /* CheckBoxReader.cpp in Sources */, + 15C154891683116B00D239F2 /* chipmunk.c in Sources */, + 1583F16A18D09FF900F3D630 /* UIRichText.cpp in Sources */, + ED35C0D718323498002A0750 /* CCTransformHelp.cpp in Sources */, + 15C1548B1683116B00D239F2 /* cpConstraint.c in Sources */, + 15C1548C1683116B00D239F2 /* cpDampedRotarySpring.c in Sources */, + 15C1548D1683116B00D239F2 /* cpDampedSpring.c in Sources */, + 373F99421869F07A0080E035 /* CCActionObject.cpp in Sources */, + 15C1548E1683116B00D239F2 /* cpGearJoint.c in Sources */, + 15C1548F1683116B00D239F2 /* cpGrooveJoint.c in Sources */, + 15C154901683116B00D239F2 /* cpPinJoint.c in Sources */, + 15C154911683116B00D239F2 /* cpPivotJoint.c in Sources */, + 298B2A3418D0671400C1920F /* LayoutReader.cpp in Sources */, + 15C154921683116B00D239F2 /* cpRatchetJoint.c in Sources */, + 89F5D0E218E7C579009D703C /* RPGMapRoleSprite.cpp in Sources */, + 89EA57E018EB16F100A10956 /* Array.cpp in Sources */, + 15C154931683116B00D239F2 /* cpRotaryLimitJoint.c in Sources */, + 15C154941683116B00D239F2 /* cpSimpleMotor.c in Sources */, + 298B2A3018D0671400C1920F /* ImageViewReader.cpp in Sources */, + 15C154951683116B00D239F2 /* cpSlideJoint.c in Sources */, + 15C154961683116B00D239F2 /* cpArbiter.c in Sources */, + 15C154971683116B00D239F2 /* cpArray.c in Sources */, + 89F5D0E618E7C579009D703C /* RPGMapSceneLayer.cpp in Sources */, + 15C154981683116B00D239F2 /* cpBB.c in Sources */, + ED35C0F118323498002A0750 /* UILabelBMFont.cpp in Sources */, + 1583F16818D09FF900F3D630 /* UIPageView.cpp in Sources */, + 15C154991683116B00D239F2 /* cpBBTree.c in Sources */, + 15C1549A1683116B00D239F2 /* cpBody.c in Sources */, + 15C1549B1683116B00D239F2 /* cpCollision.c in Sources */, + ED35C0F718323498002A0750 /* DictionaryHelper.cpp in Sources */, + 15C1549C1683116B00D239F2 /* cpHashSet.c in Sources */, + 375BD55F186846090024609E /* ObjectFactory.cpp in Sources */, + 15C1549D1683116B00D239F2 /* cpPolyShape.c in Sources */, + 895EC07318F05AE600C3814D /* RPGData.cpp in Sources */, + ED35C0E518323498002A0750 /* UIHelper.cpp in Sources */, + 15C1549E1683116B00D239F2 /* cpShape.c in Sources */, + 15C1549F1683116B00D239F2 /* cpSpace.c in Sources */, + 15C154A01683116B00D239F2 /* cpSpaceComponent.c in Sources */, + 15C154A11683116B00D239F2 /* cpSpaceHash.c in Sources */, + 15C154A21683116B00D239F2 /* cpSpaceQuery.c in Sources */, + 89E63C8118EDA9E200BDD04F /* RPGBattlePlayerSprite.cpp in Sources */, + 15C154A31683116B00D239F2 /* cpSpaceStep.c in Sources */, + 15C154A41683116B00D239F2 /* cpSpatialIndex.c in Sources */, + 15C154A51683116B00D239F2 /* cpSweep1D.c in Sources */, + 15C154A61683116B00D239F2 /* cpVect.c in Sources */, + 89EA57E718EB16F100A10956 /* Value.cpp in Sources */, + ED35C0E018323498002A0750 /* UIWidget.cpp in Sources */, + 15C1551F1683118600D239F2 /* b2BroadPhase.cpp in Sources */, + 15C155201683118600D239F2 /* b2CollideCircle.cpp in Sources */, + 15C155211683118600D239F2 /* b2CollideEdge.cpp in Sources */, + 15C155221683118600D239F2 /* b2CollidePolygon.cpp in Sources */, + ED35C0E418323498002A0750 /* CocosGUI.cpp in Sources */, + 15C155231683118600D239F2 /* b2Collision.cpp in Sources */, + 89EA57E618EB16F100A10956 /* SolidusEscaper.cpp in Sources */, + 373F993E1869F07A0080E035 /* CCActionFrame.cpp in Sources */, + ED35C0DA18323498002A0750 /* CCComAttribute.cpp in Sources */, + 298B2A3118D0671400C1920F /* LabelAtlasReader.cpp in Sources */, + ED35C0DE18323498002A0750 /* CCInputDelegate.cpp in Sources */, + 15C155241683118600D239F2 /* b2Distance.cpp in Sources */, + 89F5D0DB18E7C579009D703C /* OzgCCUtility.cpp in Sources */, + 298B2A3318D0671400C1920F /* LabelReader.cpp in Sources */, + 298B2A3A18D0671400C1920F /* TextFieldReader.cpp in Sources */, + 15C155251683118600D239F2 /* b2DynamicTree.cpp in Sources */, + 15C155261683118600D239F2 /* b2TimeOfImpact.cpp in Sources */, + 15C155271683118600D239F2 /* b2ChainShape.cpp in Sources */, + 15C155281683118600D239F2 /* b2CircleShape.cpp in Sources */, + 15C155291683118600D239F2 /* b2EdgeShape.cpp in Sources */, + 298B2A3618D0671400C1920F /* LoadingBarReader.cpp in Sources */, + 15C1552A1683118600D239F2 /* b2PolygonShape.cpp in Sources */, + 15C1552B1683118600D239F2 /* b2BlockAllocator.cpp in Sources */, + 89F5D0DD18E7C579009D703C /* OzgJoystickLayer.cpp in Sources */, + 15CA8CF618696744000032AB /* lua_cocos2dx_manual.cpp in Sources */, + 15C1552C1683118600D239F2 /* b2Draw.cpp in Sources */, + 15C1552D1683118600D239F2 /* b2Math.cpp in Sources */, + 15C1552E1683118600D239F2 /* b2Settings.cpp in Sources */, + ED35C0DD18323498002A0750 /* CCComRender.cpp in Sources */, + 15C1552F1683118600D239F2 /* b2StackAllocator.cpp in Sources */, + 15C155301683118600D239F2 /* b2Timer.cpp in Sources */, + ED35C0FF18323498002A0750 /* GUIReader.cpp in Sources */, + 375BD562186846090024609E /* TriggerObj.cpp in Sources */, + 89F5D0DA18E7C579009D703C /* OzgCCScrollBgNode.cpp in Sources */, + 15C155311683118600D239F2 /* b2Body.cpp in Sources */, + ED35C0ED18323498002A0750 /* UICheckBox.cpp in Sources */, + 15C155321683118600D239F2 /* b2ContactManager.cpp in Sources */, + 15C155331683118600D239F2 /* b2Fixture.cpp in Sources */, + 15C155341683118600D239F2 /* b2Island.cpp in Sources */, + 15C155351683118600D239F2 /* b2World.cpp in Sources */, + 15C155361683118600D239F2 /* b2WorldCallbacks.cpp in Sources */, + 15C155371683118600D239F2 /* b2ChainAndCircleContact.cpp in Sources */, + 15C155381683118600D239F2 /* b2ChainAndPolygonContact.cpp in Sources */, + 15C155391683118600D239F2 /* b2CircleContact.cpp in Sources */, + ED35C0C718323498002A0750 /* CCArmatureAnimation.cpp in Sources */, + ED35C0F218323498002A0750 /* UILoadingBar.cpp in Sources */, + 15C1553A1683118600D239F2 /* b2Contact.cpp in Sources */, + 15C1553B1683118600D239F2 /* b2ContactSolver.cpp in Sources */, + 298B2A3918D0671400C1920F /* SliderReader.cpp in Sources */, + 15C1553C1683118600D239F2 /* b2EdgeAndCircleContact.cpp in Sources */, + 15C1553D1683118600D239F2 /* b2EdgeAndPolygonContact.cpp in Sources */, + 15C1553E1683118600D239F2 /* b2PolygonAndCircleContact.cpp in Sources */, + 15C1553F1683118600D239F2 /* b2PolygonContact.cpp in Sources */, + 298B2A2E18D0671400C1920F /* ButtonReader.cpp in Sources */, + 15C155401683118600D239F2 /* b2DistanceJoint.cpp in Sources */, + 15C155411683118600D239F2 /* b2FrictionJoint.cpp in Sources */, + 373F99401869F07A0080E035 /* CCActionManager.cpp in Sources */, + 15C155421683118600D239F2 /* b2GearJoint.cpp in Sources */, + ED35C0E218323498002A0750 /* UILayoutDefine.cpp in Sources */, + 9E5C5F7118EE68BD00A68C36 /* RPGBattleMonsterSprite.cpp in Sources */, + 1583F16718D09FF900F3D630 /* UIListView.cpp in Sources */, + 15C155431683118600D239F2 /* b2Joint.cpp in Sources */, + 15C155441683118600D239F2 /* b2MouseJoint.cpp in Sources */, + ED35C0DC18323498002A0750 /* CCComController.cpp in Sources */, + 15C155451683118600D239F2 /* b2PrismaticJoint.cpp in Sources */, + ED35C0EE18323498002A0750 /* UIImageView.cpp in Sources */, + 15C155461683118600D239F2 /* b2PulleyJoint.cpp in Sources */, + 15C155471683118600D239F2 /* b2RevoluteJoint.cpp in Sources */, + 15C155481683118600D239F2 /* b2RopeJoint.cpp in Sources */, + ED35C0DB18323498002A0750 /* CCComAudio.cpp in Sources */, + 15C155491683118600D239F2 /* b2WeldJoint.cpp in Sources */, + 15C1554A1683118600D239F2 /* b2WheelJoint.cpp in Sources */, + 15C155591683118600D239F2 /* b2Rope.cpp in Sources */, + 89F5D0E018E7C579009D703C /* RPGMapMenuLayer.cpp in Sources */, + 15C155DA168311AA00D239F2 /* CDAudioManager.m in Sources */, + ED35C0CE18323498002A0750 /* CCDecorativeDisplay.cpp in Sources */, + 15C155DB168311AA00D239F2 /* CDOpenALSupport.m in Sources */, + 15CA8CF518696744000032AB /* lua_cocos2dx_cocostudio_manual.cpp in Sources */, + 15C155DC168311AA00D239F2 /* CocosDenshion.m in Sources */, + 15C155DD168311AA00D239F2 /* SimpleAudioEngine.mm in Sources */, + 15C155DE168311AA00D239F2 /* SimpleAudioEngine_objc.m in Sources */, + 15C15685168311CB00D239F2 /* tolua_event.c in Sources */, + 15C15686168311CB00D239F2 /* tolua_is.c in Sources */, + 15C15687168311CB00D239F2 /* tolua_map.c in Sources */, + 89F5D0E118E7C579009D703C /* RPGMapNPCRoleSprite.cpp in Sources */, + 1583F16918D09FF900F3D630 /* UIScrollView.cpp in Sources */, + 15C15688168311CB00D239F2 /* tolua_push.c in Sources */, + 89F5D0DE18E7C579009D703C /* RPGBaseSceneLayer.cpp in Sources */, + 15C15689168311CB00D239F2 /* tolua_to.c in Sources */, + 15CA8CF718696744000032AB /* LuaCocoStudio.cpp in Sources */, + 46C1008C16BF786A00F74D54 /* CCLuaBridge.cpp in Sources */, + 46C1008D16BF786A00F74D54 /* CCLuaEngine.cpp in Sources */, + 46C1008E16BF786A00F74D54 /* CCLuaStack.cpp in Sources */, + 46C1008F16BF786A00F74D54 /* CCLuaValue.cpp in Sources */, + 46C1009016BF786A00F74D54 /* Cocos2dxLuaLoader.cpp in Sources */, + 89EA57E218EB16F100A10956 /* Escaper.cpp in Sources */, + ED35C0F318323498002A0750 /* UISlider.cpp in Sources */, + 46C1009116BF786A00F74D54 /* LuaCocos2d.cpp in Sources */, + 8960C18218E7D51C0075EF99 /* RPGConfirmLayer.cpp in Sources */, + 46C1009216BF786A00F74D54 /* CCLuaObjcBridge.mm in Sources */, + 46C1009316BF786A00F74D54 /* tolua_fix.c in Sources */, + 1A40E7DF1727C47E006D4861 /* Animation.cpp in Sources */, + ED35C0E118323498002A0750 /* UILayout.cpp in Sources */, + ED35C10018323498002A0750 /* SceneReader.cpp in Sources */, + ED35C0D118323498002A0750 /* CCSkin.cpp in Sources */, + 1A40E7E01727C47E006D4861 /* AnimationState.cpp in Sources */, + 89CB7D8B18E9A8BF00A5921B /* RPGMapDialogLayer.cpp in Sources */, + 1A40E7E11727C47E006D4861 /* AnimationStateData.cpp in Sources */, + ED35C0D418323498002A0750 /* CCArmatureDefine.cpp in Sources */, + ED35C0CA18323498002A0750 /* CCArmature.cpp in Sources */, + 1A40E7E21727C47E006D4861 /* Atlas.cpp in Sources */, + 1A40E7E31727C47E006D4861 /* AtlasAttachmentLoader.cpp in Sources */, + ED35C0D318323498002A0750 /* CCArmatureDataManager.cpp in Sources */, + 1A40E7E41727C47E006D4861 /* Attachment.cpp in Sources */, + 1A40E7E51727C47E006D4861 /* AttachmentLoader.cpp in Sources */, + 1A40E7E61727C47E006D4861 /* Bone.cpp in Sources */, + 1A40E7E71727C47E006D4861 /* BoneData.cpp in Sources */, + ED35C0CF18323498002A0750 /* CCDisplayFactory.cpp in Sources */, + 1A40E7E81727C47E006D4861 /* extension.cpp in Sources */, + 375BD560186846090024609E /* TriggerBase.cpp in Sources */, + 1A40E7E91727C47E006D4861 /* Json.cpp in Sources */, + 1A40E7EA1727C47E006D4861 /* RegionAttachment.cpp in Sources */, + 1A40E7EB1727C47E006D4861 /* Skeleton.cpp in Sources */, + ED35C0D818323498002A0750 /* CCTweenFunction.cpp in Sources */, + 1A40E7EC1727C47E006D4861 /* SkeletonData.cpp in Sources */, + 1A40E7ED1727C47E006D4861 /* SkeletonJson.cpp in Sources */, + 1A40E7EE1727C47E006D4861 /* Skin.cpp in Sources */, + 1A40E7EF1727C47E006D4861 /* Slot.cpp in Sources */, + ED35C0CB18323498002A0750 /* CCBone.cpp in Sources */, + 1A40E7F01727C47E006D4861 /* SlotData.cpp in Sources */, + 1A40E7F11727C47E006D4861 /* spine-cocos2dx.cpp in Sources */, + 1AB87024175E0A2D005D39BF /* WebSocket.cpp in Sources */, + 1AB87029175E0A40005D39BF /* CCSkeleton.cpp in Sources */, + 1AB8702A175E0A40005D39BF /* CCSkeletonAnimation.cpp in Sources */, + ED35C0C918323498002A0750 /* CCTween.cpp in Sources */, + ED35C0CC18323498002A0750 /* CCDatas.cpp in Sources */, + 1A9CE91D1765A2C2000E3062 /* CCBProxy.cpp in Sources */, + 1A9CE91E1765A2C2000E3062 /* Lua_extensions_CCB.cpp in Sources */, + 89F5D0DC18E7C579009D703C /* OzgFileUtility.cpp in Sources */, + 89F5D0DF18E7C579009D703C /* RPGLoadingSceneLayer.cpp in Sources */, + 1A9CE91F1765A2C2000E3062 /* Lua_web_socket.cpp in Sources */, + 150E36FF17F2B72B0021A6EA /* lua_cocos2dx_extensions_manual.cpp in Sources */, + ED35C0EF18323498002A0750 /* UILabel.cpp in Sources */, + 1514E39018784113003FC4EE /* CCActionEaseEx.cpp in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 15C1568B168311DF00D239F2 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + name = cocos2dx; + targetProxy = 15C1568A168311DF00D239F2 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + F293B6C215EB7BEA00256477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT)"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + DEBUG, + "COCOS2D_DEBUG=1", + USE_FILE32API, + TARGET_OS_IPHONE, + "CC_LUA_ENGINE_ENABLED=1", + ); + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = ( + "\"$(PROJECT_NAME)/libs/cocos2dx/kazmath/include\"", + "\"$(PROJECT_NAME)/libs/cocos2dx\"", + "\"$(PROJECT_NAME)/libs/CocosDenshion/include\"", + "\"$(SDKROOT)/usr/include/libxml2\"", + "\"$(SRCROOT)/../../cocos2dx/\"", + "\"$(SRCROOT)/../../cocos2dx/kazmath/include\"", + "\"$(SRCROOT)/../../external/lua/tolua\"", + "\"$(SRCROOT)/../../external/lua/src\"", + "$(SRCROOT)/../../external/lua/cocos2dx_support", + "$(SRCROOT)/../../cocos2dx/platform/ios", + "$(SRCROOT)/../../cocos2dx/include", + ); + IPHONEOS_DEPLOYMENT_TARGET = 5.1; + SDKROOT = iphoneos; + }; + name = Debug; + }; + F293B6C315EB7BEA00256477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = "$(ARCHS_STANDARD_32_BIT)"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_PREPROCESSOR_DEFINITIONS = ( + NDEBUG, + USE_FILE32API, + TARGET_OS_IPHONE, + "CC_LUA_ENGINE_ENABLED=1", + ); + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = ( + "\"$(PROJECT_NAME)/libs/cocos2dx/kazmath/include\"", + "\"$(PROJECT_NAME)/libs/cocos2dx\"", + "\"$(PROJECT_NAME)/libs/CocosDenshion/include\"", + "\"$(SDKROOT)/usr/include/libxml2\"", + "\"$(SRCROOT)/../../cocos2dx/\"", + "\"$(SRCROOT)/../../cocos2dx/kazmath/include\"", + "\"$(SRCROOT)/../../external/lua/tolua\"", + "\"$(SRCROOT)/../../external/lua/src\"", + "$(SRCROOT)/../../external/lua/cocos2dx_support", + "$(SRCROOT)/../../cocos2dx/platform/ios", + "$(SRCROOT)/../../cocos2dx/include", + ); + IPHONEOS_DEPLOYMENT_TARGET = 5.1; + OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; + SDKROOT = iphoneos; + }; + name = Release; + }; + F293B6C515EB7BEA00256477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = Prefix.pch; + GCC_PREPROCESSOR_DEFINITIONS = ( + DEBUG, + "COCOS2D_DEBUG=1", + USE_FILE32API, + CC_TARGET_OS_IPHONE, + "CC_LUA_ENGINE_ENABLED=1", + "CC_ENABLE_CHIPMUNK_INTEGRATION=1", + ); + "GCC_THUMB_SUPPORT[arch=armv6]" = ""; + HEADER_SEARCH_PATHS = ( + "\"$(SRCROOT)/../../../cocos2dx\"", + "\"$(SRCROOT)/../../../cocos2dx/kazmath/include\"", + "\"$(SRCROOT)/../../../external/lua/tolua\"", + "\"$(SRCROOT)/../../../external/lua/src\"", + "$(SRCROOT)/../../../external/lua/cocos2dx_support", + "$(SRCROOT)/../../../cocos2dx/platform/ios", + "$(SRCROOT)/../../../cocos2dx/include", + "$(SRCROOT)/../../../CocosDenshion/include", + "\"$(SRCROOT)/../../../external/chipmunk/include/chipmunk\"", + "\"$(SRCROOT)/../../../external/chipmunk/include/constraints\"", + "\"$(SRCROOT)/../../../external\"", + "\"$(SRCROOT)/../../../cocos2dx/platform/third_party/ios\"", + "\"$(SRCROOT)/../../../cocos2dx/platform/ios/Simulation\"", + "\"$(SRCROOT)/../../../extensions\"", + "\"$(SRCROOT)/../libs/JsonBox/include\"", + ); + INFOPLIST_FILE = Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 6.1; + LIBRARY_SEARCH_PATHS = ( + "$(SRCROOT)/../../../cocos2dx/platform/third_party/ios/libraries", + "$(inherited)", + "\"$(SRCROOT)/../../../scripting/lua/luajit/ios\"", + "\"$(SRCROOT)/../../../external/libwebsockets/ios/lib\"", + ); + OTHER_LDFLAGS = ( + "-lxml2", + "-lz", + ); + PRODUCT_NAME = "$(TARGET_NAME)"; + TARGETED_DEVICE_FAMILY = "1,2"; + WRAPPER_EXTENSION = app; + }; + name = Debug; + }; + F293B6C615EB7BEA00256477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = Prefix.pch; + GCC_PREPROCESSOR_DEFINITIONS = ( + NDEBUG, + USE_FILE32API, + CC_TARGET_OS_IPHONE, + "CC_LUA_ENGINE_ENABLED=1", + "CC_ENABLE_CHIPMUNK_INTEGRATION=1", + ); + "GCC_THUMB_SUPPORT[arch=armv6]" = ""; + HEADER_SEARCH_PATHS = ( + "\"$(SRCROOT)/../../../cocos2dx\"", + "\"$(SRCROOT)/../../../cocos2dx/kazmath/include\"", + "\"$(SRCROOT)/../../../external/lua/tolua\"", + "\"$(SRCROOT)/../../../external/lua/src\"", + "$(SRCROOT)/../../../external/lua/cocos2dx_support", + "$(SRCROOT)/../../../cocos2dx/platform/ios", + "$(SRCROOT)/../../../cocos2dx/include", + "$(SRCROOT)/../../../CocosDenshion/include", + "\"$(SRCROOT)/../../../external/chipmunk/include/chipmunk\"", + "\"$(SRCROOT)/../../../external/chipmunk/include/constraints\"", + "\"$(SRCROOT)/../../../external\"", + "\"$(SRCROOT)/../../../cocos2dx/platform/third_party/ios\"", + "\"$(SRCROOT)/../../../cocos2dx/platform/ios/Simulation\"", + "\"$(SRCROOT)/../../../extensions\"", + "\"$(SRCROOT)/../libs/JsonBox/include\"", + ); + INFOPLIST_FILE = Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 6.1; + LIBRARY_SEARCH_PATHS = ( + "$(SRCROOT)/../../../cocos2dx/platform/third_party/ios/libraries", + "$(inherited)", + "\"$(SRCROOT)/../../../scripting/lua/luajit/ios\"", + "\"$(SRCROOT)/../../../external/libwebsockets/ios/lib\"", + ); + OTHER_LDFLAGS = ( + "-lxml2", + "-lz", + ); + PRODUCT_NAME = "$(TARGET_NAME)"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + WRAPPER_EXTENSION = app; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + F293B3C215EB7BE500256477 /* Build configuration list for PBXProject "OzgGameRPG" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + F293B6C215EB7BEA00256477 /* Debug */, + F293B6C315EB7BEA00256477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + F293B6C415EB7BEA00256477 /* Build configuration list for PBXNativeTarget "OzgGameRPG" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + F293B6C515EB7BEA00256477 /* Debug */, + F293B6C615EB7BEA00256477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = F293B3BF15EB7BE500256477 /* Project object */; +} diff --git a/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..ee043eb --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/UserInterfaceState.xcuserstate b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..8fa0820 Binary files /dev/null and b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/WorkspaceSettings.xcsettings b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/WorkspaceSettings.xcsettings new file mode 100644 index 0000000..659c876 --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/ouzhigang.xcuserdatad/WorkspaceSettings.xcsettings @@ -0,0 +1,10 @@ + + + + + HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges + + SnapshotAutomaticallyBeforeSignificantChanges + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/tpwid.xcuserdatad/UserInterfaceState.xcuserstate b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/tpwid.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..1d15755 Binary files /dev/null and b/proj.ios/OzgGameRPG.xcodeproj/project.xcworkspace/xcuserdata/tpwid.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/OzgGameRPG.xcscheme b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/OzgGameRPG.xcscheme new file mode 100644 index 0000000..35bec4a --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/OzgGameRPG.xcscheme @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/xcschememanagement.plist b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..7e089a0 --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/ouzhigang.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,22 @@ + + + + + SchemeUserState + + OzgGameRPG.xcscheme + + orderHint + 1 + + + SuppressBuildableAutocreation + + F293B3C715EB7BE500256477 + + primary + + + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/OzgGameRPG.xcscheme b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/OzgGameRPG.xcscheme new file mode 100644 index 0000000..35bec4a --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/OzgGameRPG.xcscheme @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/xcschememanagement.plist b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..7e089a0 --- /dev/null +++ b/proj.ios/OzgGameRPG.xcodeproj/xcuserdata/tpwid.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,22 @@ + + + + + SchemeUserState + + OzgGameRPG.xcscheme + + orderHint + 1 + + + SuppressBuildableAutocreation + + F293B3C715EB7BE500256477 + + primary + + + + + diff --git a/proj.ios/Prefix.pch b/proj.ios/Prefix.pch new file mode 100644 index 0000000..b4311a0 --- /dev/null +++ b/proj.ios/Prefix.pch @@ -0,0 +1,8 @@ +// +// Prefix header for all source files of the 'HelloLua' target in the 'HelloLua' project +// + +#ifdef __OBJC__ + #import + #import +#endif diff --git a/proj.ios/RootViewController.h b/proj.ios/RootViewController.h new file mode 100644 index 0000000..a40c2ed --- /dev/null +++ b/proj.ios/RootViewController.h @@ -0,0 +1,33 @@ +/**************************************************************************** + Copyright (c) 2010-2011 cocos2d-x.org + Copyright (c) 2010 Ricardo Quesada + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#import + + +@interface RootViewController : UIViewController { + +} + +@end diff --git a/proj.ios/RootViewController.mm b/proj.ios/RootViewController.mm new file mode 100644 index 0000000..a00da00 --- /dev/null +++ b/proj.ios/RootViewController.mm @@ -0,0 +1,96 @@ +/**************************************************************************** + Copyright (c) 2010-2011 cocos2d-x.org + Copyright (c) 2010 Ricardo Quesada + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#import "RootViewController.h" + + +@implementation RootViewController + +/* + // The designated initializer. Override if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad. +- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { + if ((self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil])) { + // Custom initialization + } + return self; +} +*/ + +/* +// Implement loadView to create a view hierarchy programmatically, without using a nib. +- (void)loadView { +} +*/ + +/* +// Implement viewDidLoad to do additional setup after loading the view, typically from a nib. +- (void)viewDidLoad { + [super viewDidLoad]; +} + +*/ +// Override to allow orientations other than the default portrait orientation. +// This method is deprecated on ios6 +- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { + return UIInterfaceOrientationIsLandscape( interfaceOrientation ); +} + +// For ios6, use supportedInterfaceOrientations & shouldAutorotate instead +- (NSUInteger) supportedInterfaceOrientations{ +#ifdef __IPHONE_6_0 + return UIInterfaceOrientationMaskAllButUpsideDown; +#endif +} + +- (BOOL) shouldAutorotate { + return YES; +} + +//fix not hide status on ios7 +- (BOOL)prefersStatusBarHidden +{ + return YES; +} + +- (void)didReceiveMemoryWarning { + // Releases the view if it doesn't have a superview. + [super didReceiveMemoryWarning]; + + // Release any cached data, images, etc that aren't in use. +} + +- (void)viewDidUnload { + [super viewDidUnload]; + // Release any retained subviews of the main view. + // e.g. self.myOutlet = nil; +} + + +- (void)dealloc { + [super dealloc]; +} + + +@end diff --git a/proj.ios/main.m b/proj.ios/main.m new file mode 100644 index 0000000..4135c21 --- /dev/null +++ b/proj.ios/main.m @@ -0,0 +1,15 @@ +// +// main.m +// HelloLua +// +// Copyright __MyCompanyName__ 2011. All rights reserved. +// + +#import + +int main(int argc, char *argv[]) { + NSAutoreleasePool *pool = [NSAutoreleasePool new]; + int retVal = UIApplicationMain(argc, argv, nil, @"AppController"); + [pool release]; + return retVal; +} diff --git a/proj.linux/.cproject b/proj.linux/.cproject new file mode 100644 index 0000000..bd3dffb --- /dev/null +++ b/proj.linux/.cproject @@ -0,0 +1,411 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/proj.linux/.project b/proj.linux/.project new file mode 100644 index 0000000..969cdcc --- /dev/null +++ b/proj.linux/.project @@ -0,0 +1,44 @@ + + + OzgGameRPG + + + libBox2D + libChipmunk + libcocos2d + libCocosDenshion + liblua + + + + org.eclipse.cdt.managedbuilder.core.genmakebuilder + clean,full,incremental, + + + + + org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder + full,incremental, + + + + + + org.eclipse.cdt.core.cnature + org.eclipse.cdt.core.ccnature + org.eclipse.cdt.managedbuilder.core.managedBuildNature + org.eclipse.cdt.managedbuilder.core.ScannerConfigNature + + + + Classes + 2 + PARENT-1-PROJECT_LOC/Classes + + + cocos2dx_support + 2 + PARENT-4-PROJECT_LOC/scripting/lua/cocos2dx_support + + + diff --git a/proj.linux/Makefile b/proj.linux/Makefile new file mode 100644 index 0000000..ee394d9 --- /dev/null +++ b/proj.linux/Makefile @@ -0,0 +1,27 @@ +EXECUTABLE = OzgGameRPG + +COCOS_ROOT = ../../.. +INCLUDES = -I../ -I../Classes -I$(COCOS_ROOT)/CocosDenshion/include \ + -I$(COCOS_ROOT)/scripting/lua/lua \ + -I$(COCOS_ROOT)/scripting/lua/tolua \ + -I$(COCOS_ROOT)/scripting/lua/cocos2dx_support + +SOURCES = main.cpp ../Classes/AppDelegate.cpp + +SHAREDLIBS += -lcocos2d -lcocosdenshion -llua +COCOS_LIBS = $(LIB_DIR)/libcocos2d.so $(LIB_DIR)/libcocosdenshion.so $(LIB_DIR)/liblua.so + +include $(COCOS_ROOT)/cocos2dx/proj.linux/cocos2dx.mk + +$(TARGET): $(OBJECTS) $(STATICLIBS) $(COCOS_LIBS) $(CORE_MAKEFILE_LIST) + @mkdir -p $(@D) + cp -n ../../../scripting/lua/script/* ../Resources + $(LOG_LINK)$(CXX) $(CXXFLAGS) $(OBJECTS) -o $@ $(SHAREDLIBS) $(STATICLIBS) $(LIBS) + +$(OBJ_DIR)/%.o: ../%.cpp $(CORE_MAKEFILE_LIST) + @mkdir -p $(@D) + $(LOG_CXX)$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@ + +$(OBJ_DIR)/%.o: %.cpp $(CORE_MAKEFILE_LIST) + @mkdir -p $(@D) + $(LOG_CXX)$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@ diff --git a/proj.linux/build.sh b/proj.linux/build.sh new file mode 100755 index 0000000..1fe8744 --- /dev/null +++ b/proj.linux/build.sh @@ -0,0 +1,62 @@ +#!/bin/bash + +TXTCOLOR_DEFAULT="\033[0;m" +TXTCOLOR_RED="\033[0;31m" +TXTCOLOR_GREEN="\033[0;32m" + +COCOS2DX20_TRUNK=`pwd`/../../.. +OUTPUT_DEBUG=$COCOS2DX20_TRUNK/lib/linux/debug/ +OUTPUT_RELEASE=$COCOS2DX20_TRUNK/lib/linux/release/ + +check_make_result() +{ + if [ 0 != $? ]; then + exit 1 + fi +} + +DEPENDS='libx11-dev' +DEPENDS+=' libxmu-dev' +DEPENDS+=' libglu1-mesa-dev' +DEPENDS+=' libgl2ps-dev' +DEPENDS+=' libxi-dev' +DEPENDS+=' libglfw-dev' +DEPENDS+=' g++' +DEPENDS+=' libzip-dev' +DEPENDS+=' libcurl4-gnutls-dev' +DEPENDS+=' libfontconfig1-dev' +DEPENDS+=' libsqlite3-dev' +DEPENDS+=' libglew-dev' + +for i in $DEPENDS; do + PKG_OK=$(dpkg-query -W --showformat='${Status}\n' $i | grep "install ok installed") + echo Checking for $i: $PKG_OK + if [ "" == "$PKG_OK" ]; then + echo -e $TXTCOLOR_GREEN"No $i. Setting up $i, please enter your password:"$TXTCOLOR_DEFAULT + sudo apt-get --force-yes --yes install $i + fi +done + +mkdir -p $OUTPUT_DEBUG +mkdir -p $OUTPUT_RELEASE + +make -C $COCOS2DX20_TRUNK/external/Box2D/proj.linux DEBUG=1 +check_make_result + +make -C $COCOS2DX20_TRUNK/external/chipmunk/proj.linux DEBUG=1 +check_make_result + +make -C $COCOS2DX20_TRUNK/cocos2dx/proj.linux DEBUG=1 +check_make_result + +make -C $COCOS2DX20_TRUNK/CocosDenshion/proj.linux DEBUG=1 +check_make_result + +make -C $COCOS2DX20_TRUNK/extensions/proj.linux DEBUG=1 +check_make_result + +make -C $COCOS2DX20_TRUNK/scripting/lua/proj.linux DEBUG=1 +check_make_result + +make DEBUG=1 +check_make_result diff --git a/proj.linux/main.cpp b/proj.linux/main.cpp new file mode 100644 index 0000000..bbaa8a6 --- /dev/null +++ b/proj.linux/main.cpp @@ -0,0 +1,19 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" +#include "CCEGLView.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(800, 480); + return CCApplication::sharedApplication()->run(); +} diff --git a/proj.marmalade/OzgGameRPG.mkb b/proj.marmalade/OzgGameRPG.mkb new file mode 100644 index 0000000..9f08d4a --- /dev/null +++ b/proj.marmalade/OzgGameRPG.mkb @@ -0,0 +1,45 @@ +options +{ + module_path="../../../cocos2dx/proj.marmalade/;../../../CocosDenshion/proj.marmalade/;../../../scripting/lua/proj.marmalade/;../../../extensions/proj.marmalade/;../../../external/chipmunk/proj.marmalade/;../../../external/Box2D/proj.marmalade/" + s3e-data-dir = "../Resources" +} + +includepaths +{ + ../Classes +} +subprojects +{ + IwGL + cocos2dx + CocosDenshion + cocos2dx-ext + Box2D + lua +} + +defines +{ + CC_ENABLE_BOX2D_INTEGRATION=1 +} + +assets +{ + (../Resources) + . +} + + +files +{ + [Main] + (src) + Main.h + Main.cpp + + (../Classes) + AppDelegate.h + AppDelegate.cpp +} + +postbuild "cccopy.py -s ../../../scripting/lua/script/ -d ../Resources/" diff --git a/proj.marmalade/cccopy.py b/proj.marmalade/cccopy.py new file mode 100644 index 0000000..e6f6f00 --- /dev/null +++ b/proj.marmalade/cccopy.py @@ -0,0 +1,46 @@ +import os +import shutil +from optparse import OptionParser + +def cccopy(sourcePath, destPath): + for root, dirs, files in os.walk(sourcePath): + #figure out where we're going + dest = destPath + root.replace(sourcePath, '') + destAbsPath = os.path.abspath(destPath) + #if we're in a directory that doesn't exist in the destination folder then create a new folder + if not os.path.isdir(dest): + os.mkdir(dest) + print os.path.abspath(dest).replace(destAbsPath, '')[1:] + ' directory created.' + + #loop through all files in the directory + for f in files: + #compute current (old) & new file locations + oldLoc = root + "/" + f + newLoc = dest + "/" + f + + if not os.path.isfile(newLoc): + try: + shutil.copy2(oldLoc, newLoc) + print os.path.abspath(newLoc).replace(destAbsPath,'')[1:] + ' copied.' + except IOError: + print os.path.abspath(newLoc).replace(destAbsPath,'')[1:] + ' already exists.' + + + +# main +def main(): + # parse options + parser = OptionParser(usage="%prog [options]") + parser.add_option("-s", "--sourcePath", action="store", help="Source path", dest="sourcePath") + parser.add_option("-d", "--destPath", action="store", help="Destination path", dest="destPath") + + (options, args) = parser.parse_args() + + if options.sourcePath and options.destPath: + cccopy(options.sourcePath, options.destPath) + else: + parser.error("") + +## entry +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/proj.marmalade/src/Main.cpp b/proj.marmalade/src/Main.cpp new file mode 100644 index 0000000..80b1f11 --- /dev/null +++ b/proj.marmalade/src/Main.cpp @@ -0,0 +1,19 @@ +// Application main file. + +#include "Main.h" +#include "../Classes/AppDelegate.h" + +// Cocos2dx headers +#include "cocos2d.h" + +// Marmalade headers +#include "IwGL.h" + +USING_NS_CC; + +int main() +{ + AppDelegate app; + + return cocos2d::CCApplication::sharedApplication()->Run(); +} diff --git a/proj.marmalade/src/Main.h b/proj.marmalade/src/Main.h new file mode 100644 index 0000000..ebfa484 --- /dev/null +++ b/proj.marmalade/src/Main.h @@ -0,0 +1,4 @@ +#ifndef MAIN_H +#define MAIN_H + +#endif diff --git a/proj.win32/OzgGameRPG.sln b/proj.win32/OzgGameRPG.sln new file mode 100644 index 0000000..234c1d1 --- /dev/null +++ b/proj.win32/OzgGameRPG.sln @@ -0,0 +1,77 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Visual Studio 2010 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OzgGameRPG", "OzgGameRPG.vcxproj", "{4E6A7A0E-DDD8-4BAA-8B22-C964069364ED}" + ProjectSection(ProjectDependencies) = postProject + {21B2C324-891F-48EA-AD1A-5AE13DE12E28} = {21B2C324-891F-48EA-AD1A-5AE13DE12E28} + {DDC3E27F-004D-4DD4-9DD3-931A013D2159} = {DDC3E27F-004D-4DD4-9DD3-931A013D2159} + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} = {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25} = {207BC7A9-CCF1-4F2F-A04D-45F72242AE25} + {929480E7-23C0-4DF6-8456-096D71547116} = {929480E7-23C0-4DF6-8456-096D71547116} + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} = {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libcocos2d", "..\..\..\cocos2dx\proj.win32\cocos2d.vcxproj", "{98A51BA8-FC3A-415B-AC8F-8C7BD464E93E}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libCocosDenshion", "..\..\..\CocosDenshion\proj.win32\CocosDenshion.vcxproj", "{F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6}" + ProjectSection(ProjectDependencies) = postProject + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} = {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libExtensions", "..\..\..\extensions\proj.win32\libExtensions.vcxproj", "{21B2C324-891F-48EA-AD1A-5AE13DE12E28}" + ProjectSection(ProjectDependencies) = postProject + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} = {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25} = {207BC7A9-CCF1-4F2F-A04D-45F72242AE25} + {929480E7-23C0-4DF6-8456-096D71547116} = {929480E7-23C0-4DF6-8456-096D71547116} + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} = {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libBox2D", "..\..\..\external\Box2D\proj.win32\Box2D.vcxproj", "{929480E7-23C0-4DF6-8456-096D71547116}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libchipmunk", "..\..\..\external\chipmunk\proj.win32\chipmunk.vcxproj", "{207BC7A9-CCF1-4F2F-A04D-45F72242AE25}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "liblua", "..\..\..\scripting\lua\proj.win32\liblua.vcxproj", "{DDC3E27F-004D-4DD4-9DD3-931A013D2159}" + ProjectSection(ProjectDependencies) = postProject + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} = {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E} + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} = {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6} + EndProjectSection +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4E6A7A0E-DDD8-4BAA-8B22-C964069364ED}.Debug|Win32.ActiveCfg = Debug|Win32 + {4E6A7A0E-DDD8-4BAA-8B22-C964069364ED}.Debug|Win32.Build.0 = Debug|Win32 + {4E6A7A0E-DDD8-4BAA-8B22-C964069364ED}.Release|Win32.ActiveCfg = Release|Win32 + {4E6A7A0E-DDD8-4BAA-8B22-C964069364ED}.Release|Win32.Build.0 = Release|Win32 + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E}.Debug|Win32.ActiveCfg = Debug|Win32 + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E}.Debug|Win32.Build.0 = Debug|Win32 + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E}.Release|Win32.ActiveCfg = Release|Win32 + {98A51BA8-FC3A-415B-AC8F-8C7BD464E93E}.Release|Win32.Build.0 = Release|Win32 + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6}.Debug|Win32.ActiveCfg = Debug|Win32 + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6}.Debug|Win32.Build.0 = Debug|Win32 + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6}.Release|Win32.ActiveCfg = Release|Win32 + {F8EDD7FA-9A51-4E80-BAEB-860825D2EAC6}.Release|Win32.Build.0 = Release|Win32 + {21B2C324-891F-48EA-AD1A-5AE13DE12E28}.Debug|Win32.ActiveCfg = Debug|Win32 + {21B2C324-891F-48EA-AD1A-5AE13DE12E28}.Debug|Win32.Build.0 = Debug|Win32 + {21B2C324-891F-48EA-AD1A-5AE13DE12E28}.Release|Win32.ActiveCfg = Release|Win32 + {21B2C324-891F-48EA-AD1A-5AE13DE12E28}.Release|Win32.Build.0 = Release|Win32 + {929480E7-23C0-4DF6-8456-096D71547116}.Debug|Win32.ActiveCfg = Debug|Win32 + {929480E7-23C0-4DF6-8456-096D71547116}.Debug|Win32.Build.0 = Debug|Win32 + {929480E7-23C0-4DF6-8456-096D71547116}.Release|Win32.ActiveCfg = Release|Win32 + {929480E7-23C0-4DF6-8456-096D71547116}.Release|Win32.Build.0 = Release|Win32 + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25}.Debug|Win32.ActiveCfg = Debug|Win32 + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25}.Debug|Win32.Build.0 = Debug|Win32 + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25}.Release|Win32.ActiveCfg = Release|Win32 + {207BC7A9-CCF1-4F2F-A04D-45F72242AE25}.Release|Win32.Build.0 = Release|Win32 + {DDC3E27F-004D-4DD4-9DD3-931A013D2159}.Debug|Win32.ActiveCfg = Debug|Win32 + {DDC3E27F-004D-4DD4-9DD3-931A013D2159}.Debug|Win32.Build.0 = Debug|Win32 + {DDC3E27F-004D-4DD4-9DD3-931A013D2159}.Release|Win32.ActiveCfg = Release|Win32 + {DDC3E27F-004D-4DD4-9DD3-931A013D2159}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/proj.win32/OzgGameRPG.vcxproj b/proj.win32/OzgGameRPG.vcxproj new file mode 100644 index 0000000..5be4971 --- /dev/null +++ b/proj.win32/OzgGameRPG.vcxproj @@ -0,0 +1,174 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {4E6A7A0E-DDD8-4BAA-8B22-C964069364ED} + OzgGameRPG + + + + Application + true + Unicode + v100 + v110 + v110_xp + v120 + v120_xp + + + Application + false + Unicode + v100 + v110 + v110_xp + v120 + v120_xp + + + + + + + + + + + + + $(SolutionDir)$(Configuration).win32\ + $(Configuration).win32\ + true + $(IncludePath) + $(SourcePath); + AllRules.ruleset + + + $(SolutionDir)$(Configuration).win32\ + $(Configuration).win32\ + false + + + $(MSBuildProgramFiles32)\Microsoft SDKs\Windows\v7.1A\lib;$(LibraryPath) + + + $(MSBuildProgramFiles32)\Microsoft SDKs\Windows\v7.1A\lib;$(LibraryPath) + + + + $(ProjectDir)..\Classes;$(ProjectDir)..\..\..\scripting\lua\cocos2dx_support;$(ProjectDir)..\..\..\scripting\lua\lua;$(ProjectDir)..\..\..\scripting\lua\tolua;$(ProjectDir)..\..\..\scripting\lua\src;$(ProjectDir)..\..\..\cocos2dx;$(ProjectDir)..\..\..\cocos2dx\include;$(ProjectDir)..\..\..\cocos2dx\kazmath\include;$(ProjectDir)..\..\..\cocos2dx\platform\win32;$(ProjectDir)..\..\..\cocos2dx\platform\third_party\win32;$(ProjectDir)..\..\..\cocos2dx\platform\third_party\win32\OGLES;$(ProjectDir)..\..\..\external;$(ProjectDir)..\..\..\external\chipmunk\include\chipmunk;$(ProjectDir)..\..\..\CocosDenshion\include;$(ProjectDir)..\..\..\scripting\lua\cocos2dx_support;$(ProjectDir)..\..\..\scripting\lua\tolua;$(ProjectDir)..\..\..\scripting\lua\lua;%(AdditionalIncludeDirectories) + + + Level3 + MultiThreadedDebugDLL + true + EditAndContinue + EnableFastChecks + Disabled + WIN32;_WINDOWS;STRICT;_CRT_SECURE_NO_WARNINGS;_SCL_SECURE_NO_WARNINGS_DEBUG;COCOS2D_DEBUG=1;%(PreprocessorDefinitions) + 4267;4251;4244;%(DisableSpecificWarnings) + + + Windows + MachineX86 + true + $(OutDir);%(AdditionalLibraryDirectories) + libcocos2d.lib;libExtensions.lib;opengl32.lib;glew32.lib;libBox2d.lib;libchipmunk.lib;libCocosDenshion.lib;liblua.lib;lua51.lib;websockets.lib;pthreadVCE2.lib;%(AdditionalDependencies) + + + 0x0409 + $(MSBuildProgramFiles32)\Microsoft SDKs\Windows\v7.1A\include;$(IntDir);%(AdditionalIncludeDirectories) + _DEBUG;%(PreprocessorDefinitions) + + + false + Win32 + _DEBUG;%(PreprocessorDefinitions) + OzgGameRPG.h + OzgGameRPG_i.c + OzgGameRPG_p.c + true + $(IntDir)/OzgGameRPG.tlb + + + + + xcopy "$(ProjectDir)..\..\..\scripting\lua\script" "$(ProjectDir)..\Resources" /e /Y + + + + + if not exist "$(OutDir)" mkdir "$(OutDir)" +xcopy /Y /Q "$(ProjectDir)..\..\..\external\libwebsockets\win32\lib\*.*" "$(OutDir)" + + + + + $(ProjectDir)..\Classes;$(ProjectDir)..\..\..\scripting\lua\cocos2dx_support;$(ProjectDir)..\..\..\scripting\lua\lua;$(ProjectDir)..\..\..\scripting\lua\tolua;$(ProjectDir)..\..\..\scripting\lua\src;$(ProjectDir)..\..\..\cocos2dx;$(ProjectDir)..\..\..\cocos2dx\include;$(ProjectDir)..\..\..\cocos2dx\kazmath\include;$(ProjectDir)..\..\..\cocos2dx\platform\win32;$(ProjectDir)..\..\..\cocos2dx\platform\third_party\win32;$(ProjectDir)..\..\..\cocos2dx\platform\third_party\win32\OGLES;$(ProjectDir)..\..\..\external;$(ProjectDir)..\..\..\external\chipmunk\include\chipmunk;$(ProjectDir)..\..\..\CocosDenshion\include;$(ProjectDir)..\..\..\scripting\lua\cocos2dx_support;$(ProjectDir)..\..\..\scripting\lua\tolua;$(ProjectDir)..\..\..\scripting\lua\lua;%(AdditionalIncludeDirectories) + + + Level3 + MultiThreadedDLL + + + + + WIN32;_WINDOWS;STRICT;_CRT_SECURE_NO_WARNINGS;_SCL_SECURE_NO_WARNINGSNDEBUG;%(PreprocessorDefinitions) + 4267;4251;4244;%(DisableSpecificWarnings) + + + Windows + MachineX86 + $(OutDir);%(AdditionalLibraryDirectories) + libcocos2d.lib;libExtensions.lib;opengl32.lib;glew32.lib;libBox2d.lib;libchipmunk.lib;libCocosDenshion.lib;liblua.lib;lua51.lib;websockets.lib;pthreadVCE2.lib;%(AdditionalDependencies) + + + 0x0409 + $(MSBuildProgramFiles32)\Microsoft SDKs\Windows\v7.1A\include;$(IntDir);%(AdditionalIncludeDirectories) + NDEBUG;%(PreprocessorDefinitions) + + + false + Win32 + NDEBUG;%(PreprocessorDefinitions) + OzgGameRPG.h + OzgGameRPG_i.c + OzgGameRPG_p.c + true + $(IntDir)/OzgGameRPG.tlb + + + + + + + + + + + if not exist "$(OutDir)" mkdir "$(OutDir)" +xcopy /Y /Q "$(ProjectDir)..\..\..\external\libwebsockets\win32\lib\*.*" "$(OutDir)" + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proj.win32/OzgGameRPG.vcxproj.filters b/proj.win32/OzgGameRPG.vcxproj.filters new file mode 100644 index 0000000..593b960 --- /dev/null +++ b/proj.win32/OzgGameRPG.vcxproj.filters @@ -0,0 +1,27 @@ + + + + + {fc5cb953-2953-4968-83b3-39e3ff951754} + + + {037a9a02-b906-4cc5-ad98-304acd4e25ee} + + + + + Classes + + + win32 + + + + + Classes + + + win32 + + + \ No newline at end of file diff --git a/proj.win32/OzgGameRPG.vcxproj.user b/proj.win32/OzgGameRPG.vcxproj.user new file mode 100644 index 0000000..62b0b77 --- /dev/null +++ b/proj.win32/OzgGameRPG.vcxproj.user @@ -0,0 +1,10 @@ + + + + false + $(ProjectDir)..\Resources + $(ProjectDir)..\Resources + WindowsLocalDebugger + WindowsLocalDebugger + + \ No newline at end of file diff --git a/proj.win32/game.rc b/proj.win32/game.rc new file mode 100644 index 0000000..6ac4ef9 --- /dev/null +++ b/proj.win32/game.rc @@ -0,0 +1,86 @@ +// Microsoft Visual C++ generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#define APSTUDIO_HIDDEN_SYMBOLS +#include "windows.h" +#undef APSTUDIO_HIDDEN_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// English (U.S.) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US +#pragma code_page(1252) +#endif //_WIN32 + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE +BEGIN + "resource.h\0" +END + +#endif // APSTUDIO_INVOKED + +///////////////////////////////////////////////////////////////////////////// +// +// Icon +// + +// Icon with lowest ID value placed first to ensure application icon +// remains consistent on all systems. +IDR_MAINFRAME ICON "res\\game.ico" + +///////////////////////////////////////////////////////////////////////////// +// +// Version +// + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 1,0,0,1 + PRODUCTVERSION 1,0,0,1 + FILEFLAGSMASK 0x3fL +#ifdef _DEBUG + FILEFLAGS 0x1L +#else + FILEFLAGS 0x0L +#endif + FILEOS 0x4L + FILETYPE 0x2L + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "\0" + VALUE "FileDescription", "HelloLua Module\0" + VALUE "FileVersion", "1, 0, 0, 1\0" + VALUE "InternalName", "HelloLua\0" + VALUE "LegalCopyright", "Copyright \0" + VALUE "OriginalFilename", "HelloLua.exe\0" + VALUE "ProductName", "HelloLua Module\0" + VALUE "ProductVersion", "1, 0, 0, 1\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x0409, 0x04B0 + END +END + +///////////////////////////////////////////////////////////////////////////// +#endif // !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) diff --git a/proj.win32/main.cpp b/proj.win32/main.cpp new file mode 100644 index 0000000..551e6c1 --- /dev/null +++ b/proj.win32/main.cpp @@ -0,0 +1,38 @@ +#include "main.h" +#include "AppDelegate.h" +#include "cocos2d.h" + +USING_NS_CC; + +// uncomment below line, open debug console +#define USE_WIN32_CONSOLE + +int APIENTRY _tWinMain(HINSTANCE hInstance, + HINSTANCE hPrevInstance, + LPTSTR lpCmdLine, + int nCmdShow) +{ + UNREFERENCED_PARAMETER(hPrevInstance); + UNREFERENCED_PARAMETER(lpCmdLine); + +#ifdef USE_WIN32_CONSOLE + AllocConsole(); + freopen("CONIN$", "r", stdin); + freopen("CONOUT$", "w", stdout); + freopen("CONOUT$", "w", stderr); +#endif + + // create the application instance + AppDelegate app; + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setViewName("OzgGameRPG"); + eglView->setFrameSize(480, 320); + + int ret = CCApplication::sharedApplication()->run(); + +#ifdef USE_WIN32_CONSOLE + FreeConsole(); +#endif + + return ret; +} diff --git a/proj.win32/main.h b/proj.win32/main.h new file mode 100644 index 0000000..d756fd1 --- /dev/null +++ b/proj.win32/main.h @@ -0,0 +1,10 @@ +#ifndef __MAIN_H__ +#define __MAIN_H__ + +#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers + +// Windows Header Files: +#include +#include + +#endif // __WINMAIN_H__ diff --git a/proj.win32/res/game.ico b/proj.win32/res/game.ico new file mode 100644 index 0000000..feaf932 Binary files /dev/null and b/proj.win32/res/game.ico differ diff --git a/proj.win32/resource.h b/proj.win32/resource.h new file mode 100644 index 0000000..53d93ae --- /dev/null +++ b/proj.win32/resource.h @@ -0,0 +1,20 @@ +//{{NO_DEPENDENCIES}} +// Microsoft Visual C++ generated include file. +// Used by game.RC +// + +#define IDS_PROJNAME 100 +#define IDR_TESTLUA 100 + +#define ID_FILE_NEW_WINDOW 32771 + +// Next default values for new objects +// +#ifdef APSTUDIO_INVOKED +#ifndef APSTUDIO_READONLY_SYMBOLS +#define _APS_NEXT_RESOURCE_VALUE 201 +#define _APS_NEXT_CONTROL_VALUE 1000 +#define _APS_NEXT_SYMED_VALUE 101 +#define _APS_NEXT_COMMAND_VALUE 32775 +#endif +#endif diff --git a/screenshot1.png b/screenshot1.png new file mode 100644 index 0000000..213fc3e Binary files /dev/null and b/screenshot1.png differ diff --git a/screenshot2.png b/screenshot2.png new file mode 100644 index 0000000..6d1051b Binary files /dev/null and b/screenshot2.png differ diff --git a/screenshot3.png b/screenshot3.png new file mode 100644 index 0000000..e1f89a0 Binary files /dev/null and b/screenshot3.png differ