3#ifndef GAME_CLIENT_COMPONENTS_PARTICLES_H
4#define GAME_CLIENT_COMPONENTS_PARTICLES_H
79 virtual int Sizeof()
const override {
return sizeof(*this); }
81 void Add(
int Group,
CParticle *pPart,
float TimePassed = 0.f);
83 virtual void OnReset()
override;
85 virtual void OnInit()
override;
104 void Update(
float TimePassed);
111 virtual int Sizeof()
const override {
return sizeof(*this); }
Definition: component.h:20
Definition: gameclient.h:124
Definition: particles.h:108
virtual int Sizeof() const override
Definition: particles.h:111
virtual void OnRender() override
Definition: particles.h:112
CParticles * m_pParts
Definition: particles.h:110
Definition: particles.h:64
CRenderGroup< GROUP_EXTRA > m_RenderExtra
Definition: particles.h:120
CRenderGroup< GROUP_PROJECTILE_TRAIL > m_RenderTrail
Definition: particles.h:116
virtual void OnInit() override
Definition: particles.cpp:169
CParticles()
Definition: particles.cpp:13
virtual int Sizeof() const override
Definition: particles.h:79
int64_t m_LastRenderTime
Definition: particles.h:101
virtual void OnReset() override
Definition: particles.cpp:23
void Update(float TimePassed)
Definition: particles.cpp:77
@ GROUP_PROJECTILE_TRAIL
Definition: particles.h:70
@ GROUP_EXTRA
Definition: particles.h:73
@ NUM_GROUPS
Definition: particles.h:75
@ GROUP_TRAIL_EXTRA
Definition: particles.h:71
@ GROUP_GENERAL
Definition: particles.h:74
@ GROUP_EXPLOSIONS
Definition: particles.h:72
float m_FrictionFraction
Definition: particles.h:100
CRenderGroup< GROUP_EXPLOSIONS > m_RenderExplosions
Definition: particles.h:119
int m_aFirstPart[NUM_GROUPS]
Definition: particles.h:98
int m_FirstFree
Definition: particles.h:97
void RenderGroup(int Group)
Definition: particles.cpp:209
@ MAX_PARTICLES
Definition: particles.h:93
CRenderGroup< GROUP_TRAIL_EXTRA > m_RenderTrailExtra
Definition: particles.h:117
int m_ExtraParticleQuadContainerIndex
Definition: particles.h:89
CParticle m_aParticles[MAX_PARTICLES]
Definition: particles.h:96
void Add(int Group, CParticle *pPart, float TimePassed=0.f)
Definition: particles.cpp:40
int m_ParticleQuadContainerIndex
Definition: particles.h:88
bool ParticleIsVisibleOnScreen(const vec2 &CurPos, float CurSize)
Definition: particles.cpp:194
virtual void OnRender() override
Definition: particles.cpp:146
CRenderGroup< GROUP_GENERAL > m_RenderGeneral
Definition: particles.h:121
Definition: particles.h:11
int m_PrevPart
Definition: particles.h:59
float m_Gravity
Definition: particles.h:50
int m_Spr
Definition: particles.h:34
float m_Rotspeed
Definition: particles.h:48
float m_LifeSpan
Definition: particles.h:38
int m_NextPart
Definition: particles.h:60
float m_EndSize
Definition: particles.h:41
ColorRGBA m_Color
Definition: particles.h:53
float m_FlowAffected
Definition: particles.h:36
void SetDefault()
Definition: particles.h:12
float m_Rot
Definition: particles.h:47
float m_EndAlpha
Definition: particles.h:45
bool m_UseAlphaFading
Definition: particles.h:43
float m_Friction
Definition: particles.h:51
float m_StartSize
Definition: particles.h:40
float m_Life
Definition: particles.h:58
vec2 m_Pos
Definition: particles.h:31
vec2 m_Vel
Definition: particles.h:32
bool m_Collides
Definition: particles.h:55
float m_StartAlpha
Definition: particles.h:44
vector2_base< float > vec2
Definition: vmath.h:158