Xonotic
electro.qh
Go to the documentation of this file.
1 #pragma once
2 
4 /* spawnfunc */ ATTRIB(Electro, m_canonical_spawnfunc, string, "weapon_electro");
5 /* ammotype */ ATTRIB(Electro, ammo_type, Resource, RES_CELLS);
6 /* impulse */ ATTRIB(Electro, impulse, int, 5);
8 /* rating */ ATTRIB(Electro, bot_pickupbasevalue, float, 5000);
9 /* color */ ATTRIB(Electro, wpcolor, vector, '0 0.5 1');
10 /* modelname */ ATTRIB(Electro, mdl, string, "electro");
11 #ifdef GAMEQC
12 /* model */ ATTRIB(Electro, m_model, Model, MDL_ELECTRO_ITEM);
13 /* flash mdl */ ATTRIB(Electro, m_muzzlemodel, Model, MDL_Null);
14 /* flash eff */ ATTRIB(Electro, m_muzzleeffect, entity, EFFECT_ELECTRO_MUZZLEFLASH);
15 #endif
16 /* crosshair */ ATTRIB(Electro, w_crosshair, string, "gfx/crosshairelectro");
17 /* crosshair */ ATTRIB(Electro, w_crosshair_size, float, 0.6);
18 /* wepimg */ ATTRIB(Electro, model2, string, "weaponelectro");
19 /* refname */ ATTRIB(Electro, netname, string, "electro");
20 /* wepname */ ATTRIB(Electro, m_name, string, _("Electro"));
21 
22 #define X(BEGIN, P, END, class, prefix) \
23  BEGIN(class) \
24  P(class, prefix, ammo, float, BOTH) \
25  P(class, prefix, animtime, float, BOTH) \
26  P(class, prefix, bouncefactor, float, SEC) \
27  P(class, prefix, bouncestop, float, SEC) \
28  P(class, prefix, comboradius, float, PRI) \
29  P(class, prefix, combo_comboradius, float, NONE) \
30  P(class, prefix, combo_comboradius_thruwall, float, NONE) \
31  P(class, prefix, combo_damage, float, NONE) \
32  P(class, prefix, combo_edgedamage, float, NONE) \
33  P(class, prefix, combo_force, float, NONE) \
34  P(class, prefix, combo_radius, float, NONE) \
35  P(class, prefix, combo_safeammocheck, float, NONE) \
36  P(class, prefix, combo_speed, float, NONE) \
37  P(class, prefix, count, float, SEC) \
38  P(class, prefix, damagedbycontents, float, SEC) \
39  P(class, prefix, damageforcescale, float, SEC) \
40  P(class, prefix, damage, float, BOTH) \
41  P(class, prefix, edgedamage, float, BOTH) \
42  P(class, prefix, force, float, BOTH) \
43  P(class, prefix, health, float, SEC) \
44  P(class, prefix, lifetime, float, BOTH) \
45  P(class, prefix, limit, float, SEC) \
46  P(class, prefix, midaircombo_enemy, bool, PRI) \
47  P(class, prefix, midaircombo_explode, float, PRI) \
48  P(class, prefix, midaircombo_interval, float, PRI) \
49  P(class, prefix, midaircombo_own, bool, PRI) \
50  P(class, prefix, midaircombo_radius, float, PRI) \
51  P(class, prefix, midaircombo_speed, float, PRI) \
52  P(class, prefix, midaircombo_teammate, float, PRI) \
53  P(class, prefix, radius, float, BOTH) \
54  P(class, prefix, refire2, float, SEC) \
55  P(class, prefix, refire, float, BOTH) \
56  P(class, prefix, reload_ammo, float, NONE) \
57  P(class, prefix, reload_time, float, NONE) \
58  P(class, prefix, speed, float, BOTH) \
59  P(class, prefix, speed_up, float, SEC) \
60  P(class, prefix, speed_z, float, SEC) \
61  P(class, prefix, spread, float, BOTH) \
62  P(class, prefix, stick, float, SEC) \
63  P(class, prefix, stick_lifetime, float, SEC) \
64  P(class, prefix, switchdelay_drop, float, NONE) \
65  P(class, prefix, switchdelay_raise, float, NONE) \
66  P(class, prefix, touchexplode, float, SEC) \
67  P(class, prefix, weaponreplace, string,NONE) \
68  P(class, prefix, weaponstartoverride, float, NONE) \
69  P(class, prefix, weaponstart, float, NONE) \
70  P(class, prefix, weaponthrowable, float, NONE) \
71  END()
72  W_PROPS(X, Electro, electro)
73 #undef X
74 
75 ENDCLASS(Electro)
76 REGISTER_WEAPON(ELECTRO, electro, NEW(Electro));
77 
78 SPAWNFUNC_WEAPON(weapon_electro, WEP_ELECTRO)
79 
80 #ifdef SVQC
81 IntrusiveList LimitedElectroBallRubbleList;
82 .float electro_count;
83 .float electro_secondarytime;
84 void W_Electro_ExplodeCombo(entity this);
85 #endif
const int WEP_FLAG_RELOADABLE
Definition: weapon.qh:201
#define NEW(cname,...)
Definition: oo.qh:105
CLASS(Object) Object
Definition: oo.qh:318
#define X(BEGIN, P, END, class, prefix)
Definition: electro.qh:22
entity() spawn
string netname
Definition: powerups.qc:20
float bot_pickupbasevalue
Definition: bot.qh:66
limitations: NULL cannot be present elements can only be present once a maximum of IL_MAX lists can e...
const int WEP_TYPE_SPLASH
Definition: weapon.qh:196
float impulse
Definition: progsdefs.qc:158
float spawnflags
Definition: progsdefs.qc:191
#define ATTRIB(...)
Definition: oo.qh:136
Definition: model.qh:3
vector(float skel, float bonenum) _skel_get_boneabs_hidden
const int WEP_FLAG_CANCLIMB
Definition: weapon.qh:198
#define SPAWNFUNC_WEAPON(name, weapon)
Definition: weapon.qh:143
#define ENDCLASS(cname)
Definition: oo.qh:269
const int WEP_FLAG_NORMAL
Definition: weapon.qh:199
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
Definition: weapon.qh:41
#define W_PROPS(L, class, prefix)
Definition: all.qh:163
string m_name
Definition: scores.qh:135
REGISTER_WEAPON(ELECTRO, electro, NEW(Electro))