]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/weapons/weapon/crylink.qc
s/(void)/()
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / weapons / weapon / crylink.qc
index 75eb2f710061dfa0632cb2c283ec5c69e549fbc2..252cc56dc80929c2d935b0db16697b515f3339ce 100644 (file)
@@ -108,7 +108,7 @@ void W_Crylink_Dequeue(entity e)
        W_Crylink_Dequeue_Raw(e.realowner, e.queueprev, e, e.queuenext);
 }
 
-void W_Crylink_Reset(void)
+void W_Crylink_Reset()
 {SELFPARAM();
        W_Crylink_Dequeue(self);
        remove(self);
@@ -225,7 +225,7 @@ vector W_Crylink_LinkJoin(entity e, float jspeed)
        return targ_origin;
 }
 
-void W_Crylink_LinkJoinEffect_Think(void)
+void W_Crylink_LinkJoinEffect_Think()
 {SELFPARAM();
        // is there at least 2 projectiles very close?
        entity e, p;
@@ -290,7 +290,7 @@ float W_Crylink_Touch_WouldHitFriendly(entity projectile, float rad)
 }
 
 // NO bounce protection, as bounces are limited!
-void W_Crylink_Touch(void)
+void W_Crylink_Touch()
 {SELFPARAM();
        float finalhit;
        float f;
@@ -335,7 +335,7 @@ void W_Crylink_Touch(void)
        //      CSQCProjectile(proj, true, PROJECTILE_CRYLINK, true);
 }
 
-void W_Crylink_Fadethink(void)
+void W_Crylink_Fadethink()
 {SELFPARAM();
        W_Crylink_Dequeue(self);
        remove(self);
@@ -572,7 +572,7 @@ void W_Crylink_Attack2(Weapon thiswep)
                        else
                                self.BUTTON_ATCK2 = bot_aim(WEP_CVAR_SEC(crylink, speed), 0, WEP_CVAR_SEC(crylink, middle_lifetime), false);
                }
-               METHOD(Crylink, wr_think, void(entity thiswep, entity actor, int slot, int fire))
+               METHOD(Crylink, wr_think, void(entity thiswep, entity actor, .entity weaponentity, int fire))
                {
                        if(autocvar_g_balance_crylink_reload_ammo && actor.clip_load < min(WEP_CVAR_PRI(crylink, ammo), WEP_CVAR_SEC(crylink, ammo))) { // forced reload
                                Weapon w = get_weaponinfo(actor.weapon);
@@ -582,20 +582,20 @@ void W_Crylink_Attack2(Weapon thiswep)
                        if(fire & 1)
                        {
                                if(actor.crylink_waitrelease != 1)
-                               if(weapon_prepareattack(thiswep, actor, slot, false, WEP_CVAR_PRI(crylink, refire)))
+                               if(weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(crylink, refire)))
                                {
                                        W_Crylink_Attack(thiswep);
-                                       weapon_thinkf(actor, slot, WFRAME_FIRE1, WEP_CVAR_PRI(crylink, animtime), w_ready);
+                                       weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(crylink, animtime), w_ready);
                                }
                        }
 
                        if((fire & 2) && autocvar_g_balance_crylink_secondary)
                        {
                                if(actor.crylink_waitrelease != 2)
-                               if(weapon_prepareattack(thiswep, actor, slot, true, WEP_CVAR_SEC(crylink, refire)))
+                               if(weapon_prepareattack(thiswep, actor, weaponentity, true, WEP_CVAR_SEC(crylink, refire)))
                                {
                                        W_Crylink_Attack2(thiswep);
-                                       weapon_thinkf(actor, slot, WFRAME_FIRE2, WEP_CVAR_SEC(crylink, animtime), w_ready);
+                                       weapon_thinkf(actor, weaponentity, WFRAME_FIRE2, WEP_CVAR_SEC(crylink, animtime), w_ready);
                                }
                        }
 
@@ -680,13 +680,13 @@ void W_Crylink_Attack2(Weapon thiswep)
                        org2 = w_org + w_backoff * 2;
                        if(w_deathtype & HITTYPE_SECONDARY)
                        {
-                               pointparticles(particleeffectnum(EFFECT_CRYLINK_IMPACT2), org2, '0 0 0', 1);
+                               pointparticles(EFFECT_CRYLINK_IMPACT2, org2, '0 0 0', 1);
                                if(!w_issilent)
                                        sound(self, CH_SHOTS, SND_CRYLINK_IMPACT2, VOL_BASE, ATTN_NORM);
                        }
                        else
                        {
-                               pointparticles(particleeffectnum(EFFECT_CRYLINK_IMPACT), org2, '0 0 0', 1);
+                               pointparticles(EFFECT_CRYLINK_IMPACT, org2, '0 0 0', 1);
                                if(!w_issilent)
                                        sound(self, CH_SHOTS, SND_CRYLINK_IMPACT, VOL_BASE, ATTN_NORM);
                        }