group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
WeaponFiredEvent Struct Reference

Emitted when a weapon fires (both hitscan and projectile). More...

#include <ParticleEvents.hpp>

Public Attributes

entt::entity shooter = entt::null
WeaponType type = WeaponType::Rifle
glm::vec3 origin {}
 Muzzle world position.
glm::vec3 direction {}
 Normalised fire direction.
bool isHitscan = false
bool localPlayer = false
 True when this event originated from the listening client.
glm::vec3 hitPos {}
 Valid only when isHitscan == true.

Detailed Description

Emitted when a weapon fires (both hitscan and projectile).

Member Data Documentation

◆ direction

glm::vec3 WeaponFiredEvent::direction {}

Normalised fire direction.

◆ hitPos

glm::vec3 WeaponFiredEvent::hitPos {}

Valid only when isHitscan == true.

◆ isHitscan

bool WeaponFiredEvent::isHitscan = false

◆ localPlayer

bool WeaponFiredEvent::localPlayer = false

True when this event originated from the listening client.

◆ origin

glm::vec3 WeaponFiredEvent::origin {}

Muzzle world position.

◆ shooter

entt::entity WeaponFiredEvent::shooter = entt::null

◆ type

WeaponType WeaponFiredEvent::type = WeaponType::Rifle

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