summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIronClawTrem <louie.nutman@gmail.com>2020-03-09 15:39:49 +0000
committerIronClawTrem <louie.nutman@gmail.com>2020-03-09 15:39:49 +0000
commit07cb505e8189041d26e40e3d4eeabb9957028bd1 (patch)
tree03614455bfa17eeeef3d9b7e9a7da6989b422d0e
parent43f455243b9590f757513504e56d56af263068ec (diff)
fix booster aura working before booster is finished building
-rw-r--r--src/game/g_buildable.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/game/g_buildable.c b/src/game/g_buildable.c
index d8612d6..722bbb5 100644
--- a/src/game/g_buildable.c
+++ b/src/game/g_buildable.c
@@ -1549,6 +1549,9 @@ void ABooster_Think( gentity_t *self )
self->nextthink = level.time + BG_FindNextThinkForBuildable( self->s.modelindex );
+ if( !self->spawned || !self->powered || self->health <= 0 )
+ return;
+
VectorSet( range, REGEN_BOOST_RANGE, REGEN_BOOST_RANGE,
REGEN_BOOST_RANGE );
VectorAdd( self->r.currentOrigin, range, maxs );