Preface
I am a Java back-end developer, and I despised my front-end colleagues when they debugged Lua code without thinking. Baidu worked hard to write a Lua script document for debugging Unity.
operate
1.Install lua
Lua official website download page
2.idea installs the plug-in emmylua
3.idea opens unity’s lua script
-
idea->file->open select the corresponding directory
-
idea->file->project structure->sdks select + number
4. Configure startup parameters
5. Copy the code in the box and find Main.lua in unity
6. Run
Run unity and run idea debugging
7.Testing
Call it a day.
This article is original. Please declare when reprinting.
appendix:
Unity version 2019.2.21f1 lua script version < native version
idea version 2022.1.1
Lua version (windows version lua5.4.2)