]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/weapons/weapon/crylink.qc
Merge branch 'drjaska/wep-reload-fixes' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / weapons / weapon / crylink.qc
index 61820528fe1e14bcab89fd9a9f740f4b685c07bb..1e1b8f9913b92abf658d6331a6f757fc53710e3e 100644 (file)
@@ -341,11 +341,12 @@ void W_Crylink_Attack(Weapon thiswep, entity actor, .entity weaponentity)
 
                set_movetype(proj, MOVETYPE_BOUNCEMISSILE);
                PROJECTILE_MAKETRIGGER(proj);
+               proj.clipgroup = CLIPGROUP_UNHITTABLEPROJ;
                proj.projectiledeathtype = thiswep.m_id;
                //proj.gravity = 0.001;
 
                setorigin(proj, w_shotorg);
-               setsize(proj, '0 0 0', '0 0 0');
+               setsize(proj, UNHITTABLEPROJ_MINS, UNHITTABLEPROJ_MAXS);
 
 
                s = '0 0 0';
@@ -391,7 +392,7 @@ void W_Crylink_Attack(Weapon thiswep, entity actor, .entity weaponentity)
 
                MUTATOR_CALLHOOK(EditProjectile, actor, proj);
        }
-       if(WEP_CVAR_PRI(crylink, joinspread) != 0)
+       if(WEP_CVAR_PRI(crylink, joinspread) != 0 && WEP_CVAR_PRI(crylink, shots) > 1)
        {
                actor.(weaponentity).crylink_lastgroup = proj;
                W_Crylink_CheckLinks(proj);
@@ -454,11 +455,12 @@ void W_Crylink_Attack2(Weapon thiswep, entity actor, .entity weaponentity)
 
                set_movetype(proj, MOVETYPE_BOUNCEMISSILE);
                PROJECTILE_MAKETRIGGER(proj);
+               proj.clipgroup = CLIPGROUP_UNHITTABLEPROJ;
                proj.projectiledeathtype = thiswep.m_id | HITTYPE_SECONDARY;
                //proj.gravity = 0.001;
 
                setorigin(proj, w_shotorg);
-               setsize(proj, '0 0 0', '0 0 0');
+               setsize(proj, UNHITTABLEPROJ_MINS, UNHITTABLEPROJ_MAXS);
 
                if(WEP_CVAR_SEC(crylink, spreadtype) == 1)
                {
@@ -511,7 +513,7 @@ void W_Crylink_Attack2(Weapon thiswep, entity actor, .entity weaponentity)
 
                MUTATOR_CALLHOOK(EditProjectile, actor, proj);
        }
-       if(WEP_CVAR_SEC(crylink, joinspread) != 0)
+       if(WEP_CVAR_SEC(crylink, joinspread) != 0 && WEP_CVAR_SEC(crylink, shots) > 1)
        {
                actor.(weaponentity).crylink_lastgroup = proj;
                W_Crylink_CheckLinks(proj);