Add more vars to actions
New:
- Lifted restriction of 2 vars per state (maximum is now 8)
- Lifted restriction of 2 arguments per action
- Lua: Added
vars[]to states- This is 1-indexed, so
vars[1]is the first var,vars[2]is the second var, etc. - Accepts a table when setting (maximum accepted amount of vars is 8)
- This is 1-indexed, so
- SOC: Added
VAR3toVAR8 - Added dynamic typing to vars. Types:
- integer
- boolean (
true,false) - string
- null
Backwards compatible:
-
state.var1is equivalent tostate.vars[1] -
state.var2is equivalent tostate.vars[2]
Backwards incompatible:
- Calling actions scripted with Lua without the sufficient number of arguments will push
nilinstead of the number zero.
Example for testing: action_test.wad
Edited by Lactozilla