Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
vaporizer.qc
Go to the documentation of this file.
1#include "vaporizer.qh"
2
3#ifdef GAMEQC
4REGISTER_NET_TEMP(TE_CSQC_VAPORBEAMPARTICLE)
5#endif
6
7#if defined(SVQC)
8void SendCSQCVaporizerBeamParticle(entity player, int hit) {
9 vector v;
11 WriteHeader(MSG_BROADCAST, TE_CSQC_VAPORBEAMPARTICLE);
12 WriteVector(MSG_BROADCAST, w_shotorg);
13 WriteVector(MSG_BROADCAST, v);
16}
17#elif defined(CSQC)
18bool autocvar_cl_vaporizerbeam_teamcolor = true;
19bool autocvar_cl_vaporizerbeam_particle = false;
20float autocvar_cl_vaporizerbeam_lifetime = 0.8;
21float autocvar_cl_vaporizerbeam_colorboost = 0.7;
22
23string Draw_VaporizerBeam_trace_callback_tex;
24float Draw_VaporizerBeam_trace_callback_rnd;
25vector Draw_VaporizerBeam_trace_callback_rgb;
26float Draw_VaporizerBeam_trace_callback_a;
27
28void Draw_VaporizerBeam_trace_callback(vector start, vector hit, vector end)
29{
30 float i;
31 vector vorg;
33 for(i = 0; i < Draw_VaporizerBeam_trace_callback_a; ++i)
34 Draw_CylindricLine(hit, start, 8, Draw_VaporizerBeam_trace_callback_tex, 0.25, Draw_VaporizerBeam_trace_callback_rnd, Draw_VaporizerBeam_trace_callback_rgb, min(1, Draw_VaporizerBeam_trace_callback_a - i), DRAWFLAG_NORMAL, vorg);
35 Draw_VaporizerBeam_trace_callback_rnd += 0.25 * vlen(hit - start) / 8;
36}
37
38.vector vorg1, vorg2;
39void VaporizerBeam_Draw(entity this)
40{
41 //draw either the old v2.3 beam or the new beam
43
44 string tex = "particles/lgbeam";
45 if(this.cnt)
46 tex = "particles/gauntletbeam";
47 vector rgb = WEP_VAPORIZER.m_color;
48 if(autocvar_cl_vaporizerbeam_teamcolor)
49 rgb = colormapPaletteColor(entcs_GetClientColors(this.sv_entnum - 1) & 0x0F, true);
50
51 rgb *= (1 + autocvar_cl_vaporizerbeam_colorboost);
52
53 float fail = (this.nextthink - time);
54
55 Draw_VaporizerBeam_trace_callback_tex = tex;
56 Draw_VaporizerBeam_trace_callback_rnd = 0;
57 Draw_VaporizerBeam_trace_callback_rgb = rgb;
58 Draw_VaporizerBeam_trace_callback_a = bound(0, fail, 1);
59 WarpZone_TraceBox_ThroughZone(this.vorg1, '0 0 0', '0 0 0', this.vorg2, MOVE_NOTHING, NULL, NULL, Draw_VaporizerBeam_trace_callback);
60 Draw_VaporizerBeam_trace_callback_tex = string_null;
61
62 /*if(!MUTATOR_CALLHOOK(Particles_VaporizerBeam, this.vorg1, this.vorg2))
63 if(autocvar_cl_particles_oldvortexbeam)
64 WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM_OLD), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);
65 else
66 WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);*/
67}
68
69NET_HANDLE(TE_CSQC_VAPORBEAMPARTICLE, bool isNew)
70{
71 Net_Accept(vortex_beam);
72 setthink(this, SUB_Remove);
73 this.nextthink = time + bound(0, autocvar_cl_vaporizerbeam_lifetime, 10);
74 this.draw = VaporizerBeam_Draw;
75 if (isNew) IL_PUSH(g_drawables, this);
76 this.drawmask = MASK_NORMAL;
77
78 this.vorg1 = ReadVector();
79 this.vorg2 = ReadVector();
80 this.cnt = ReadByte();
81 int myowner = ReadByte();
82 this.owner = playerslots[myowner - 1];
83 this.sv_entnum = myowner;
84
85 //pointparticles(EFFECT_VORTEX_MUZZLEFLASH, this.vorg1, normalize(this.vorg2 - this.vorg1) * 1000, 1);
86
87 if(autocvar_cl_vaporizerbeam_particle)
88 {
89 vector rgb = WEP_VAPORIZER.m_color;
90 if(autocvar_cl_vaporizerbeam_teamcolor)
91 rgb = colormapPaletteColor(entcs_GetClientColors(this.sv_entnum - 1) & 0x0F, true);
92
94 WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(((this.cnt) ? EFFECT_VAPORIZER_BEAM_HIT : EFFECT_VAPORIZER_BEAM)), this.vorg1, this.vorg2, 1, PARTICLES_USECOLOR);
95 this.draw = func_null;
96 this.drawmask = MASK_NORMAL;
97 delete(this);
98 }
99
100 return true;
101}
102#endif
103
104#ifdef SVQC
105
106void W_RocketMinsta_Explosion(entity actor, .entity weaponentity, vector loc)
107{
108 if(accuracy_canbegooddamage(actor))
109 accuracy_add(actor, WEP_DEVASTATOR, autocvar_g_rm_damage, 0, 0); // add to fired
110 entity dmgent = spawn();
111 dmgent.owner = dmgent.realowner = actor;
112 setorigin(dmgent, loc);
114 delete(dmgent);
115}
116
117void W_Vaporizer_Attack(Weapon thiswep, entity actor, .entity weaponentity)
118{
119 bool flying = IsFlying(actor); // do this BEFORE to make the trace values from FireRailgunBullet last
120 float vaporizer_damage = ((WEP_CVAR_PRI(WEP_VAPORIZER, damage) > 0) ? WEP_CVAR_PRI(WEP_VAPORIZER, damage) : 10000);
121
122 W_SetupShot(actor, weaponentity, true, 0, SND_Null, CH_WEAPON_A, vaporizer_damage, thiswep.m_id);
123 // handle sound separately so we can change the volume
124 // added bonus: no longer plays the strength sound (strength gives no bonus to instakill anyway)
125 sound (actor, CH_WEAPON_A, SND_VAPORIZER_FIRE, VOL_BASE * 0.8, ATTEN_NORM);
126
127 yoda = 0;
128 impressive_hits = 0;
129 FireRailgunBullet(actor, weaponentity, w_shotorg, w_shotorg + w_shotdir * max_shot_distance, vaporizer_damage, true, WEP_CVAR_PRI(WEP_VAPORIZER, force), WEP_CVAR_PRI(WEP_VAPORIZER, damagefalloff_mindist), WEP_CVAR_PRI(WEP_VAPORIZER, damagefalloff_maxdist), WEP_CVAR_PRI(WEP_VAPORIZER, damagefalloff_halflife), WEP_CVAR_PRI(WEP_VAPORIZER, damagefalloff_forcehalflife), thiswep.m_id);
130
131 // do this now, as goodhits is disabled below
133 W_MuzzleFlash(thiswep, actor, weaponentity, w_shotorg, normalize(v - w_shotorg));
135
136 if(yoda && flying)
137 Send_Notification(NOTIF_ONE, actor, MSG_ANNCE, ANNCE_ACHIEVEMENT_YODA);
138 if(impressive_hits && actor.vaporizer_lasthit)
139 {
140 Send_Notification(NOTIF_ONE, actor, MSG_ANNCE, ANNCE_ACHIEVEMENT_IMPRESSIVE);
141 impressive_hits = 0; // only every second time
142 }
143
144 actor.vaporizer_lasthit = impressive_hits;
145
146 if(autocvar_g_rm)
148 W_RocketMinsta_Explosion(actor, weaponentity, trace_endpos);
149
150 W_DecreaseAmmo(thiswep, actor, ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(WEP_VAPORIZER, ammo)), weaponentity);
151}
152
153void W_RocketMinsta_Laser_Damage(entity this, entity directhitentity)
154{
155 int laser_count = max(1, this.rm_laser_count);
156 float laser_force = autocvar_g_rm_laser_force / laser_count;
157 float laser_damage = autocvar_g_rm_laser_damage / laser_count;
158 RadiusDamage(this, this.realowner, laser_damage, laser_damage, autocvar_g_rm_laser_radius, NULL, NULL, laser_force, this.projectiledeathtype, this.weaponentity_fld, directhitentity);
159}
160
161void W_RocketMinsta_Laser_Explode(entity this, entity directhitentity)
162{
163 if(directhitentity.takedamage == DAMAGE_AIM)
164 if(IS_PLAYER(directhitentity))
165 if(DIFF_TEAM(this.realowner, directhitentity))
166 if(!IS_DEAD(directhitentity))
167 if(IsFlying(directhitentity))
168 Send_Notification(NOTIF_ONE, this.realowner, MSG_ANNCE, ANNCE_ACHIEVEMENT_ELECTROBITCH);
169
170 this.event_damage = func_null;
171 this.takedamage = DAMAGE_NO;
172 W_RocketMinsta_Laser_Damage(this, directhitentity);
173 delete(this);
174}
175
177{
178 W_RocketMinsta_Laser_Explode(this, trigger); // we probably don't want trigger used here, but this matches closest to old behaviour
179}
180
182{
184 //W_RocketMinsta_Laser_Explode ();
186 delete(this);
187}
188
189// mode 0 fires many projectiles
190// mode 1 fires 1 projectile
191void W_RocketMinsta_Attack(entity actor, .entity weaponentity, int mode)
192{
193 makevectors(actor.v_angle);
194
195 entity proj;
196 int laser_count = max(1, autocvar_g_rm_laser_count);
197 int total = (mode == 0) ? laser_count : 1;
198 Sound snd = (mode == 0) ? SND_CRYLINK_FIRE : SND_ELECTRO_FIRE2; // WEAPONTODO multiple references to other weapons here!
199 W_SetupShot_ProjectileSize(actor, weaponentity, '0 0 -3', '0 0 -3', false, 2, snd, CH_WEAPON_A, autocvar_g_rm_laser_damage, WEP_ELECTRO.m_id);
200
201 // uses electro effects
202 W_MuzzleFlash(WEP_ELECTRO, actor, weaponentity, w_shotorg, w_shotdir);
203
204 for (int counter = 0; counter < total; ++counter)
205 {
206 proj = new(plasma_prim);
207 proj.owner = proj.realowner = actor;
208 proj.bot_dodge = true;
209 proj.bot_dodgerating = autocvar_g_rm_laser_damage;
212 proj.nextthink = time + autocvar_g_rm_laser_lifetime;
214 proj.projectiledeathtype = WEP_ELECTRO.m_id;
215 proj.weaponentity_fld = weaponentity;
216 setorigin(proj, w_shotorg);
217
218 proj.rm_laser_count = total;
219
220 //W_SetupProjectileVelocity(proj, autocvar_g_rm_laser_speed, spread * (rndspread ? random() : 1) * autocvar_g_rm_laser_speed);
221
223 if (mode == 0)
224 {
226 //W_SETUPPROJECTILEVELOCITY(proj, g_balance_minstanex_laser);
227 proj.velocity = (w_shotdir + (((counter + 0.5) / total) * 2 - 1) * v_right * spread) * cvar("g_rm_laser_speed");
228 proj.velocity.z += cvar("g_rm_laser_zspread") * (random() - 0.5);
229 }
230 else
231 proj.velocity = w_shotdir * autocvar_g_rm_laser_speed;
232 proj.velocity = W_CalculateProjectileVelocity(actor, actor.velocity, proj.velocity, true);
233 proj.angles = vectoangles(proj.velocity);
235 setsize(proj, '0 0 -3', '0 0 -3');
236 proj.flags = FL_PROJECTILE;
237 IL_PUSH(g_projectiles, proj);
238 IL_PUSH(g_bot_dodge, proj);
239 proj.missile_flags = MIF_SPLASH;
240
242
243 MUTATOR_CALLHOOK(EditProjectile, actor, proj);
244 }
245}
246
247METHOD(Vaporizer, wr_aim, void(entity thiswep, entity actor, .entity weaponentity))
248{
249 if((actor.items & IT_UNLIMITED_AMMO) || GetResource(actor, thiswep.ammo_type) > 0)
250 PHYS_INPUT_BUTTON_ATCK(actor) = bot_aim(actor, weaponentity, 1000000, 0, 1, false, true);
251 else
252 PHYS_INPUT_BUTTON_ATCK2(actor) = bot_aim(actor, weaponentity, WEP_CVAR_PRI(WEP_BLASTER, speed), 0, WEP_CVAR_PRI(WEP_BLASTER, lifetime), false, true);
253}
254
255METHOD(Vaporizer, wr_think, void(entity thiswep, entity actor, .entity weaponentity, int fire))
256{
257 float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(WEP_VAPORIZER, ammo));
258 // if the laser uses load, we also consider its ammo for reloading
259 if (WEP_CVAR(WEP_VAPORIZER, reload_ammo)
260 && WEP_CVAR_PRI(WEP_BLASTER, ammo)
261 && actor.(weaponentity).clip_load < min(vaporizer_ammo, WEP_CVAR_PRI(WEP_BLASTER, ammo)))
262 { // forced reload
263 thiswep.wr_reload(thiswep, actor, weaponentity);
264 actor.(weaponentity).hagar_load = false; // rocket minsta exclusive var
265 return;
266 }
267 if(WEP_CVAR(WEP_VAPORIZER, reload_ammo)
268 && actor.(weaponentity).clip_load < vaporizer_ammo)
269 { // forced reload
270 thiswep.wr_reload(thiswep, actor, weaponentity);
271 actor.(weaponentity).hagar_load = false; // rocket minsta exclusive var
272 return;
273 }
274
275 if((fire & 1) && (GetResource(actor, RES_CELLS) || !autocvar_g_rm) && !weaponLocked(actor))
276 {
277 if(weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(WEP_VAPORIZER, refire)))
278 {
279 W_Vaporizer_Attack(thiswep, actor, weaponentity);
280 weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(WEP_VAPORIZER, animtime), w_ready);
281 }
282 }
283
284 if((fire & 2) || ((fire & 1) && !GetResource(actor, RES_CELLS) && autocvar_g_rm))
285 {
287 {
288 bool rapid = autocvar_g_rm_laser_rapid;
289 //hagar_load was previously named held_down
290 if(actor.(weaponentity).jump_interval <= time && !actor.(weaponentity).hagar_load)
291 {
292 if(rapid)
293 actor.(weaponentity).hagar_load = true;
294 actor.(weaponentity).jump_interval = time + autocvar_g_rm_laser_refire;
295 actor.(weaponentity).jump_interval2 = time + autocvar_g_rm_laser_rapid_delay;
296 impressive_hits = 0;
297 W_RocketMinsta_Attack(actor, weaponentity, 0);
298 }
299 else if(rapid && actor.(weaponentity).jump_interval2 <= time && actor.(weaponentity).hagar_load)
300 {
302 impressive_hits = 0;
303 W_RocketMinsta_Attack(actor, weaponentity, 1);
304 //weapon_thinkf(actor, WFRAME_FIRE2, autocvar_g_rm_laser_rapid_animtime, w_ready);
305 }
306 }
307 else if (actor.(weaponentity).jump_interval <= time)
308 {
309 // handle refire manually, so that primary and secondary can be fired without conflictions (important for instagib)
310 actor.(weaponentity).jump_interval = time + WEP_CVAR_PRI(WEP_BLASTER, refire) * W_WeaponRateFactor(actor);
311
312 // decrease ammo for the laser?
313 if(WEP_CVAR_PRI(WEP_BLASTER, ammo))
314 W_DecreaseAmmo(thiswep, actor, WEP_CVAR_PRI(WEP_BLASTER, ammo), weaponentity);
315
316 makevectors(actor.v_angle);
317 W_Blaster_Attack(actor, weaponentity);
318
319 // now do normal refire
320 weapon_thinkf(actor, weaponentity, WFRAME_FIRE2, WEP_CVAR_PRI(WEP_BLASTER, animtime), w_ready);
321 }
322 }
323 else
324 actor.(weaponentity).hagar_load = false;
325}
326
327METHOD(Vaporizer, wr_setup, void(entity thiswep, entity actor, .entity weaponentity))
328{
329 actor.vaporizer_lasthit = 0;
330}
331
332METHOD(Vaporizer, wr_checkammo1, bool(entity thiswep, entity actor, .entity weaponentity))
333{
334 float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(WEP_VAPORIZER, ammo));
335 float ammo_amount = GetResource(actor, thiswep.ammo_type) >= vaporizer_ammo;
336 ammo_amount += actor.(weaponentity).(weapon_load[thiswep.m_id]) >= vaporizer_ammo;
337 return ammo_amount;
338}
339
340METHOD(Vaporizer, wr_checkammo2, bool(entity thiswep, entity actor, .entity weaponentity))
341{
342 if(!WEP_CVAR_PRI(WEP_BLASTER, ammo))
343 return true;
344 float ammo_amount = GetResource(actor, thiswep.ammo_type) >= WEP_CVAR_PRI(WEP_BLASTER, ammo);
345 ammo_amount += actor.(weaponentity).(weapon_load[thiswep.m_id]) >= WEP_CVAR_PRI(WEP_BLASTER, ammo);
346 return ammo_amount;
347}
348
349METHOD(Vaporizer, wr_resetplayer, void(entity thiswep, entity actor))
350{
351 actor.vaporizer_lasthit = 0;
352}
353
354METHOD(Vaporizer, wr_reload, void(entity thiswep, entity actor, .entity weaponentity))
355{
356 float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(WEP_VAPORIZER, ammo));
357 float used_ammo;
358 if(WEP_CVAR_PRI(WEP_BLASTER, ammo))
359 used_ammo = min(vaporizer_ammo, WEP_CVAR_PRI(WEP_BLASTER, ammo));
360 else
361 used_ammo = vaporizer_ammo;
362
363 W_Reload(actor, weaponentity, used_ammo, SND_RELOAD);
364}
365
366METHOD(Vaporizer, wr_suicidemessage, Notification(entity thiswep))
367{
368 return WEAPON_THINKING_WITH_PORTALS;
369}
370
371METHOD(Vaporizer, wr_killmessage, Notification(entity thiswep))
372{
373 return WEAPON_VAPORIZER_MURDER;
374}
375
376#endif
377#ifdef CSQC
378
379METHOD(Vaporizer, wr_impacteffect, void(entity thiswep, entity actor))
380{
381 vector org2 = w_org + w_backoff * 2;
382 pointparticles(EFFECT_VORTEX_IMPACT, org2, '0 0 0', 1);
383 if(!w_issilent)
384 sound(actor, CH_SHOTS, SND_VAPORIZER_IMPACT, VOL_BASE, ATTN_NORM);
385}
386
387METHOD(Vaporizer, wr_init, void(entity thiswep))
388{
390 {
391 precache_pic("gfx/reticle_nex");
392 }
393}
394
395METHOD(Vaporizer, wr_zoom, bool(entity thiswep, entity actor))
396{
398 {
399 return true;
400 }
401 else
402 {
403 // no weapon specific image for this weapon
404 return false;
405 }
406}
407
408#endif
409#ifdef MENUQC
413#include "blaster.qh"
414
415METHOD(Vaporizer, describe, string(Vaporizer this))
416{
417 TC(Vaporizer, this);
419 PAR(_("The %s is a unique weapon, firing a deadly beam of energy dealing a huge amount of damage. "
420 "In %s, the beam has the ability to instantly kill enemies with a single shot, unless they have an %s."), COLORED_NAME(this), COLORED_NAME(MUTATOR_mutator_instagib), COLORED_NAME(ITEM_ExtraLife));
421 PAR(_("The secondary fire shoots a laser identical to that fired by the %s, with strong knockback."), COLORED_NAME(WEP_BLASTER));
422 PAR(_("It is a superweapon, so isn't often found in game, except in %s where all players spawn with it."), COLORED_NAME(MUTATOR_mutator_instagib));
423 PAR(_("It consumes some %s ammo with each shot."), COLORED_NAME(ITEM_Cells));
424 PAR(W_Guide_Keybinds(this));
425 PAR(W_Guide_DPS_onlyOne(this.netname, "primary"));
426 return PAGE_TEXT;
427}
428
429#endif
void accuracy_add(entity this, Weapon w, float fired, float hit, float real)
update accuracy stats
Definition accuracy.qc:102
bool accuracy_canbegooddamage(entity attacker)
if damage were to occur, would accuracy_isgooddamage be able to return true?
Definition accuracy.qc:154
bool bot_aim(entity this,.entity weaponentity, float shotspeed, float shotspeedupward, float maxshottime, float applygravity, bool shot_accurate)
IntrusiveList g_bot_dodge
Definition api.qh:150
#define MUTATOR_CALLHOOK(id,...)
Definition base.qh:143
void W_Blaster_Attack(entity actor,.entity weaponentity)
Definition blaster.qc:54
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float GetResource(entity e, Resource res_type)
Returns the current amount of resource the given entity has.
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
Definition weapon.qh:44
int m_id
Definition weapon.qh:45
string netname
Definition powerups.qc:20
float lifetime
Definition powerups.qc:23
float cnt
Definition powerups.qc:24
entity playerslots[255]
Definition main.qh:84
IntrusiveList g_drawables
Definition main.qh:91
vector view_origin
Definition main.qh:109
entity owner
Definition main.qh:87
bool button_zoom
Definition main.qh:113
int sv_entnum
Definition main.qh:186
#define colormapPaletteColor(c, isPants)
Definition color.qh:5
#define COLORED_NAME(this)
Definition color.qh:195
const int IT_UNLIMITED_AMMO
Definition item.qh:23
bool IsFlying(entity this)
Definition player.qc:836
#define IS_DEAD(s)
Definition player.qh:245
#define IS_PLAYER(s)
Definition player.qh:243
#define PHYS_INPUT_BUTTON_ATCK(s)
Definition player.qh:150
#define PHYS_INPUT_BUTTON_ATCK2(s)
Definition player.qh:152
float W_WeaponRateFactor(entity this)
void Draw_CylindricLine(vector from, vector to, float thickness, string texture, float aspect, float shift, vector rgb, float theAlpha, float drawflag, vector vieworg)
Definition draw.qh:11
const int FL_PROJECTILE
Definition constants.qh:85
bool autocvar_cl_reticle_weapon
Definition crosshair.qh:5
bool autocvar_cl_reticle
Definition crosshair.qh:3
float Q3SURFACEFLAG_SKY
const float DRAWFLAG_NORMAL
float drawmask
vector particles_colormin
const float MASK_NORMAL
float time
vector v_right
vector trace_endpos
float particles_alphamax
float nextthink
float trace_dphitq3surfaceflags
vector particles_colormax
float particles_alphamin
const float ATTN_NORM
float Q3SURFACEFLAG_NOIMPACT
float PARTICLES_USECOLOR
float particles_fade
#define spawn
void CSQCProjectile(entity e, float clientanimate, int type, float docull)
float RadiusDamage(entity inflictor, entity attacker, float coredamage, float edgedamage, float rad, entity cantbe, entity mustbe, float forceintensity, int deathtype,.entity weaponentity, entity directhitentity)
Definition damage.qc:981
float yoda
Definition damage.qh:48
int impressive_hits
Definition damage.qh:49
vector w_org
vector w_backoff
float w_issilent
const int HITTYPE_SPLASH
Definition all.qh:30
void SUB_Remove(entity this)
Remove entity.
Definition defer.qh:13
float speed
Definition dynlight.qc:9
#define pointparticles(effect, org, vel, howmany)
Definition effect.qh:7
#define particleeffectnum(e)
Definition effect.qh:3
int entcs_GetClientColors(int i)
Definition ent_cs.qh:115
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
#define TC(T, sym)
Definition _all.inc:82
#define NET_HANDLE(id, param)
Definition net.qh:15
#define ReadVector()
Definition net.qh:367
#define Net_Accept(classname)
Definition net.qh:201
#define WriteHeader(to, id)
Definition net.qh:221
int ReadByte()
#define REGISTER_NET_TEMP(id)
Definition net.qh:28
void WarpZone_TraceBox_ThroughZone(vector org, vector mi, vector ma, vector end, float nomonsters, entity forent, entity zone, WarpZone_trace_callback_t cb)
Definition common.qc:212
void WarpZone_TrailParticles_WithMultiplier(entity own, float eff, vector org, vector end, float f, int boxflags)
Definition common.qc:489
vector WarpZone_UnTransformOrigin(entity wz, vector v)
Definition common.qc:545
vector WarpZone_TransformOrigin(entity wz, vector v)
Definition common.qc:509
entity WarpZone_trace_transform
Definition common.qh:37
#define MOVE_NOTHING
Definition common.qh:33
float bound(float min, float value, float max)
float cvar(string name)
float random(void)
string precache_pic(string name,...)
float vlen(vector v)
vector vectoangles(vector v)
float min(float f,...)
vector normalize(vector v)
void WriteByte(float data, float dest, float desto)
float MSG_BROADCAST
Definition menudefs.qc:55
float max(float f,...)
#define etof(e)
Definition misc.qh:25
void set_movetype(entity this, int mt)
Definition movetypes.qc:4
const int MOVETYPE_BOUNCEMISSILE
Definition movetypes.qh:140
var void func_null()
string string_null
Definition nil.qh:9
void Send_Notification(NOTIF broadcast, entity client, MSG net_type, Notification net_name,...count)
Definition all.qc:1573
entity Notification
always last
Definition all.qh:81
#define METHOD(cname, name, prototype)
Definition oo.qh:269
#define NULL
Definition post.qh:14
#define makevectors
Definition post.qh:21
const int PROJECTILE_ROCKETMINSTA_LASER
#define setthink(e, f)
vector
Definition self.qh:92
entity entity toucher
Definition self.qh:72
#define settouch(e, f)
Definition self.qh:73
void adaptor_think2use_hittype_splash(entity this)
Definition common.qc:106
const int MIF_SPLASH
Definition common.qh:46
int projectiledeathtype
Definition common.qh:21
#define PROJECTILE_TOUCH(e, t)
Definition common.qh:28
IntrusiveList g_projectiles
Definition common.qh:58
#define PROJECTILE_MAKETRIGGER(e)
Definition common.qh:34
const float VOL_BASE
Definition sound.qh:36
const int CH_SHOTS
Definition sound.qh:14
const int CH_WEAPON_A
Definition sound.qh:7
const float ATTEN_NORM
Definition sound.qh:30
#define sound(e, c, s, v, a)
Definition sound.qh:52
#define PAGE_TEXT
Definition string.qh:643
#define PAR(...)
Adds an individually translatable paragraph to PAGE_TEXT without having to deal with strcat and sprin...
Definition string.qh:649
#define PAGE_TEXT_INIT()
Definition string.qh:642
const int DAMAGE_NO
Definition subs.qh:79
const int DAMAGE_AIM
Definition subs.qh:81
float takedamage
Definition subs.qh:78
float autocvar_g_rm_laser_spread_random
float autocvar_g_rm_laser_refire
float autocvar_g_rm
Definition sv_instagib.qh:8
float autocvar_g_rm_laser_spread
float autocvar_g_rm_laser_rapid_delay
float autocvar_g_rm_laser_rapid
float autocvar_g_rm_laser_lifetime
bool autocvar_g_instagib
float autocvar_g_rm_laser_count
float autocvar_g_rm_radius
float autocvar_g_rm_laser_damage
float autocvar_g_rm_damage
Definition sv_instagib.qh:9
float autocvar_g_rm_laser_speed
float autocvar_g_rm_laser_rapid_refire
float autocvar_g_rm_force
float autocvar_g_rm_laser_radius
float autocvar_g_rm_laser_force
float autocvar_g_rm_edgedamage
float autocvar_g_rm_laser
float ammo
Definition sv_turrets.qh:43
#define DIFF_TEAM(a, b)
Definition teams.qh:242
entity realowner
vector W_CalculateProjectileVelocity(entity actor, vector pvelocity, vector mvelocity, float forceAbsolute)
Definition tracing.qc:176
void FireRailgunBullet(entity this,.entity weaponentity, vector start, vector end, float bdamage, bool headshot_notify, float bforce, float mindist, float maxdist, float halflifedist, float forcehalflifedist, int deathtype)
Definition tracing.qc:238
vector w_shotdir
Definition tracing.qh:20
#define W_SetupShot_ProjectileSize(ent, wepent, mi, ma, antilag, recoil, snd, chan, maxdamage, deathtype)
Definition tracing.qh:30
vector w_shotorg
Definition tracing.qh:19
#define W_SetupShot(ent, wepent, antilag, recoil, snd, chan, maxdamage, deathtype)
Definition tracing.qh:34
void W_RocketMinsta_Attack(entity actor,.entity weaponentity, int mode)
Definition vaporizer.qc:191
void SendCSQCVaporizerBeamParticle(entity player, int hit)
Definition vaporizer.qc:8
void W_Vaporizer_Attack(Weapon thiswep, entity actor,.entity weaponentity)
Definition vaporizer.qc:117
void W_RocketMinsta_Laser_Explode_use(entity this, entity actor, entity trigger)
Definition vaporizer.qc:176
void W_RocketMinsta_Laser_Explode(entity this, entity directhitentity)
Definition vaporizer.qc:161
void W_RocketMinsta_Laser_Touch(entity this, entity toucher)
Definition vaporizer.qc:181
void W_RocketMinsta_Explosion(entity actor,.entity weaponentity, vector loc)
Definition vaporizer.qc:106
void W_RocketMinsta_Laser_Damage(entity this, entity directhitentity)
Definition vaporizer.qc:153
int rm_laser_count
Definition vaporizer.qh:68
float jump_interval
Definition vaporizer.qh:66
float jump_interval2
Definition vaporizer.qh:67
float zoomscript_caught
Definition view.qh:121
string W_Guide_Keybinds(Weapon wep)
Definition all.qc:836
void W_MuzzleFlash(Weapon thiswep, entity actor,.entity weaponentity, vector shotorg, vector shotdir)
Definition all.qc:728
string W_Guide_DPS_onlyOne(string name, string fire)
Definition all.qc:926
#define WEP_CVAR_PRI(wep, name)
Definition all.qh:322
#define WEP_CVAR(wep, name)
Definition all.qh:321
int max_shot_distance
Definition weapon.qh:203
void W_DecreaseAmmo(Weapon wep, entity actor, float ammo_use,.entity weaponentity)
void W_Reload(entity actor,.entity weaponentity, float sent_ammo_min, Sound sent_sound)
void weapon_thinkf(entity actor,.entity weaponentity, WFRAME fr, float t, void(Weapon thiswep, entity actor,.entity weaponentity, int fire) func)
bool weapon_prepareattack(Weapon thiswep, entity actor,.entity weaponentity, bool secondary, float attacktime)
void w_ready(Weapon thiswep, entity actor,.entity weaponentity, int fire)
bool weaponLocked(entity player)
entity weaponentity_fld
float weapon_load[REGISTRY_MAX(Weapons)]
int hagar_load
Definition wepent.qh:13