group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
ParticleEvents.hpp
Go to the documentation of this file.
1
3
4#pragma once
5
7
8#include <entt/entt.hpp>
9#include <glm/glm.hpp>
10
13{
14 entt::entity shooter = entt::null;
16 glm::vec3 origin{};
17 glm::vec3 direction{};
18 bool isHitscan = false;
19 glm::vec3 hitPos{};
20};
21
30
33{
34 glm::vec3 pos{};
35 float blastRadius = 100.f;
36};
Projectile component and weapon/surface type enumerations.
SurfaceType
Surface material hit by a projectile — drives impact effect parameters.
Definition Projectile.hpp:21
WeaponType
Weapon type — determines tracer style, damage, sound, and impact effects.
Definition Projectile.hpp:11
@ Rifle
Fast hitscan/projectile (R301-style capsule tracer)
Emitted when a rocket/grenade explodes.
Definition ParticleEvents.hpp:33
glm::vec3 pos
Definition ParticleEvents.hpp:34
float blastRadius
Definition ParticleEvents.hpp:35
Emitted when a projectile or hitscan hits a surface.
Definition ParticleEvents.hpp:24
glm::vec3 pos
Definition ParticleEvents.hpp:25
glm::vec3 normal
Definition ParticleEvents.hpp:26
WeaponType weaponType
Definition ParticleEvents.hpp:28
SurfaceType surface
Definition ParticleEvents.hpp:27
Emitted when a weapon fires (both hitscan and projectile).
Definition ParticleEvents.hpp:13
bool isHitscan
Definition ParticleEvents.hpp:18
entt::entity shooter
Definition ParticleEvents.hpp:14
WeaponType type
Definition ParticleEvents.hpp:15
glm::vec3 direction
Normalised fire direction.
Definition ParticleEvents.hpp:17
glm::vec3 origin
Muzzle world position.
Definition ParticleEvents.hpp:16
glm::vec3 hitPos
Valid only when isHitscan == true.
Definition ParticleEvents.hpp:19