VoltMod
C++23 framework for CS2 server plugins
Loading...
Searching...
No Matches
VoltMod::PlayerHurt Struct Reference

#include <EventTypes.hpp>

Static Public Member Functions

static PlayerHurt From (IGameEvent &e)
 

Public Attributes

int Slot = -1
 player index who was hurt
 
int AttackerSlot = -1
 player index who attacked
 
int Health = 0
 remaining health points
 
int Armor = 0
 remaining armor points
 
std::string Weapon
 weapon name attacker used, if not the world
 
int DmgHealth = 0
 damage done to health
 
int DmgArmor = 0
 damage done to armor
 
VoltMod::HitGroup Hitgroup = VoltMod::HitGroup::Generic
 hitgroup that was damaged
 

Static Public Attributes

static constexpr std::string_view EventName = "player_hurt"
 

Detailed Description

Definition at line 1511 of file EventTypes.hpp.

Member Function Documentation

◆ From()

PlayerHurt VoltMod::PlayerHurt::From ( IGameEvent &  e)
static

Definition at line 1431 of file EventTypes.cpp.

References VoltMod::ReadFile(), and Slot.

Member Data Documentation

◆ Armor

int VoltMod::PlayerHurt::Armor = 0

remaining armor points

Definition at line 1517 of file EventTypes.hpp.

◆ AttackerSlot

int VoltMod::PlayerHurt::AttackerSlot = -1

player index who attacked

Definition at line 1515 of file EventTypes.hpp.

◆ DmgArmor

int VoltMod::PlayerHurt::DmgArmor = 0

damage done to armor

Definition at line 1520 of file EventTypes.hpp.

◆ DmgHealth

int VoltMod::PlayerHurt::DmgHealth = 0

damage done to health

Definition at line 1519 of file EventTypes.hpp.

◆ EventName

constexpr std::string_view VoltMod::PlayerHurt::EventName = "player_hurt"
staticconstexpr

Definition at line 1513 of file EventTypes.hpp.

◆ Health

int VoltMod::PlayerHurt::Health = 0

remaining health points

Definition at line 1516 of file EventTypes.hpp.

◆ Hitgroup

VoltMod::HitGroup VoltMod::PlayerHurt::Hitgroup = VoltMod::HitGroup::Generic

hitgroup that was damaged

Definition at line 1521 of file EventTypes.hpp.

◆ Slot

int VoltMod::PlayerHurt::Slot = -1

player index who was hurt

Definition at line 1514 of file EventTypes.hpp.

Referenced by From().

◆ Weapon

std::string VoltMod::PlayerHurt::Weapon

weapon name attacker used, if not the world

Definition at line 1518 of file EventTypes.hpp.


The documentation for this struct was generated from the following files: