X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fweapons%2Fall.qc;h=f118a04667f39c181eb0dee13eede8cc59d42973;hb=c66a78d068945e0dce54d7eb640395c782207fb0;hp=dca20d0cdbf1b627bf920ddee47aeb93c60ce58d;hpb=f242b05ab828abab5e2bd9f8497b84cdadc86d13;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/weapons/all.qc b/qcsrc/common/weapons/all.qc index dca20d0cd..f118a0466 100644 --- a/qcsrc/common/weapons/all.qc +++ b/qcsrc/common/weapons/all.qc @@ -123,6 +123,8 @@ string W_UndeprecateName(string s) case "minstanex": return "vaporizer"; case "grenadelauncher": return "mortar"; case "uzi": return "machinegun"; + case "hmg": return "okhmg"; + case "rpc": return "okrpc"; default: return s; } } @@ -192,9 +194,8 @@ string W_FixWeaponOrder_ForceComplete(string order) return W_FixWeaponOrder(order, 1); } -void W_RandomWeapons(entity e, int n) +WepSet W_RandomWeapons(entity e, WepSet remaining, int n) { - WepSet remaining = e.weapons; WepSet result = '0 0 0'; for (int j = 0; j < n; ++j) { @@ -207,7 +208,7 @@ void W_RandomWeapons(entity e, int n) result |= WepSet_FromWeapon(w); remaining &= ~WepSet_FromWeapon(w); } - e.weapons = result; + return result; } string GetAmmoPicture(int ammotype)