#ifdef REGISTER_WEAPON
REGISTER_WEAPON(
-/* WEP_##id */ ARC,
-/* function */ w_arc,
-/* ammotype */ IT_CELLS,
-/* impulse */ 5,
-/* flags */ WEP_FLAG_NORMAL,
-/* rating */ BOT_PICKUP_RATING_HIGH,
-/* model */ "arc",
-/* shortname */ "arc",
-/* fullname */ _("Arc")
+/* WEP_##id */ ARC,
+/* function */ w_arc,
+/* ammotype */ IT_CELLS,
+/* impulse */ 5,
+/* flags */ WEP_FLAG_NORMAL,
+/* rating */ BOT_PICKUP_RATING_HIGH,
+/* model */ "arc",
+/* netname */ "arc",
+/* fullname */ _("Arc")
);
#define ARC_SETTINGS(weapon) \
#endif
#else
#ifdef SVQC
+void spawnfunc_weapon_arc() { weapon_defaultspawnfunc(WEP_ARC); }
float W_Arc_Beam_Send(entity to, float sf)
{
return TRUE;
}
- case WR_PRECACHE:
+ case WR_INIT:
{
precache_model ("models/weapons/g_arc.md3");
precache_model ("models/weapons/v_arc.md3");
{
return self.ammo_cells >= WEP_CVAR_SEC(arc, ammo);
}
+ case WR_CONFIG:
+ {
+ WEP_CONFIG_SETTINGS(ARC_SETTINGS(arc))
+ return TRUE;
+ }
case WR_KILLMESSAGE:
{
if(w_deathtype & HITTYPE_SECONDARY)
void ArcInit()
{
- weapon_action(WEP_ARC, WR_PRECACHE);
+ WEP_ACTION(WEP_ARC, WR_INIT);
arc_shotorigin[0] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), FALSE, FALSE, 1);
arc_shotorigin[1] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), FALSE, FALSE, 2);
arc_shotorigin[2] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), FALSE, FALSE, 3);
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
}
-
-void spawnfunc_weapon_arc (void) // should this really be here?
-{
- weapon_defaultspawnfunc(WEP_ARC);
-}
#endif
#ifdef CSQC
float w_arc(float req)
return TRUE;
}
- case WR_PRECACHE:
+ case WR_INIT:
{
precache_sound("weapons/arc_impact.wav");
precache_sound("weapons/arc_impact_combo.wav");