Commands/Lua

Reference for console commands, Lua hooks and Lua commands in CS2D.

CS2D Command CS2D Console Commands

Category: server (201)

CS2D Command mp_shotweakening

Categories

Parameters

  • weakening (0-100): How much are shots weakened per hit (in percent)?

Info

Controls how much the force/damage of shots is weakened when they hit a player/hostage/NPC or image hitzone.

The default value for this setting is 30 (=30% damage reduction per hit).

Sample scenario with 30%:
A player shoots into a row of other players with a weapon which causes 100 damage.
- The first player will suffer full 100 damage
- The second player will suffer 30% less (actual calculation is 100*(1.0-0.3)), hence 70 damage
- The third player will suffer another 30% damage less, which is 49
- etc.

Set this value to 0 if you don't want the shot to be weakened (this is how shots worked in CS2D Beta 0.1.2.1 and prior versions).
Set it to 100 if you want only the first target to suffer damage at all. Note that the visual effects of the shot will be displayed in full length anyway (it will not stop at the first target even though it doesn't cause any damage on all following targets).

Note: The damage received is rounded up (Ceil) for shot weakening. So if the calculation leads to something like 25.01 damage, the actual damage will be 26.

Lua Hook Lua Hooks

Lua Command Lua Commands