Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
hlac.qh
Go to the documentation of this file.
1#pragma once
2
3#ifdef GAMEQC
4MODEL(HLAC_VIEW, W_Model("h_hlac.iqm"));
5MODEL(HLAC_WORLD, W_Model("v_hlac.md3"));
6MODEL(HLAC_ITEM, W_Model("g_hlac.md3"));
7
8SOUND(HLAC_FIRE, W_Sound("lasergun_fire"));
9#endif
10
12/* spawnfunc */ ATTRIB(HLAC, m_canonical_spawnfunc, string, "weapon_hlac");
13/* ammotype */ ATTRIB(HLAC, ammo_type, Resource, RES_CELLS);
14/* impulse */ ATTRIB(HLAC, impulse, int, 6);
16/* rating */ ATTRIB(HLAC, bot_pickupbasevalue, float, 4000);
17/* color */ ATTRIB(HLAC, m_color, vector, '0.506 0.945 0.239');
18/* modelname */ ATTRIB(HLAC, mdl, string, "hlac");
19#ifdef GAMEQC
20/* model */ ATTRIB(HLAC, m_model, Model, MDL_HLAC_ITEM);
21/* flash mdl */ ATTRIB(HLAC, m_muzzlemodel, Model, MDL_Null);
22/* flash eff */ ATTRIB(HLAC, m_muzzleeffect, entity,
23 (particleeffectnum(EFFECT_GREEN_HLAC_MUZZLEFLASH) < 0)
24 ? EFFECT_BLASTER_MUZZLEFLASH // compatible with Xonotic v0.8.6 or lower
25 : EFFECT_GREEN_HLAC_MUZZLEFLASH);
26#endif
27/* crosshair */ ATTRIB(HLAC, w_crosshair, string, "gfx/crosshairhlac");
28/* crosshair */ ATTRIB(HLAC, w_crosshair_size, float, 0.6);
29/* wepimg */ ATTRIB(HLAC, model2, string, "weaponhlac");
30/* refname */ ATTRIB(HLAC, netname, string, "hlac");
31/* wepname */ ATTRIB(HLAC, m_name, string, _("Heavy Laser Assault Cannon"));
32
33#define X(BEGIN, P, END, class, prefix) \
34 BEGIN(class) \
35 P(class, prefix, ammo, float, BOTH) \
36 P(class, prefix, animtime, float, BOTH) \
37 P(class, prefix, damage, float, BOTH) \
38 P(class, prefix, edgedamage, float, BOTH) \
39 P(class, prefix, force, float, BOTH) \
40 P(class, prefix, lifetime, float, BOTH) \
41 P(class, prefix, pickup_ammo, float, NONE) \
42 P(class, prefix, radius, float, BOTH) \
43 P(class, prefix, refire, float, BOTH) \
44 P(class, prefix, reload_ammo, float, NONE) \
45 P(class, prefix, reload_time, float, NONE) \
46 P(class, prefix, secondary, float, NONE) \
47 P(class, prefix, shots, float, SEC) \
48 P(class, prefix, speed, float, BOTH) \
49 P(class, prefix, spread, float, SEC) \
50 P(class, prefix, spread_add, float, PRI) \
51 P(class, prefix, spread_crouchmod, float, BOTH) \
52 P(class, prefix, spread_max, float, PRI) \
53 P(class, prefix, spread_min, float, PRI) \
54 P(class, prefix, switchdelay_drop, float, NONE) \
55 P(class, prefix, switchdelay_raise, float, NONE) \
56 P(class, prefix, weaponreplace, string,NONE) \
57 P(class, prefix, weaponstartoverride, float, NONE) \
58 P(class, prefix, weaponstart, float, NONE) \
59 P(class, prefix, weaponthrowable, float, NONE) \
60 END()
61 W_PROPS(X, HLAC, hlac)
62#undef X
63
66
67SPAWNFUNC_WEAPON(weapon_hlac, WEP_HLAC)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
Definition hlac.qh:11
Model m_muzzlemodel
Definition hlac.qh:21
int spawnflags
Definition hlac.qh:15
string model2
Definition hlac.qh:29
Model m_model
Definition hlac.qh:20
string mdl
Definition hlac.qh:18
int impulse
Definition hlac.qh:14
Resource ammo_type
Definition hlac.qh:13
string m_canonical_spawnfunc
Definition hlac.qh:12
string m_name
Definition hlac.qh:31
float bot_pickupbasevalue
Definition hlac.qh:16
float w_crosshair_size
Definition hlac.qh:28
string netname
Definition hlac.qh:30
entity m_muzzleeffect
Definition hlac.qh:25
vector m_color
Definition hlac.qh:17
string w_crosshair
Definition hlac.qh:27
Definition model.qh:3
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
Definition weapon.qh:44
ATTRIB(Weapon, m_canonical_spawnfunc, string)
the canonical spawnfunc name
#define particleeffectnum(e)
Definition effect.qh:3
#define X()
string W_Model(string w_mdl)
Definition all.qc:232
#define MODEL(name, path)
Definition all.qh:8
#define NEW(cname,...)
Definition oo.qh:117
#define CLASS(...)
Definition oo.qh:145
#define ENDCLASS(cname)
Definition oo.qh:281
#define ATTRIB(...)
Definition oo.qh:148
vector
Definition self.qh:92
string W_Sound(string w_snd)
Definition all.qc:225
#define SOUND(name, path)
Definition all.qh:30
#define W_PROPS(L, class, prefix)
Definition all.qh:179
#define REGISTER_WEAPON(id, inst)
Definition all.qh:136
const int WEP_FLAG_RELOADABLE
Definition weapon.qh:217
const int WEP_TYPE_SPLASH
Definition weapon.qh:212
const int WEP_FLAG_MUTATORBLOCKED
Definition weapon.qh:219
#define SPAWNFUNC_WEAPON(name, weapon)
Definition weapon.qh:150