]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add todo comment, move another throw weapon function
authorSamual Lenks <samual@xonotic.org>
Tue, 7 Jan 2014 02:50:10 +0000 (21:50 -0500)
committerSamual Lenks <samual@xonotic.org>
Tue, 7 Jan 2014 02:50:10 +0000 (21:50 -0500)
qcsrc/server/cl_client.qc
qcsrc/server/cl_player.qc
qcsrc/server/weapons/throwing.qc
qcsrc/server/weapons/throwing.qh

index 10b79a5176d6030876050069d718802d70e10aea..d91c6c75efe27e1b7c801eaf1066a1e9e649d036 100644 (file)
@@ -2429,6 +2429,7 @@ void PlayerPreThink (void)
                SpectatorThink();
        }
 
+       // WEAPONTODO: Add weapon request for this
        if(!zoomstate_set)
                SetZoomState(self.BUTTON_ZOOM || self.BUTTON_ZOOMSCRIPT || (self.BUTTON_ATCK2 && self.weapon == WEP_VORTEX) || (self.BUTTON_ATCK2 && self.weapon == WEP_RIFLE && WEP_CVAR(rifle, secondary) == 0)); // WEAPONTODO
 
index 6548912ab26d65920e4b58673d0333fdac5c0999..99a50c709a88ffa598b1dcbfa0ae07452ed1b40f 100644 (file)
@@ -138,13 +138,6 @@ void player_anim (void)
        }
 }
 
-void SpawnThrownWeapon (vector org, float w)
-{
-       if(self.weapons & WepSet_FromWeapon(self.weapon))
-               if(W_IsWeaponThrowable(self.weapon))
-                       W_ThrowNewWeapon(self, self.weapon, FALSE, org, randomvec() * 125 + '0 0 200');
-}
-
 void PlayerCorpseDamage (entity inflictor, entity attacker, float damage, float deathtype, vector hitloc, vector force)
 {
        float take, save;
index 36a7ae6793fe16f1dc6c8129bd8476cc6e5e834d..e5f36b941356f8f6c449da24d45a46aea2e4789b 100644 (file)
@@ -177,3 +177,10 @@ void W_ThrowWeapon(vector velo, vector delta, float doreduce)
        if(!a) return;
        Send_Notification(NOTIF_ONE, self, MSG_MULTI, ITEM_WEAPON_DROP, a, w);
 }
+
+void SpawnThrownWeapon(vector org, float w)
+{
+       if(self.weapons & WepSet_FromWeapon(self.weapon))
+               if(W_IsWeaponThrowable(self.weapon))
+                       W_ThrowNewWeapon(self, self.weapon, FALSE, org, randomvec() * 125 + '0 0 200');
+}
index 9dd70a67b0a000224c0a18f72cca03b8683a3730..c09a8f88296c4da90d6743e686d960513f5692be 100644 (file)
@@ -8,3 +8,5 @@ float W_IsWeaponThrowable(float w);
 
 // toss current weapon
 void W_ThrowWeapon(vector velo, vector delta, float doreduce);
+
+void SpawnThrownWeapon(vector org, float w);