GS-EntBase: Fix some more places where remove() was being called directly when it shouldn't be
This commit is contained in:
parent
b593c2694b
commit
41ccbca2aa
4 changed files with 3 additions and 6 deletions
|
@ -113,9 +113,7 @@ ambient_generic::ambient_generic(void)
|
|||
void
|
||||
ambient_generic::OnRemoveEntity(void)
|
||||
{
|
||||
#ifdef SERVER
|
||||
sound(this, CHAN_BODY, "common/null.wav", 0.1f, 0);
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef SERVER
|
||||
|
|
|
@ -268,8 +268,7 @@ env_bubbles::EmitBubbles(void)
|
|||
|
||||
/* destroy the bubble once it exits out the water */
|
||||
timer = (size[2] / eBubble.velocity[2]);
|
||||
eBubble.think = Util_Destroy;
|
||||
eBubble.nextthink = time + timer;
|
||||
eBubble.ScheduleThink(Destroy, timer);
|
||||
}
|
||||
|
||||
nextthink = time + m_flFrequency;
|
||||
|
|
|
@ -856,7 +856,7 @@ through your own hoops. This however will be sufficient 99,99% of the time.
|
|||
void NSEntity::Destroy( void ) {
|
||||
removed = 1; /* mark this as cleanly removed */
|
||||
OnRemoveEntity();
|
||||
ScheduleThink( Util_Destroy, 0.0f );
|
||||
ScheduleThink(Util_Destroy, 0.0f );
|
||||
}
|
||||
|
||||
void NSEntity::Show( void ) {
|
||||
|
|
|
@ -575,7 +575,7 @@ BreakModel_SpawnID(vector smins, vector smaxs, vector dir, float speed, int coun
|
|||
gib.velocity[2] += (random() - 0.5) * (speed * 0.25);
|
||||
gib.SetAngularVelocity(vectoangles(gib.velocity));
|
||||
gib.SetMovetype(MOVETYPE_BOUNCE);
|
||||
gib.ScheduleThink(Util_Destroy, fadetime);
|
||||
gib.ScheduleThink(NSEntity::Destroy, fadetime);
|
||||
|
||||
#ifdef CLIENT
|
||||
gib.drawmask = MASK_ENGINE;
|
||||
|
|
Loading…
Reference in a new issue