cocos2dx3.4 新建项目不能用vs BabeLua调试
发布时间:2020-12-14 17:18:07 所属栏目:百科 来源:网络整理
导读:cocos2dx 3.4新建lua项目,按照 http://www.cocoachina.com/bbs/read.php?tid-205043-page-1.html 的操作,没有办法进入断点.项目可以正常运行,但是把Lua插件生成的temp项目设置成启动项目时,模拟器运行就是黑屏, 这个是日志: -------------------------------
cocos2dx 3.4新建lua项目,按照
http://www.cocoachina.com/bbs/read.php?tid-205043-page-1.html
的操作,没有办法进入断点.项目可以正常运行,但是把Lua插件生成的temp项目设置成启动项目时,模拟器运行就是黑屏,
这个是日志: --------------------------------- Setting Info ----------------------------------------- Setting name: test_lua3.4_script Lua scripts folder: E:test_lua3.4src Lua exe path: E:test_lua3.4runtimewin32test_lua3.4.exe Working path: E:test_lua3.4runtimewin32 Command line: ---------------------------------------------------------------------------------------- E:test_lua3.4runtimewin32test_lua3.4.exe Debugger attached to process 0x037501c0: VM created package.path: .?.lua;E:test_lua3.4runtimewin32lua?.lua;E:test_lua3.4runtimewin32lua?init.lua; Load script(0): E:test_lua3.4src@Untitled1.luarelative(file not exist) Load script(1): E:test_lua3.4src@Untitled2.luarelative(file not exist) Load script(2): E:test_lua3.4src@Untitled3.luarelative(file not exist) Load script(3): E:test_lua3.4src@Untitled4.luarelative(file not exist) Load script(4): E:test_lua3.4src@Untitled5.luarelative(file not exist) Load script(5): E:test_lua3.4src@Untitled6.luarelative(file not exist) Load script(6): E:test_lua3.4src@Untitled7.luarelative(file not exist) Load script(7): E:test_lua3.4src@Untitled8.luarelative(file not exist) Load script(8): E:test_lua3.4src@Untitled9.luarelative(file not exist) Load script(9): E:test_lua3.4src@Untitled10.luarelative(file not exist) 我折腾了2天,还是没有 成功,希望能帮助下,刚开始用 vs. 最开始用VS新建3.4 lua项目时,直接黑屏,不能直接运行,每次都要刷新才行.后来在AppDelegate.cpp的bool AppDelegate::applicationDidFinishLaunching()下开始的位置添加: //add search paths///////////////////////////// string strPath = CCFileUtils::getInstance()->getWritablePath(); vector<string> vtPath = CCFileUtils::getInstance()->getSearchPaths(); vtPath.push_back(strPath + "res/"); vtPath.push_back(strPath + "src/"); CCFileUtils::getInstance()->setSearchPaths(vtPath); 在src目录下的main.lua文件中加入 package.path = package.path..";src/?.lua" 这个是配置(编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |