issue #707: require works ok on iOS

This commit is contained in:
minggo 2011-09-05 17:42:08 +08:00
parent d6cc12ffe4
commit edb86b1154
2 changed files with 2 additions and 1 deletions

View File

@ -111,6 +111,7 @@ bool AppDelegate::applicationDidFinishLaunching()
#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_IOS)
string path = CCFileUtils::fullPathFromRelativePath("hello.lua");
CCScriptEngineManager::sharedScriptEngineManager()->getScriptEngine()->addSearchPath(path.substr(0, path.find_last_of("/")).c_str());
CCScriptEngineManager::sharedScriptEngineManager()->getScriptEngine()->executeScriptFile(path.c_str());
#endif

View File

@ -1 +1 @@
5aad4711f8c4040a3bfef0c18ca11e79718ccb0f
0eeb5b0e70a2884281fd6d16e58654dd2012c7ce