]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/mutators/mutator_touchexplode.qc
Hook: merge offhand and weapon behaviour
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / mutators / mutator_touchexplode.qc
index 5ceeff34b5f4ab365744a9c8d999e7fe6036fedd..faa74bb1dcf74e989eeb50311e1b83c82bd1fba6 100644 (file)
@@ -5,13 +5,13 @@
 .float touchexplode_time;
 
 void PlayerTouchExplode(entity p1, entity p2)
-{
+{SELFPARAM();
        vector org;
        org = (p1.origin + p2.origin) * 0.5;
        org.z += (p1.mins.z + p2.mins.z) * 0.5;
 
-       sound(self, CH_TRIGGER, W_Sound("grenade_impact"), VOL_BASE, ATTEN_NORM);
-       Send_Effect("explosion_small", org, '0 0 0', 1);
+       sound(self, CH_TRIGGER, SND_GRENADE_IMPACT, VOL_BASE, ATTEN_NORM);
+       Send_Effect(EFFECT_EXPLOSION_SMALL, org, '0 0 0', 1);
 
        entity e;
        e = spawn();
@@ -21,7 +21,7 @@ void PlayerTouchExplode(entity p1, entity p2)
 }
 
 MUTATOR_HOOKFUNCTION(touchexplode_PlayerThink)
-{
+{SELFPARAM();
        if(time > self.touchexplode_time)
        if(!gameover)
        if(!self.frozen)