Commands/Lua
Reference for console commands, Lua hooks and Lua commands in CS2D.
- Console Commands are entered in console, executed with key-binds, cfg-files or with Lua parse
- Lua Hooks execute Lua when events occur - some have a return value which can change the game behavior
- Lua Commands are used to retrieve game data or to perform actions in Lua scripts
CS2D Console Commands
mp_idleactionCategories
Parameters
- action (0-4): 0 kick, 1 make spec., 2 slap, 3 kill, 4 show message
Info
Peform this action if mp_idlekick is 1 and if a player was idle too long (mp_idletime).
Possible actions are:
- 0 - kick player (default)
- 1 - switch the team of the player to spectator
- 2 - slap the player
- 3 - kill the player
- 4 - show a message that the player is idle
Lua Hooks
Lua Commands
Categories
Parameters
- action (0-4): 0 kick, 1 make spec., 2 slap, 3 kill, 4 show message
Info
Peform this action if mp_idlekick is 1 and if a player was idle too long (mp_idletime).
Possible actions are:
Possible actions are:
- 0 - kick player (default)
- 1 - switch the team of the player to spectator
- 2 - slap the player
- 3 - kill the player
- 4 - show a message that the player is idle