]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix a few more floats
authorMario <zacjardine@y7mail.com>
Sat, 25 Apr 2015 04:23:53 +0000 (14:23 +1000)
committerMario <zacjardine@y7mail.com>
Sat, 25 Apr 2015 04:23:53 +0000 (14:23 +1000)
qcsrc/common/weapons/weapons.qc

index 58a164f75b5b77e5874246376405afb51a2be1ee..3ab584fc1e7fb63d8be9dd8ec2b73c88d0996819 100644 (file)
@@ -130,10 +130,10 @@ WepSet ReadWepSet()
 void register_weapon(
        int id,
        WepSet bit,
-       float(float) func,
-       .float ammotype,
-       float i,
-       float weapontype,
+       bool(int) func,
+       .int ammotype,
+       int i,
+       int weapontype,
        float pickupbasevalue,
        vector clr,
        string modelname,
@@ -169,7 +169,7 @@ void register_weapon(
        func(WR_INIT);
        #endif
 }
-float w_null(float dummy)
+bool w_null(int dummy)
 {
        return 0;
 }
@@ -246,7 +246,7 @@ string W_NameWeaponOrder(string order)
 }
 string W_NumberWeaponOrder_MapFunc(string s)
 {
-       float i;
+       int i;
        if(s == "0" || stof(s))
                return s;
        s = W_UndeprecateName(s);
@@ -312,7 +312,7 @@ string W_FixWeaponOrder_ForceComplete(string order)
 
 void W_RandomWeapons(entity e, float n)
 {
-       float i, j;
+       int i, j;
        WepSet remaining;
        WepSet result;
        remaining = e.weapons;
@@ -329,7 +329,7 @@ void W_RandomWeapons(entity e, float n)
        e.weapons = result;
 }
 
-string GetAmmoPicture(.float ammotype)
+string GetAmmoPicture(.int ammotype)
 {
        switch(ammotype)
        {
@@ -344,7 +344,7 @@ string GetAmmoPicture(.float ammotype)
 }
 
 #ifdef CSQC
-.float GetAmmoFieldFromNum(int i)
+.int GetAmmoFieldFromNum(int i)
 {
        switch(i)
        {
@@ -358,7 +358,7 @@ string GetAmmoPicture(.float ammotype)
        }
 }
 
-int GetAmmoStat(.float ammotype)
+int GetAmmoStat(.int ammotype)
 {
        switch(ammotype)
        {