diff options
author | Christopher Schwarz <lakitu7@gmail.com> | 2010-05-23 19:11:12 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2013-01-03 00:17:37 +0000 |
commit | 0cfc3bbfe7da1c26a6dc0646d5973e3a65878d2f (patch) | |
tree | b37398021bad0256696c39a5c5f628488c67d630 /src/game/g_buildable.c | |
parent | 034057319870cc058097190434b1199cec206187 (diff) |
* (bug 4638) Fix behavior of structure power when moving the reactor into repeaters' BP zones causes it to be providing more than its max power (Rezyn)
Diffstat (limited to 'src/game/g_buildable.c')
-rw-r--r-- | src/game/g_buildable.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/src/game/g_buildable.c b/src/game/g_buildable.c index 5579be34..5bf063dc 100644 --- a/src/game/g_buildable.c +++ b/src/game/g_buildable.c @@ -267,14 +267,8 @@ qboolean G_FindPower( gentity_t *self, qboolean searchUnspawned ) } } - // If there were no power items nearby give up - if( closestPower ) - { - self->parentNode = closestPower; - return qtrue; - } - else - return qfalse; + self->parentNode = closestPower; + return self->parentNode != NULL; } /* @@ -1757,6 +1751,7 @@ void HRepeater_Think( gentity_t *self ) { // if the repeater is inside of another power zone then disappear G_Damage( self, NULL, NULL, NULL, NULL, self->health, 0, MOD_SUICIDE ); + return; } self->powered = reactor; |