summaryrefslogtreecommitdiff
path: root/src/game/g_cmds.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/g_cmds.c')
-rw-r--r--src/game/g_cmds.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c
index 83bfc76c..2824018a 100644
--- a/src/game/g_cmds.c
+++ b/src/game/g_cmds.c
@@ -1807,9 +1807,12 @@ void Cmd_Destroy_f( gentity_t *ent )
BG_FindNameForBuildable( traceEnt->s.modelindex ) );
if( !deconstruct )
- G_Damage( traceEnt, ent, ent, forward, tr.endpos, 10000, 0, MOD_SUICIDE );
+ G_Damage( traceEnt, ent, ent, forward, tr.endpos, ent->health, 0, MOD_SUICIDE );
else
+ {
+ G_Damage( traceEnt, ent, ent, forward, tr.endpos, ent->health, 0, MOD_SUICIDE );
G_FreeEntity( traceEnt );
+ }
if( !g_cheats.integer )
ent->client->ps.stats[ STAT_MISC ] +=