]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/common/weapons/weapon/crylink.qh
Attach muzzle effects to weapon data instead of trying to send it for each muzzle...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / weapons / weapon / crylink.qh
1 #pragma once
2
3 CLASS(Crylink, Weapon)
4 /* spawnfunc */ ATTRIB(Crylink, m_canonical_spawnfunc, string, "weapon_crylink");
5 /* ammotype  */ ATTRIB(Crylink, ammo_type, int, RES_CELLS);
6 /* impulse   */ ATTRIB(Crylink, impulse, int, 6);
7 /* flags     */ ATTRIB(Crylink, spawnflags, int, WEP_FLAG_NORMAL | WEP_FLAG_RELOADABLE | WEP_TYPE_SPLASH | WEP_FLAG_CANCLIMB);
8 /* rating    */ ATTRIB(Crylink, bot_pickupbasevalue, float, 6000);
9 /* color     */ ATTRIB(Crylink, wpcolor, vector, '1 0.5 1');
10 /* modelname */ ATTRIB(Crylink, mdl, string, "crylink");
11 #ifdef GAMEQC
12 /* model     */ ATTRIB(Crylink, m_model, Model, MDL_CRYLINK_ITEM);
13 /* flash mdl */ ATTRIB(Crylink, m_muzzlemodel, Model, MDL_Null);
14 /* flash eff */ ATTRIB(Crylink, m_muzzleeffect, entity, EFFECT_CRYLINK_MUZZLEFLASH);
15 #endif
16 /* crosshair */ ATTRIB(Crylink, w_crosshair, string, "gfx/crosshaircrylink");
17 /* crosshair */ ATTRIB(Crylink, w_crosshair_size, float, 0.5);
18 /* wepimg    */ ATTRIB(Crylink, model2, string, "weaponcrylink");
19 /* refname   */ ATTRIB(Crylink, netname, string, "crylink");
20 /* wepname   */ ATTRIB(Crylink, m_name, string, _("Crylink"));
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, bouncedamagefactor, float, BOTH) \
27         P(class, prefix, bounces, float, BOTH) \
28         P(class, prefix, damage, float, BOTH) \
29         P(class, prefix, edgedamage, float, BOTH) \
30         P(class, prefix, force, float, BOTH) \
31         P(class, prefix, joindelay, float, BOTH) \
32         P(class, prefix, joinexplode, float, BOTH) \
33         P(class, prefix, joinexplode_damage, float, BOTH) \
34         P(class, prefix, joinexplode_edgedamage, float, BOTH) \
35         P(class, prefix, joinexplode_force, float, BOTH) \
36         P(class, prefix, joinexplode_radius, float, BOTH) \
37         P(class, prefix, joinspread, float, BOTH) \
38         P(class, prefix, linkexplode, float, BOTH) \
39         P(class, prefix, middle_fadetime, float, BOTH) \
40         P(class, prefix, middle_lifetime, float, BOTH) \
41         P(class, prefix, other_fadetime, float, BOTH) \
42         P(class, prefix, other_lifetime, float, BOTH) \
43         P(class, prefix, radius, float, BOTH) \
44         P(class, prefix, refire, float, BOTH) \
45         P(class, prefix, reload_ammo, float, NONE) \
46         P(class, prefix, reload_time, float, NONE) \
47         P(class, prefix, secondary, float, NONE) \
48         P(class, prefix, shots, float, BOTH) \
49         P(class, prefix, speed, float, BOTH) \
50         P(class, prefix, spreadtype, float, SEC) \
51         P(class, prefix, spread, float, BOTH) \
52         P(class, prefix, switchdelay_drop, float, NONE) \
53         P(class, prefix, switchdelay_raise, float, NONE) \
54         P(class, prefix, weaponreplace, string, NONE) \
55         P(class, prefix, weaponstartoverride, float, NONE) \
56         P(class, prefix, weaponstart, float, NONE) \
57         P(class, prefix, weaponthrowable, float, NONE) \
58         END()
59         W_PROPS(X, Crylink, crylink)
60 #undef X
61
62 ENDCLASS(Crylink)
63 REGISTER_WEAPON(CRYLINK, crylink, NEW(Crylink));
64
65 SPAWNFUNC_WEAPON(weapon_crylink, WEP_CRYLINK)
66
67 #ifdef SVQC
68 .float gravity;
69 .float crylink_waitrelease;
70 .entity crylink_lastgroup;
71
72 .entity crylink_owner; // we can't use realowner, as that's subject to change
73
74 .entity queuenext;
75 .entity queueprev;
76
77 void W_Crylink_Dequeue(entity e);
78 #endif