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
sv_friendlyfireCategories
Parameters
- FF (0/1): allow to hurt teammates?
Info
Select if you want players to be able to hurt and even kill their teammates (1) or not (0, default). In game modes without teams this setting has no effect because you can kill everyone anyway. However there are some additional things which are affected by this setting:
It also controls the damage of your own weapons on yourself. You can hurt yourself with your own grenades for instance when friendly fire is enabled. You can't hurt yourself this way when friendly fire is disabled.
Turrets never hurt yourself or teammates. The only exception is deathmatch mode where your own turret can kill you when friendly fire is enabled (it won't aim at you but you can get hurt when you are standing in its line of fire).
Lua Hooks
Lua Commands
Categories
Parameters
- FF (0/1): allow to hurt teammates?
Info
Select if you want players to be able to hurt and even kill their teammates (1) or not (0, default). In game modes without teams this setting has no effect because you can kill everyone anyway. However there are some additional things which are affected by this setting:
It also controls the damage of your own weapons on yourself. You can hurt yourself with your own grenades for instance when friendly fire is enabled. You can't hurt yourself this way when friendly fire is disabled.
Turrets never hurt yourself or teammates. The only exception is deathmatch mode where your own turret can kill you when friendly fire is enabled (it won't aim at you but you can get hurt when you are standing in its line of fire).
It also controls the damage of your own weapons on yourself. You can hurt yourself with your own grenades for instance when friendly fire is enabled. You can't hurt yourself this way when friendly fire is disabled.
Turrets never hurt yourself or teammates. The only exception is deathmatch mode where your own turret can kill you when friendly fire is enabled (it won't aim at you but you can get hurt when you are standing in its line of fire).