diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/core/World.cpp | 4 | ||||
-rw-r--r-- | src/entities/Physical.cpp | 1 | ||||
-rw-r--r-- | src/objects/ParticleObject.cpp | 11 | ||||
-rw-r--r-- | src/objects/ParticleObject.h | 5 | ||||
-rw-r--r-- | src/render/Particle.cpp | 2 | ||||
-rw-r--r-- | src/render/Particle.h | 7 |
6 files changed, 18 insertions, 12 deletions
diff --git a/src/core/World.cpp b/src/core/World.cpp index 1af0c4a4..3022368b 100644 --- a/src/core/World.cpp +++ b/src/core/World.cpp @@ -2161,8 +2161,8 @@ CWorld::TriggerExplosionSectorList(CPtrList &list, const CVector &position, floa } else { CVector pos = pEntity->GetPosition(); pos.z -= 0.5f; - CParticleObject::AddObject(POBJECT_FIRE_HYDRANT, - pos, true); + CParticleObject::AddObject(POBJECT_FIRE_HYDRANT, pos, true); + CParticleObject::AddObject(POBJECT_FIRE_HYDRANT_STEAM, pos, true); pObject->bHasBeenDamaged = true; } } diff --git a/src/entities/Physical.cpp b/src/entities/Physical.cpp index 5ce7bd72..de60c400 100644 --- a/src/entities/Physical.cpp +++ b/src/entities/Physical.cpp @@ -715,6 +715,7 @@ CPhysical::ApplyCollision(CPhysical *B, CColPoint &colpoint, float &impulseA, fl int16 model = B->GetModelIndex(); if(model == MI_FIRE_HYDRANT && !Bobj->bHasBeenDamaged){ CParticleObject::AddObject(POBJECT_FIRE_HYDRANT, B->GetPosition() - CVector(0.0f, 0.0f, 0.5f), true); + CParticleObject::AddObject(POBJECT_FIRE_HYDRANT_STEAM, B->GetPosition() - CVector(0.0f, 0.0f, 0.5f), true); Bobj->bHasBeenDamaged = true; }else if(model == MI_PARKINGMETER || model == MI_PARKINGMETER2){ CPickups::CreateSomeMoney(GetPosition(), CGeneral::GetRandomNumber()%100); diff --git a/src/objects/ParticleObject.cpp b/src/objects/ParticleObject.cpp index 4d080d1f..a281062f 100644 --- a/src/objects/ParticleObject.cpp +++ b/src/objects/ParticleObject.cpp @@ -242,6 +242,16 @@ CParticleObject::AddObject(uint16 type, CVector const &pos, CVector const &targe break; } + case POBJECT_FIRE_HYDRANT_STEAM: + { + pobj->m_ParticleType = PARTICLE_HYDRANT_STEAM; + pobj->m_nNumEffectCycles = 2; + pobj->m_nSkipFrames = 2; + pobj->m_nCreationChance = 8; + pobj->m_nRemoveTimer = CTimer::GetTimeInMilliseconds() + 5000; + break; + } + case POBJECT_CAR_WATER_SPLASH: case POBJECT_PED_WATER_SPLASH: { @@ -921,6 +931,7 @@ void CParticleObject::UpdateClose(void) CParticle::AddParticle(PARTICLE_CAR_SPLASH, splashpos, splashvel, nil, CGeneral::GetRandomNumberInRange(0.005f, 0.0075f), this->m_Color, 0, 0, 1, 300); } + for ( int32 i = 0; i < this->m_nNumEffectCycles; i++ ) { CParticle::AddParticle(this->m_ParticleType, pos, vel, nil, 0.0f, this->m_Color); diff --git a/src/objects/ParticleObject.h b/src/objects/ParticleObject.h index f199e533..1ac29451 100644 --- a/src/objects/ParticleObject.h +++ b/src/objects/ParticleObject.h @@ -15,6 +15,7 @@ enum eParticleObjectType POBJECT_WALL_STEAM_SLOWMOTION, POBJECT_DARK_SMOKE, POBJECT_FIRE_HYDRANT, + POBJECT_FIRE_HYDRANT_STEAM, POBJECT_CAR_WATER_SPLASH, POBJECT_PED_WATER_SPLASH, POBJECT_SPLASHES_AROUND, @@ -49,7 +50,7 @@ public: CParticleObject *m_pNext; CParticleObject *m_pPrev; CParticle *m_pParticle; - uint32 m_nRemoveTimer; + uint32 m_nRemoveTimer; eParticleObjectType m_Type; tParticleType m_ParticleType; uint8 m_nNumEffectCycles; @@ -109,4 +110,4 @@ public: static void Remove(CParticleObject *particleobject); static CAudioHydrant *Get(int n); // for neo screen droplets -};
\ No newline at end of file +}; diff --git a/src/render/Particle.cpp b/src/render/Particle.cpp index d6ee36a1..660ed5c2 100644 --- a/src/render/Particle.cpp +++ b/src/render/Particle.cpp @@ -2283,7 +2283,7 @@ void CParticle::HandleShootableBirdsStuff(CEntity *entity, CVector const&camPos) } void -CEntity::AddSteamsFromGround(CVector *unused) //todo +CEntity::AddSteamsFromGround(CVector *unused) { int i, n; C2dEffect *effect; diff --git a/src/render/Particle.h b/src/render/Particle.h index edfd9b77..a306f0c4 100644 --- a/src/render/Particle.h +++ b/src/render/Particle.h @@ -30,13 +30,6 @@ public: uint8 m_nCurrentFrame; RwRGBA m_Color; CParticle *m_pNext; - - //CVector m_vecParticleMovementOffset; - //int16 m_nCurrentZRotation; - //uint16 m_nZRotationTimer; - //float m_fCurrentZRadius; - //uint16 m_nZRadiusTimer; - int32 field_4C; CParticle() |