]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge branch 'master' into Lyberta/StandaloneOverkillWeapons
authorLyberta <lyberta@lyberta.net>
Sat, 5 Aug 2017 02:45:28 +0000 (05:45 +0300)
committerLyberta <lyberta@lyberta.net>
Sat, 5 Aug 2017 02:45:28 +0000 (05:45 +0300)
qcsrc/client/mutators/events.qh
qcsrc/common/effects/qc/damageeffects.qc
qcsrc/common/mutators/mutator/overkill/rpc.qh

index b3c0b0dfbfcf484f292292f8554125c7c154b889..24d634ce8213e05759f7afed13f2f0b011be5146 100644 (file)
@@ -186,3 +186,11 @@ MUTATOR_HOOKABLE(HUD_Contents, EV_NO_ARGS);
        /** is local */                 i(bool, MUTATOR_ARGV_1_bool) \
        /**/
 MUTATOR_HOOKABLE(ForcePlayermodels_Skip, EV_ForcePlayermodels_Skip);
+
+/** Called when damage info is received on the client, useful for playing explosion effects */
+#define EV_DamageInfo(i, o) \
+       /** entity id */                i(entity, MUTATOR_ARGV_0_entity) \
+       /** death type */               i(int, MUTATOR_ARGV_1_int) \
+       /** hit origin */               i(vector, MUTATOR_ARGV_2_vector) \
+       /**/
+MUTATOR_HOOKABLE(DamageInfo, EV_DamageInfo);
index c62bbd6b68cd5b08c5108a9b0c0dd9ac77598693..38241c2cc2df62999807f2cc2b153580a2c40d15 100644 (file)
@@ -390,6 +390,8 @@ NET_HANDLE(ENT_CLIENT_DAMAGEINFO, bool isNew)
                }
        }
 
+       MUTATOR_CALLHOOK(DamageInfo, this, w_deathtype, w_org);
+
        // TODO spawn particle effects and sounds based on w_deathtype
        if(!DEATH_ISSPECIAL(w_deathtype))
        if(!hitplayer || rad) // don't show ground impacts for hitscan weapons if a player was hit
index d4d5c1772e4fd0ec620c12070959732738493242..512f51a70336e97565a3ee6c8343e558f5bbc0da 100644 (file)
@@ -2,7 +2,7 @@
 
 CLASS(RocketPropelledChainsaw, Weapon)
 /* ammotype  */ ATTRIB(RocketPropelledChainsaw, ammo_field, .int, ammo_rockets);
-/* impulse   */ ATTRIB(RocketPropelledChainsaw, impulse, int, 7);
+/* impulse   */ ATTRIB(RocketPropelledChainsaw, impulse, int, 9);
 /* flags     */ ATTRIB(RocketPropelledChainsaw, spawnflags, int, WEP_FLAG_MUTATORBLOCKED | WEP_FLAG_HIDDEN | WEP_FLAG_NORMAL | WEP_FLAG_CANCLIMB | WEP_FLAG_RELOADABLE | WEP_TYPE_SPLASH | WEP_FLAG_SUPERWEAPON);
 /* rating    */ ATTRIB(RocketPropelledChainsaw, bot_pickupbasevalue, float, 10000);
 /* color     */ ATTRIB(RocketPropelledChainsaw, wpcolor, vector, '0.5 0.5 0');