summaryrefslogtreecommitdiffstats
path: root/src/render/Particle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/render/Particle.cpp')
-rw-r--r--src/render/Particle.cpp35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/render/Particle.cpp b/src/render/Particle.cpp
index 844b6acd..08137d0c 100644
--- a/src/render/Particle.cpp
+++ b/src/render/Particle.cpp
@@ -3,6 +3,7 @@
#include "General.h"
#include "Timer.h"
#include "TxdStore.h"
+#include "Entity.h"
#include "Sprite.h"
#include "Camera.h"
#include "Collision.h"
@@ -585,6 +586,40 @@ void CParticle::Initialise()
debug("CParticle ready");
}
+void
+CEntity::AddSteamsFromGround(CVector *unused)
+{
+ int i, n;
+ C2dEffect *effect;
+ CVector pos;
+
+ n = CModelInfo::GetModelInfo(GetModelIndex())->GetNum2dEffects();
+ for(i = 0; i < n; i++){
+ effect = CModelInfo::GetModelInfo(GetModelIndex())->Get2dEffect(i);
+ if(effect->type != EFFECT_PARTICLE)
+ continue;
+
+ pos = GetMatrix() * effect->pos;
+ switch(effect->particle.particleType){
+ case 0:
+ CParticleObject::AddObject(POBJECT_PAVEMENT_STEAM, pos, effect->particle.dir, effect->particle.scale, false);
+ break;
+ case 1:
+ CParticleObject::AddObject(POBJECT_WALL_STEAM, pos, effect->particle.dir, effect->particle.scale, false);
+ break;
+ case 2:
+ CParticleObject::AddObject(POBJECT_DRY_ICE, pos, effect->particle.scale, false);
+ break;
+ case 3:
+ CParticleObject::AddObject(POBJECT_SMALL_FIRE, pos, effect->particle.dir, effect->particle.scale, false);
+ break;
+ case 4:
+ CParticleObject::AddObject(POBJECT_DARK_SMOKE, pos, effect->particle.dir, effect->particle.scale, false);
+ break;
+ }
+ }
+}
+
void CParticle::Shutdown()
{
debug("Shutting down CParticle...");