From: Mario Date: Sun, 4 Aug 2019 05:43:52 +0000 (+1000) Subject: Fix allow_jumpoff code so 2D monsters can turn around at ledges X-Git-Tag: xonotic-v0.8.5~1429 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=7dc3f659abb5a7cc04314ef34c9cbe92ffedbe02;p=xonotic%2Fxonotic-data.pk3dir.git Fix allow_jumpoff code so 2D monsters can turn around at ledges --- diff --git a/qcsrc/common/monsters/sv_monsters.qc b/qcsrc/common/monsters/sv_monsters.qc index 97a68b5f8..0619a5ded 100644 --- a/qcsrc/common/monsters/sv_monsters.qc +++ b/qcsrc/common/monsters/sv_monsters.qc @@ -1095,15 +1095,12 @@ void Monster_Move_2D(entity this, float mspeed, bool allow_jumpoff) if(trace_ent && IS_MONSTER(trace_ent)) reverse = true; - // TODO: fix this... tracing is broken if the floor is thin - /* if(!allow_jumpoff) { - a = b - '0 0 32'; - traceline(b, a, MOVE_WORLDONLY, this); + traceline(b, b - '0 0 32', MOVE_NORMAL, this); if(trace_fraction == 1.0) reverse = true; - } */ + } if(reverse) { diff --git a/qcsrc/common/monsters/sv_spawner.qc b/qcsrc/common/monsters/sv_spawner.qc index d3f4ee740..13c98e93f 100644 --- a/qcsrc/common/monsters/sv_spawner.qc +++ b/qcsrc/common/monsters/sv_spawner.qc @@ -16,6 +16,7 @@ void spawner_use(entity this, entity actor, entity trigger) e.noalign = this.noalign; e.angles = this.angles; e.monster_skill = this.monster_skill; + e.skin = this.skin; e = spawnmonster(e, this.spawnmob, 0, this, this, this.origin, false, true, this.monster_moveflags); }