arc_shotorigin[3] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), FALSE, FALSE, 4);
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_ARC).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_ARC,weapon,prop,name)
ARC_SETTINGS(arc)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
precache_sound ("weapons/crylink_fire2.wav");
precache_sound ("weapons/crylink_linkjoin.wav");
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_CRYLINK).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_CRYLINK,weapon,prop,name)
CRYLINK_SETTINGS(crylink)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
}
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_DEVASTATOR).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_DEVASTATOR,weapon,prop,name)
ARC_SETTINGS(devastator)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
precache_sound ("weapons/hagar_load.wav");
precache_sound ("weapons/hagar_beep.wav");
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_HAGAR).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_HAGAR,weapon,prop,name)
HAGAR_SETTINGS(hagar)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
precache_model ("models/weapons/h_uzi.iqm");
precache_sound ("weapons/uzi_fire.wav");
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_UZI).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_UZI,weapon,prop,name)
UZI_SETTINGS(uzi)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
precache_sound ("weapons/grenade_fire.wav");
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_GRENADE_LAUNCHER).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_GRENADE_LAUNCHER,weapon,prop,name)
MORTAR_SETTINGS(mortar)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
precache_sound ("weapons/nexwhoosh2.wav");
precache_sound ("weapons/nexwhoosh3.wav");
#define WEP_ADD_CVAR(weapon,mode,name) /*nothing*/
- #define WEP_ADD_PROP(weapon,prop,name) get_weaponinfo(WEP_NEX).##prop = autocvar_g_balance_##weapon##_##name;
+ #define WEP_ADD_PROP(weapon,prop,name) WEP_SET_PROP(WEP_NEX,weapon,prop,name)
NEX_SETTINGS(nex)
#undef WEP_ADD_CVAR
#undef WEP_ADD_PROP
.float ##prop; \
float autocvar_g_balance_##weapon##_##name;
+#define WEP_SET_PROP(wepid,weapon,prop,name) get_weaponinfo(##wepid).##prop = autocvar_g_balance_##weapon##_##name;
+
#include "all.qh"
#undef WEP_ADD_CVAR