Development Modes
Script-based Projects
After placing LGameObject in the level, add the LScriptComponent to LGameObject
Write the script, add the on_begin_play function to the script, write relevant logic
Add on_end_play function in the script, write relevant logic
Bind the LScriptComponent on the LGameObject to the script
You can also implement new types by inheriting types from C++ based on Lua scripts.
C++ Based Projects
Add C++ DLL Project
Select the type needs to be inherited (LGameInstance, LCharacter, LGameMode, etc.) and write relevant code in C++
Configure the DLL for the project to load
Compile and run
Comparison of Two Development Modes
Script-based projects can quickly build project prototype, while C++ based project has more in-depth customization features, better compile-time check and performance.