From: terencehill Date: Sat, 10 Sep 2016 15:06:54 +0000 (+0200) Subject: Fix #1810 generator doesn't show any explosion effect when it gets destroyed X-Git-Tag: xonotic-v0.8.2~603 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=3aa40f94096d905e54d5cddcc2aa478b1b055d56;p=xonotic%2Fxonotic-data.pk3dir.git Fix #1810 generator doesn't show any explosion effect when it gets destroyed --- diff --git a/qcsrc/common/gamemodes/gamemode/onslaught/cl_generator.qc b/qcsrc/common/gamemodes/gamemode/onslaught/cl_generator.qc index cbba9a9aa..54ced2fb1 100644 --- a/qcsrc/common/gamemodes/gamemode/onslaught/cl_generator.qc +++ b/qcsrc/common/gamemodes/gamemode/onslaught/cl_generator.qc @@ -149,7 +149,10 @@ void generator_construct(entity this, bool isnew) this.classname = "onslaught_generator"; if(isnew) + { IL_PUSH(g_onsgenerators, this); + IL_PUSH(g_drawables, this); + } setorigin(this, this.origin); setmodel(this, MDL_ONS_GEN); diff --git a/qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc b/qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc index 28fcaeb9d..d6606a370 100644 --- a/qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc +++ b/qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc @@ -827,7 +827,7 @@ void ons_GeneratorDamage(entity this, entity inflictor, entity attacker, float d { if (this.isshielded) { - // this is protected by a shield, so ignore the damage + // generator is protected by a shield, so ignore the damage if (time > this.pain_finished) if (IS_PLAYER(attacker)) {