The Lua Console provides an in-game interface where you can run Lua commands.
Property | Function |
---|---|
Visible | If ticked, the console is visible |
Min Size | The minimum size of the Lua console window |
Max History | The number of previous Lua commands to remember |
During gameplay, ~+L
(tilde plus the L key) toggles the console, which allows you to enter Lua commands and see their results. You can use the up and down arrow keys to move through the history of your Lua commands.
The Lua Console is useful for debugging Lua commands and examining the internal state of the Lua environment. For example, if you have a dialogue entry that's supposed to set a variable to a certain value, you can use the console to confirm that the variable is set. The console displays the return values of your commands. It doesn't display the output of print statements. To examine the value of a variable, use syntax such as:
return Actor['Player'].Name
You can also use the console to manually set values if you want to test specific parts of your conversations.
<< Lua Examples | Using NLua >>