summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/game/g_buildable.c11
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;