X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fmutators%2Fgamemode_onslaught.qc;h=fd7f305c910c2859bd528e72d5fb9ec29ae62aba;hb=57f409333cc09406298b66421d5e99357a7f586d;hp=b5b6594d70d384b89ed595692240acd4edf0b3be;hpb=1ea3b0365fd6fbb31c38cf6d22ee0b952e9010c1;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/mutators/gamemode_onslaught.qc b/qcsrc/server/mutators/gamemode_onslaught.qc index b5b6594d7..fd7f305c9 100644 --- a/qcsrc/server/mutators/gamemode_onslaught.qc +++ b/qcsrc/server/mutators/gamemode_onslaught.qc @@ -510,7 +510,7 @@ void onslaught_generator_deaththink() vector org; float i; - if not (self.count) + if (!self.count) self.count = 40; // White shockwave @@ -614,7 +614,7 @@ void onslaught_generator_damage(entity inflictor, entity attacker, float damage, #endif self.lasthealth = self.health; } - else if not(warmup_stage) + else if (!warmup_stage) { if (attacker == self) bprint(Team_ColoredFullName(self.team), " generator spontaneously exploded due to overtime!\n"); @@ -1271,7 +1271,7 @@ void onslaught_controlpoint_touch() { entity e; float a; - if not(IS_PLAYER(other)) + if (!IS_PLAYER(other)) return; a = onslaught_controlpoint_attackable(self, other.team); if(a != 2 && a != 4) @@ -1304,6 +1304,12 @@ void onslaught_controlpoint_touch() onslaught_updatelinks(); } +void onslaught_controlpoint_think() +{ + self.nextthink = time; + CSQCMODEL_AUTOUPDATE(); +} + void onslaught_controlpoint_reset() { if(self.goalentity && self.goalentity != world) @@ -1316,8 +1322,9 @@ void onslaught_controlpoint_reset() self.isshielded = TRUE; self.enemy.solid = SOLID_NOT; self.enemy.colormap = self.colormap; - self.think = self.enemy.think = func_null; - self.nextthink = 0; // don't like func_null :P + self.think = onslaught_controlpoint_think; + self.enemy.think = func_null; + self.nextthink = time; // don't like func_null :P setmodel(self, "models/onslaught/controlpoint_pad.md3"); //setsize(self, '-32 -32 0', '32 32 8'); @@ -1327,6 +1334,8 @@ void onslaught_controlpoint_reset() activator = self; SUB_UseTargets(); // to reset the structures, playerspawns etc. + + CSQCMODEL_AUTOUPDATE(); } /*QUAKED spawnfunc_onslaught_controlpoint (0 .5 .8) (-32 -32 0) (32 32 128) @@ -1397,6 +1406,9 @@ void spawnfunc_onslaught_controlpoint() self.enemy.colormap = self.colormap; waypoint_spawnforitem(self); + + self.think = onslaught_controlpoint_think; + self.nextthink = time; WaypointSprite_SpawnFixed(string_null, self.origin + '0 0 128', self, sprite, RADARICON_NONE, '0 0 0'); WaypointSprite_UpdateRule(self.sprite, NUM_TEAM_2, SPRITERULE_TEAMPLAY); @@ -1404,6 +1416,8 @@ void spawnfunc_onslaught_controlpoint() onslaught_updatelinks(); self.reset = onslaught_controlpoint_reset; + + CSQCMODEL_AUTOINIT(); } float onslaught_link_send(entity to, float sendflags)