Breakpoint debugging support for cocos2dx-lua

Source: Internet
Author: User

Cocos2dx 3.2 supports Cocos code ide quite well. However, the editor doesn't feel comfortable with sublime.

Cocos code ide supports Lua project creation, but the default project creation does not support custom native code. What should I do.

Open source is good. Get all the relevant C ++ code from its template and add it to the project.

Specific path: cocos2d-x-3.2 \ Templates \ LUA-template-runtime

Runtime-Src \ classs, runtime-Src \ Win32, etc.

In other words, there is still a file named config. JSON, Which is boring and uses Lua. Why can't we fix it with Lua?

I don't know if it's my manual project or what, so I have to add the following two macros for normal compilation.

Glfw_expose_native_win32
Glfw_expose_native_wgl

Cocos2dx is compiled using cmake in Linux. Why does it not support cmake in win. What a wonderful thing

Note: Remember appdelegate. executescriptfile (src/main. lua) Remember to remove it. Otherwise, simulatorwindow will first load a scenario. Loading main in advance will cause the scenario you want to be replaced by the scenario supported by debugging.

Because the start button of the debugging interface will re-load src/Main. Lua, normally src/Main. Lua will load the login interface,

If the file has already been loaded, Lua will not load the file any more, causing the login interface to crash.

In addition, if another Lua file is used for require, the executescriptfile will be executed again at this time.

 

Breakpoint debugging support for cocos2dx-lua

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.