X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fweapons%2Fweapon.qh;h=ec6e14eb668d8ef63e33cb6aaf2577fc464033cb;hb=ef1ca2543a39a330f6c619ee3e8707efd7252563;hp=83f3f4a0febd438e9f817f3ba9010bd747f78992;hpb=05878d3a4c3285af636dd5e9f9b3aa1f54e6b3fb;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/weapons/weapon.qh b/qcsrc/common/weapons/weapon.qh index 83f3f4a0fe..ec6e14eb66 100644 --- a/qcsrc/common/weapons/weapon.qh +++ b/qcsrc/common/weapons/weapon.qh @@ -1,7 +1,7 @@ #pragma once -#include #include +#include #include #ifdef SVQC @@ -45,7 +45,7 @@ CLASS(Weapon, Object) /** control what happens when this weapon is spawned */ METHOD(Weapon, m_spawnfunc_hookreplace, Weapon(Weapon this, entity e)) { return this; } /** M: ammotype : main ammo type */ - ATTRIB(Weapon, ammo_type, int, RES_NONE); + ATTRIB(Weapon, ammo_type, Resource, RES_NONE); /** M: impulse : weapon impulse */ ATTRIB(Weapon, impulse, int, -1); /** M: flags : WEPSPAWNFLAG_... combined */ @@ -223,15 +223,16 @@ string W_FixWeaponOrder_AllowIncomplete(entity this, string order); string W_FixWeaponOrder_ForceComplete(string order); WepSet W_RandomWeapons(entity e, WepSet remaining, int n); -string GetAmmoPicture(int ammotype); +string GetAmmoPicture(Resource ammotype); -string GetAmmoName(int ammotype); +string GetAmmoName(Resource ammotype); -entity GetAmmoItem(int ammotype); +entity GetAmmoItem(Resource ammotype); #ifdef CSQC -int GetAmmoTypeFromNum(int i); -int GetAmmoStat(int ammotype); +Resource GetAmmoTypeFromNum(int i); + +int GetAmmoStat(Resource ammotype); #endif string W_Sound(string w_snd);