|
VoltMod
C++23 framework for CS2 server plugins
|
Holds one pawn still and gives its move type back to that pawn only, so a player who respawns while held never inherits the dead body's. Keep one per player. More...
#include <MovementFreeze.hpp>
Public Member Functions | |
| void | Hold (const Pawn &pawn) |
| void | Release (const Pawn &pawn) |
| void | Sync (const Pawn &pawn) |
| operator bool () const noexcept | |
Holds one pawn still and gives its move type back to that pawn only, so a player who respawns while held never inherits the dead body's. Keep one per player.
Definition at line 13 of file MovementFreeze.hpp.
Freeze pawn. Does nothing when a pawn is already held, or when pawn cannot be.
Definition at line 6 of file MovementFreeze.cpp.
References VoltMod::Schema::MOVETYPE_NONE, and VoltMod::ReadFile().
Referenced by Sync().
|
inlineexplicitnoexcept |
Whether a pawn is being held.
Definition at line 27 of file MovementFreeze.hpp.
Give pawn its move type back if it is the one being held, then forget it.
Definition at line 19 of file MovementFreeze.cpp.
References VoltMod::ReadFile().
Carry the hold across a respawn: forget a replaced pawn without writing to it, then hold pawn.
Definition at line 33 of file MovementFreeze.cpp.
References Hold(), and VoltMod::ReadFile().