X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fcommon%2Fweapons%2Fweapon%2Fshotgun.qh;h=5a47a18890cda1246024982d4f9a1ec90bce7dc0;hp=6f70f09beec2219624baeca92e2cd7deaa104fb4;hb=f785b8a76c2336cb00e78fe9e738d55512a086f5;hpb=c039d054a46888048d214000273ccfc63e4611b6 diff --git a/qcsrc/common/weapons/weapon/shotgun.qh b/qcsrc/common/weapons/weapon/shotgun.qh index 6f70f09be..5a47a1889 100644 --- a/qcsrc/common/weapons/weapon/shotgun.qh +++ b/qcsrc/common/weapons/weapon/shotgun.qh @@ -1 +1,57 @@ #pragma once + +CLASS(Shotgun, Weapon) +/* spawnfunc */ ATTRIB(Shotgun, m_canonical_spawnfunc, string, "weapon_shotgun"); +/* ammotype */ ATTRIB(Shotgun, ammo_type, int, RES_SHELLS); +/* impulse */ ATTRIB(Shotgun, impulse, int, 2); +/* flags */ ATTRIB(Shotgun, spawnflags, int, WEP_FLAG_NORMAL | WEP_FLAG_RELOADABLE | WEP_TYPE_HITSCAN | WEP_TYPE_MELEE_SEC); +/* rating */ ATTRIB(Shotgun, bot_pickupbasevalue, float, 6000); +/* color */ ATTRIB(Shotgun, wpcolor, vector, '0.5 0.25 0'); +/* modelname */ ATTRIB(Shotgun, mdl, string, "shotgun"); +#ifdef GAMEQC +/* model */ ATTRIB(Shotgun, m_model, Model, MDL_SHOTGUN_ITEM); +#endif +/* crosshair */ ATTRIB(Shotgun, w_crosshair, string, "gfx/crosshairshotgun"); +/* crosshair */ ATTRIB(Shotgun, w_crosshair_size, float, 0.65); +/* wepimg */ ATTRIB(Shotgun, model2, string, "weaponshotgun"); +/* refname */ ATTRIB(Shotgun, netname, string, "shotgun"); +/* wepname */ ATTRIB(Shotgun, m_name, string, _("Shotgun")); + +#define X(BEGIN, P, END, class, prefix) \ + BEGIN(class) \ + P(class, prefix, alt_animtime, float, SEC) \ + P(class, prefix, alt_refire, float, SEC) \ + P(class, prefix, ammo, float, PRI) \ + P(class, prefix, animtime, float, BOTH) \ + P(class, prefix, bullets, float, PRI) \ + P(class, prefix, damage, float, BOTH) \ + P(class, prefix, force, float, BOTH) \ + P(class, prefix, melee_delay, float, SEC) \ + P(class, prefix, melee_multihit, float, SEC) \ + P(class, prefix, melee_nonplayerdamage, float, SEC) \ + P(class, prefix, melee_no_doubleslap, float, SEC) \ + P(class, prefix, melee_range, float, SEC) \ + P(class, prefix, melee_swing_side, float, SEC) \ + P(class, prefix, melee_swing_up, float, SEC) \ + P(class, prefix, melee_time, float, SEC) \ + P(class, prefix, melee_traces, float, SEC) \ + P(class, prefix, refire, float, BOTH) \ + P(class, prefix, reload_ammo, float, NONE) \ + P(class, prefix, reload_time, float, NONE) \ + P(class, prefix, secondary, float, NONE) \ + P(class, prefix, solidpenetration, float, PRI) \ + P(class, prefix, spread, float, PRI) \ + P(class, prefix, switchdelay_drop, float, NONE) \ + P(class, prefix, switchdelay_raise, float, NONE) \ + P(class, prefix, weaponreplace, string,NONE) \ + P(class, prefix, weaponstartoverride, float, NONE) \ + P(class, prefix, weaponstart, float, NONE) \ + P(class, prefix, weaponthrowable, float, NONE) \ + END() + W_PROPS(X, Shotgun, shotgun) +#undef X + +ENDCLASS(Shotgun) +REGISTER_WEAPON(SHOTGUN, shotgun, NEW(Shotgun)); + +SPAWNFUNC_WEAPON(weapon_shotgun, WEP_SHOTGUN)