From: Mario Date: Sun, 12 Jun 2016 18:29:24 +0000 (+1000) Subject: Fix captureshield texture, also make entrap affect monsters X-Git-Tag: xonotic-v0.8.2~807^2~2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=ed58bc3fc0da3aeaf5421ee59bc9bd83e3838cdd;p=xonotic%2Fxonotic-data.pk3dir.git Fix captureshield texture, also make entrap affect monsters --- diff --git a/models/ctf/shield.md3_0.skin b/models/ctf/shield.md3_0.skin index 754fce734..113f275d4 100644 --- a/models/ctf/shield.md3_0.skin +++ b/models/ctf/shield.md3_0.skin @@ -1 +1 @@ -shield,shield +shield,ons_shield diff --git a/qcsrc/common/mutators/mutator/nades/nades.qc b/qcsrc/common/mutators/mutator/nades/nades.qc index 65387f5ad..e3fb4b68b 100644 --- a/qcsrc/common/mutators/mutator/nades/nades.qc +++ b/qcsrc/common/mutators/mutator/nades/nades.qc @@ -584,7 +584,7 @@ void nade_entrap_touch(entity this) #endif } - if ( IS_REAL_CLIENT(other) || IS_VEHICLE(other) ) + if ( IS_REAL_CLIENT(other) || IS_VEHICLE(other) || IS_MONSTER(other) ) { entity show_tint = (IS_VEHICLE(other)) ? other.owner : other; STAT(ENTRAP_ORB, show_tint) = time + 0.1; @@ -1320,6 +1320,17 @@ MUTATOR_HOOKFUNCTION(nades, PlayerPhysics) } } +MUTATOR_HOOKFUNCTION(nades, MonsterMove) +{ + entity mon = M_ARGV(0, entity); + + if (STAT(ENTRAP_ORB, mon) > time) + { + M_ARGV(1, float) *= autocvar_g_nades_entrap_speed; // run speed + M_ARGV(2, float) *= autocvar_g_nades_entrap_speed; // walk speed + } +} + MUTATOR_HOOKFUNCTION(nades, PlayerSpawn) { entity player = M_ARGV(0, entity);