mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-11-26 22:13:01 +00:00
1.6 KiB
1.6 KiB
⏪ Lua Reference
Setting up Visual Studio Code will allow you to have all of the modern benefits of IDEs like autocomplete.
- Install the
Lua
extension bysumneko
in VS Code:
- Goto settings (
ctrl+,
) and typediagnostics disable
in the settings search bar:
- Add a new item called
lowercase-global
and clickok
- Type
workspace library
in the settings search bar:
- Add a new item containing the location of
<your repro>/autogen/lua_definitions
Note: For your custom functions you will need to provide type definitions to get autocomplete.
For instance, this will not autocomplete for the mario struct:
function mario_update(m)
-- code here
end
But this will autocomplete for the mario struct:
--- @param m MarioState
function mario_update(m)
-- code here
end