Xonotic
vaporizer.qc
Go to the documentation of this file.
1 #include "vaporizer.qh"
2 
3 REGISTER_NET_TEMP(TE_CSQC_VAPORBEAMPARTICLE)
4 
5 #if defined(SVQC)
6 void SendCSQCVaporizerBeamParticle(entity player, int hit) {
7  vector v;
9  WriteHeader(MSG_BROADCAST, TE_CSQC_VAPORBEAMPARTICLE);
10  WriteVector(MSG_BROADCAST, w_shotorg);
11  WriteVector(MSG_BROADCAST, v);
13  WriteByte(MSG_BROADCAST, etof(player));
14  WriteByte(MSG_BROADCAST, player.team);
15 }
16 #elif defined(CSQC)
17 bool autocvar_cl_vaporizerbeam_particle = false;
18 float autocvar_cl_vaporizerbeam_lifetime = 0.8;
19 float autocvar_cl_vaporizerbeam_colorboost = 0.7;
20 
21 string Draw_VaporizerBeam_trace_callback_tex;
22 float Draw_VaporizerBeam_trace_callback_rnd;
23 vector Draw_VaporizerBeam_trace_callback_rgb;
24 float Draw_VaporizerBeam_trace_callback_a;
25 void Draw_VaporizerBeam_trace_callback(vector start, vector hit, vector end)
26 {
27  float i;
28  vector vorg;
30  for(i = 0; i < Draw_VaporizerBeam_trace_callback_a; ++i)
31  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);
32  Draw_VaporizerBeam_trace_callback_rnd += 0.25 * vlen(hit - start) / 8;
33 }
34 
35 .vector vorg1, vorg2;
36 void VaporizerBeam_Draw(entity this)
37 {
38  //draw either the old v2.3 beam or the new beam
40 
41  string tex = "particles/lgbeam";
42  if(this.cnt)
43  tex = "particles/gauntletbeam";
44  vector rgb;
45  //entity e = CSQCModel_server2csqc(this.sv_entnum - 1);
46  //if (e == NULL)
47  //{
48  rgb = colormapPaletteColor(entcs_GetClientColors(this.sv_entnum - 1) & 0x0F, true);
49  //rgb = '1 1 1';
50  //}
51  //else
52  // rgb = e.glowmod;
53  rgb *= (1 + autocvar_cl_vaporizerbeam_colorboost);
54 
55  float fail = (this.nextthink - time);
56 
57  Draw_VaporizerBeam_trace_callback_tex = tex;
58  Draw_VaporizerBeam_trace_callback_rnd = 0;
59  Draw_VaporizerBeam_trace_callback_rgb = rgb;
60  Draw_VaporizerBeam_trace_callback_a = bound(0, fail, 1);
61  WarpZone_TraceBox_ThroughZone(this.vorg1, '0 0 0', '0 0 0', this.vorg2, MOVE_NOTHING, NULL, NULL, Draw_VaporizerBeam_trace_callback);
62  Draw_VaporizerBeam_trace_callback_tex = string_null;
63 
64  /*if(!MUTATOR_CALLHOOK(Particles_VaporizerBeam, this.vorg1, this.vorg2))
65  if(autocvar_cl_particles_oldvortexbeam)
66  WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM_OLD), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);
67  else
68  WarpZone_TrailParticles_WithMultiplier(NULL, particleeffectnum(EFFECT_VORTEX_BEAM), this.vorg1, this.vorg2, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);*/
69 }
70 
71 NET_HANDLE(TE_CSQC_VAPORBEAMPARTICLE, bool isNew)
72 {
73  Net_Accept(vortex_beam);
74  setthink(this, SUB_Remove);
75  this.nextthink = time + bound(0, autocvar_cl_vaporizerbeam_lifetime, 10);
76  this.draw = VaporizerBeam_Draw;
77  if (isNew) IL_PUSH(g_drawables, this);
78  this.drawmask = MASK_NORMAL;
79 
80  this.vorg1 = ReadVector();
81  this.vorg2 = ReadVector();
82  this.cnt = ReadByte();
83  int myowner = ReadByte();
84  this.owner = playerslots[myowner - 1];
85  this.sv_entnum = myowner;
86  this.team = ReadByte() - 1;
87 
88  //pointparticles(EFFECT_VORTEX_MUZZLEFLASH, this.vorg1, normalize(this.vorg2 - this.vorg1) * 1000, 1);
89 
90  if(autocvar_cl_vaporizerbeam_particle)
91  {
92  WarpZone_TrailParticles(NULL, particleeffectnum(((this.cnt) ? EFFECT_VAPORIZER_HIT(this.team) : EFFECT_VAPORIZER(this.team))), this.vorg1, this.vorg2);
93  this.draw = func_null;
94  this.drawmask = MASK_NORMAL;
95  delete(this);
96  }
97 
98  return true;
99 }
100 #endif
101 
102 #ifdef SVQC
103 
104 void W_RocketMinsta_Explosion(entity actor, .entity weaponentity, vector loc)
105 {
106  if(accuracy_canbegooddamage(actor))
107  accuracy_add(actor, WEP_DEVASTATOR, autocvar_g_rm_damage, 0);
108  entity dmgent = spawn();
109  dmgent.owner = dmgent.realowner = actor;
110  setorigin(dmgent, loc);
112  delete(dmgent);
113 }
114 
115 void W_Vaporizer_Attack(Weapon thiswep, entity actor, .entity weaponentity)
116 {
117  bool flying = IsFlying(actor); // do this BEFORE to make the trace values from FireRailgunBullet last
118  float vaporizer_damage = ((WEP_CVAR_PRI(vaporizer, damage) > 0) ? WEP_CVAR_PRI(vaporizer, damage) : 10000);
119 
120  W_SetupShot(actor, weaponentity, true, 0, SND_Null, CH_WEAPON_A, vaporizer_damage, thiswep.m_id);
121  // handle sound separately so we can change the volume
122  // added bonus: no longer plays the strength sound (strength gives no bonus to instakill anyway)
123  sound (actor, CH_WEAPON_A, SND_MINSTANEXFIRE, VOL_BASE * 0.8, ATTEN_NORM);
124 
125  yoda = 0;
126  impressive_hits = 0;
127  FireRailgunBullet(actor, weaponentity, w_shotorg, w_shotorg + w_shotdir * max_shot_distance, vaporizer_damage, true, WEP_CVAR_PRI(vaporizer, force), 0, 0, 0, 0, thiswep.m_id);
128 
129  // do this now, as goodhits is disabled below
131  W_MuzzleFlash(thiswep, actor, weaponentity, w_shotorg, normalize(v - w_shotorg));
132  SendCSQCVaporizerBeamParticle(actor, impressive_hits);
133 
134  if(yoda && flying)
135  Send_Notification(NOTIF_ONE, actor, MSG_ANNCE, ANNCE_ACHIEVEMENT_YODA);
136  if(impressive_hits && actor.vaporizer_lasthit)
137  {
138  Send_Notification(NOTIF_ONE, actor, MSG_ANNCE, ANNCE_ACHIEVEMENT_IMPRESSIVE);
139  impressive_hits = 0; // only every second time
140  }
141 
142  actor.vaporizer_lasthit = impressive_hits;
143 
144  if(autocvar_g_rm)
146  W_RocketMinsta_Explosion(actor, weaponentity, trace_endpos);
147 
148  W_DecreaseAmmo(thiswep, actor, ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(vaporizer, ammo)), weaponentity);
149 }
150 
151 void W_RocketMinsta_Laser_Damage(entity this, entity directhitentity)
152 {
153  int laser_count = max(1, this.rm_laser_count);
154  float laser_force = autocvar_g_rm_laser_force / laser_count;
155  float laser_damage = autocvar_g_rm_laser_damage / laser_count;
156  RadiusDamage(this, this.realowner, laser_damage, laser_damage, autocvar_g_rm_laser_radius, NULL, NULL, laser_force, this.projectiledeathtype, this.weaponentity_fld, directhitentity);
157 }
158 
159 void W_RocketMinsta_Laser_Explode(entity this, entity directhitentity)
160 {
161  if(directhitentity.takedamage == DAMAGE_AIM)
162  if(IS_PLAYER(directhitentity))
163  if(DIFF_TEAM(this.realowner, directhitentity))
164  if(!IS_DEAD(directhitentity))
165  if(IsFlying(directhitentity))
166  Send_Notification(NOTIF_ONE, this.realowner, MSG_ANNCE, ANNCE_ACHIEVEMENT_ELECTROBITCH);
167 
168  this.event_damage = func_null;
169  this.takedamage = DAMAGE_NO;
170  W_RocketMinsta_Laser_Damage(this, directhitentity);
171  delete(this);
172 }
173 
174 void W_RocketMinsta_Laser_Explode_use(entity this, entity actor, entity trigger)
175 {
176  W_RocketMinsta_Laser_Explode(this, trigger); // we probably don't want trigger used here, but this matches closest to old behaviour
177 }
178 
179 void W_RocketMinsta_Laser_Touch(entity this, entity toucher)
180 {
181  PROJECTILE_TOUCH(this, toucher);
182  //W_RocketMinsta_Laser_Explode ();
183  W_RocketMinsta_Laser_Damage(this, toucher);
184  delete(this);
185 }
186 
187 // mode 0 fires many projectiles
188 // mode 1 fires 1 projectile
189 void W_RocketMinsta_Attack(entity actor, .entity weaponentity, int mode)
190 {
191  makevectors(actor.v_angle);
192 
193  entity proj;
194  int laser_count = max(1, autocvar_g_rm_laser_count);
195  int total = (mode == 0) ? laser_count : 1;
196  Sound snd = (mode == 0) ? SND_CRYLINK_FIRE : SND_ELECTRO_FIRE2;
197  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);
198 
199  // uses electro effects
200  W_MuzzleFlash(WEP_ELECTRO, actor, weaponentity, w_shotorg, w_shotdir);
201 
202  for (int counter = 0; counter < total; counter++)
203  {
204  proj = new(plasma_prim);
205  proj.owner = proj.realowner = actor;
206  proj.bot_dodge = true;
207  proj.bot_dodgerating = autocvar_g_rm_laser_damage;
208  proj.use = W_RocketMinsta_Laser_Explode_use;
210  proj.nextthink = time + autocvar_g_rm_laser_lifetime;
212  proj.projectiledeathtype = WEP_ELECTRO.m_id;
213  proj.weaponentity_fld = weaponentity;
214  setorigin(proj, w_shotorg);
215 
216  proj.rm_laser_count = total;
217 
218  //W_SetupProjectileVelocity(proj, autocvar_g_rm_laser_speed, spread * (rndspread ? random() : 1) * autocvar_g_rm_laser_speed);
219 
221  if (mode == 0)
222  {
224  //W_SETUPPROJECTILEVELOCITY(proj, g_balance_minstanex_laser);
225  proj.velocity = (w_shotdir + (((counter + 0.5) / total) * 2 - 1) * v_right * spread) * cvar("g_rm_laser_speed");
226  proj.velocity.z += cvar("g_rm_laser_zspread") * (random() - 0.5);
227  }
228  else
229  proj.velocity = w_shotdir * autocvar_g_rm_laser_speed;
230  proj.velocity = W_CalculateProjectileVelocity(actor, actor.velocity, proj.velocity, true);
231  proj.angles = vectoangles(proj.velocity);
232  settouch(proj, W_RocketMinsta_Laser_Touch);
233  setsize(proj, '0 0 -3', '0 0 -3');
234  proj.flags = FL_PROJECTILE;
235  IL_PUSH(g_projectiles, proj);
236  IL_PUSH(g_bot_dodge, proj);
237  proj.missile_flags = MIF_SPLASH;
238 
240 
241  MUTATOR_CALLHOOK(EditProjectile, actor, proj);
242  }
243 }
244 
245 METHOD(Vaporizer, wr_aim, void(entity thiswep, entity actor, .entity weaponentity))
246 {
247  if((actor.items & IT_UNLIMITED_AMMO) || GetResource(actor, thiswep.ammo_type) > 0)
248  PHYS_INPUT_BUTTON_ATCK(actor) = bot_aim(actor, weaponentity, 1000000, 0, 1, false);
249  else
250  PHYS_INPUT_BUTTON_ATCK2(actor) = bot_aim(actor, weaponentity, WEP_CVAR_SEC(vaporizer, speed), 0, WEP_CVAR_SEC(vaporizer, lifetime), false); // WEAPONTODO: replace with proper vaporizer cvars
251 }
252 METHOD(Vaporizer, wr_think, void(entity thiswep, entity actor, .entity weaponentity, int fire))
253 {
254  float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(vaporizer, ammo));
255  // if the laser uses load, we also consider its ammo for reloading
256  if(WEP_CVAR(vaporizer, reload_ammo) && WEP_CVAR_SEC(vaporizer, ammo) && actor.(weaponentity).clip_load < min(vaporizer_ammo, WEP_CVAR_SEC(vaporizer, ammo))) { // forced reload
257  thiswep.wr_reload(thiswep, actor, weaponentity);
258  } else if(WEP_CVAR(vaporizer, reload_ammo) && actor.(weaponentity).clip_load < vaporizer_ammo) { // forced reload
259  thiswep.wr_reload(thiswep, actor, weaponentity);
260  }
261  if((fire & 1) && (GetResource(actor, RES_CELLS) || !autocvar_g_rm) && !weaponLocked(actor))
262  {
263  if(weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(vaporizer, refire)))
264  {
265  W_Vaporizer_Attack(thiswep, actor, weaponentity);
266  weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(vaporizer, animtime), w_ready);
267  }
268  }
269  if((fire & 2) || ((fire & 1) && !GetResource(actor, RES_CELLS) && autocvar_g_rm))
270  {
272  {
273  bool rapid = autocvar_g_rm_laser_rapid;
274  if(actor.(weaponentity).jump_interval <= time && !actor.(weaponentity).held_down)
275  {
276  if(rapid)
277  actor.(weaponentity).held_down = true;
278  actor.(weaponentity).jump_interval = time + autocvar_g_rm_laser_refire;
279  actor.(weaponentity).jump_interval2 = time + autocvar_g_rm_laser_rapid_delay;
280  impressive_hits = 0;
281  W_RocketMinsta_Attack(actor, weaponentity, 0);
282  }
283  else if(rapid && actor.(weaponentity).jump_interval2 <= time && actor.(weaponentity).held_down)
284  {
285  actor.(weaponentity).jump_interval2 = time + autocvar_g_rm_laser_rapid_refire;
286  impressive_hits = 0;
287  W_RocketMinsta_Attack(actor, weaponentity, 1);
288  //weapon_thinkf(actor, WFRAME_FIRE2, autocvar_g_rm_laser_rapid_animtime, w_ready);
289  }
290  }
291  else if (actor.(weaponentity).jump_interval <= time)
292  {
293  // handle refire manually, so that primary and secondary can be fired without conflictions (important for instagib)
294  actor.(weaponentity).jump_interval = time + WEP_CVAR_SEC(vaporizer, refire) * W_WeaponRateFactor(actor);
295 
296  // decrease ammo for the laser?
297  if(WEP_CVAR_SEC(vaporizer, ammo))
298  W_DecreaseAmmo(thiswep, actor, WEP_CVAR_SEC(vaporizer, ammo), weaponentity);
299 
300  BLASTER_SECONDARY_ATTACK(vaporizer, actor, weaponentity);
301 
302  // now do normal refire
303  weapon_thinkf(actor, weaponentity, WFRAME_FIRE2, WEP_CVAR_SEC(vaporizer, animtime), w_ready);
304  }
305  }
306  else
307  actor.(weaponentity).held_down = false;
308 }
309 METHOD(Vaporizer, wr_setup, void(entity thiswep, entity actor, .entity weaponentity))
310 {
311  actor.vaporizer_lasthit = 0;
312 }
313 METHOD(Vaporizer, wr_checkammo1, bool(entity thiswep, entity actor, .entity weaponentity))
314 {
315  float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(vaporizer, ammo));
316  float ammo_amount = GetResource(actor, thiswep.ammo_type) >= vaporizer_ammo;
317  ammo_amount += actor.(weaponentity).(weapon_load[thiswep.m_id]) >= vaporizer_ammo;
318  return ammo_amount;
319 }
320 METHOD(Vaporizer, wr_checkammo2, bool(entity thiswep, entity actor, .entity weaponentity))
321 {
322  if(!WEP_CVAR_SEC(vaporizer, ammo))
323  return true;
324  float ammo_amount = GetResource(actor, thiswep.ammo_type) >= WEP_CVAR_SEC(vaporizer, ammo);
325  ammo_amount += actor.(weaponentity).(weapon_load[thiswep.m_id]) >= WEP_CVAR_SEC(vaporizer, ammo);
326  return ammo_amount;
327 }
328 METHOD(Vaporizer, wr_resetplayer, void(entity thiswep, entity actor))
329 {
330  actor.vaporizer_lasthit = 0;
331 }
332 METHOD(Vaporizer, wr_reload, void(entity thiswep, entity actor, .entity weaponentity))
333 {
334  float vaporizer_ammo = ((autocvar_g_instagib) ? 1 : WEP_CVAR_PRI(vaporizer, ammo));
335  float used_ammo;
336  if(WEP_CVAR_SEC(vaporizer, ammo))
337  used_ammo = min(vaporizer_ammo, WEP_CVAR_SEC(vaporizer, ammo));
338  else
339  used_ammo = vaporizer_ammo;
340 
341  W_Reload(actor, weaponentity, used_ammo, SND_RELOAD);
342 }
343 METHOD(Vaporizer, wr_suicidemessage, Notification(entity thiswep))
344 {
345  return WEAPON_THINKING_WITH_PORTALS;
346 }
347 METHOD(Vaporizer, wr_killmessage, Notification(entity thiswep))
348 {
349  return WEAPON_VAPORIZER_MURDER;
350 }
351 
352 #endif
353 #ifdef CSQC
354 
355 METHOD(Vaporizer, wr_impacteffect, void(entity thiswep, entity actor))
356 {
357  vector org2 = w_org + w_backoff * 6;
359  {
360  pointparticles(EFFECT_BLASTER_IMPACT, org2, w_backoff * 1000, 1);
361  if(!w_issilent) { sound(actor, CH_SHOTS, SND_LASERIMPACT, VOL_BASE, ATTN_NORM); }
362  }
363  else
364  {
365  pointparticles(EFFECT_VORTEX_IMPACT, org2, '0 0 0', 1);
366  if(!w_issilent) { sound(actor, CH_SHOTS, SND_NEXIMPACT, VOL_BASE, ATTN_NORM); }
367  }
368 }
369 METHOD(Vaporizer, wr_init, void(entity thiswep))
370 {
372  {
373  precache_pic("gfx/reticle_nex");
374  }
375 }
376 METHOD(Vaporizer, wr_zoom, bool(entity thiswep, entity actor))
377 {
379  {
380  return true;
381  }
382  else
383  {
384  // no weapon specific image for this weapon
385  return false;
386  }
387 }
388 
389 #endif
const int HITTYPE_SPLASH
automatically set by RadiusDamage
Definition: all.qh:27
#define WEP_CVAR_PRI(wepname, name)
Definition: all.qh:300
#define PHYS_INPUT_BUTTON_ATCK2(s)
Definition: player.qh:148
bool bot_aim(entity this,.entity weaponentity, float shotspeed, float shotspeedupward, float maxshottime, float applygravity)
#define WEP_CVAR_SEC(wepname, name)
Definition: all.qh:301
float weapon_load[REGISTRY_MAX(Weapons)]
Definition: weaponsystem.qh:29
string string_null
Definition: nil.qh:9
entity EFFECT_VAPORIZER_HIT(int teamid)
Definition: all.inc:77
float speed
Definition: subs.qh:41
vector w_shotorg
Definition: tracing.qh:18
float autocvar_g_rm_laser_rapid
Definition: sv_instagib.qh:21
#define PROJECTILE_MAKETRIGGER(e)
Definition: common.qh:29
float zoomscript_caught
Definition: view.qh:117
float autocvar_g_rm_laser_rapid_delay
Definition: sv_instagib.qh:23
float trace_dphitq3surfaceflags
const int MIF_SPLASH
Definition: common.qh:34
int team
Definition: main.qh:157
float autocvar_g_rm_laser_spread
Definition: sv_instagib.qh:16
#define MOVE_NOTHING
Definition: common.qh:33
#define W_SetupShot_ProjectileSize(ent, wepent, mi, ma, antilag, recoil, snd, chan, maxdamage, deathtype)
Definition: tracing.qh:29
entity() spawn
float DAMAGE_AIM
Definition: progsdefs.qc:284
vector WarpZone_TransformOrigin(entity wz, vector v)
Definition: common.qc:499
int sv_entnum
Definition: main.qh:155
float MOVETYPE_BOUNCEMISSILE
Definition: progsdefs.qc:257
void w_ready(Weapon thiswep, entity actor,.entity weaponentity, int fire)
vector view_origin
Definition: main.qh:93
#define NET_HANDLE(id, param)
Definition: net.qh:12
#define WEP_CVAR(wepname, name)
Definition: all.qh:299
float autocvar_g_rm_force
Definition: sv_instagib.qh:11
vector w_shotdir
Definition: tracing.qh:19
entity weaponentity_fld
Definition: weaponsystem.qh:27
entity playerslots[255]
Definition: main.qh:70
#define METHOD(cname, name, prototype)
Definition: oo.qh:257
void CSQCProjectile(entity e, float clientanimate, int type, float docull)
#define DIFF_TEAM(a, b)
Definition: teams.qh:240
float autocvar_g_rm_laser_count
Definition: sv_instagib.qh:14
float particles_fade
int impressive_hits
Definition: damage.qh:52
int clip_load
Definition: wepent.qh:14
entity owner
Definition: main.qh:73
IntrusiveList g_bot_dodge
Definition: api.qh:150
bool autocvar_cl_reticle
Definition: crosshair.qh:3
vector WarpZone_UnTransformOrigin(entity wz, vector v)
Definition: common.qc:535
#define PROJECTILE_TOUCH(e, t)
Definition: common.qh:27
const float ATTN_NORM
Definition: csprogsdefs.qc:226
float ammo
Definition: sv_turrets.qh:44
bool weaponLocked(entity player)
float autocvar_g_rm_radius
Definition: sv_instagib.qh:12
float particles_alphamin
float autocvar_g_rm_laser_radius
Definition: sv_instagib.qh:24
bool autocvar_g_instagib
Definition: sv_instagib.qh:27
float lifetime
Definition: powerups.qc:23
float Q3SURFACEFLAG_SKY
float cnt
Definition: powerups.qc:24
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
const int CH_WEAPON_A
Definition: sound.qh:7
bool weapon_prepareattack(Weapon thiswep, entity actor,.entity weaponentity, bool secondary, float attacktime)
#define pointparticles
Definition: csprogsdefs.qh:13
#define NULL
Definition: post.qh:17
const float DRAWFLAG_NORMAL
Definition: csprogsdefs.qc:317
const float VOL_BASE
Definition: sound.qh:36
vector trace_endpos
Definition: csprogsdefs.qc:37
#define PHYS_INPUT_BUTTON_ATCK(s)
Definition: player.qh:146
float autocvar_g_rm_laser_force
Definition: sv_instagib.qh:25
float takedamage
Definition: progsdefs.qc:147
float autocvar_g_rm
Definition: sv_instagib.qh:8
float autocvar_g_rm_laser_damage
Definition: sv_instagib.qh:19
const int HITTYPE_SECONDARY
Definition: all.qh:25
#define W_SetupShot(ent, wepent, antilag, recoil, snd, chan, maxdamage, deathtype)
Definition: tracing.qh:33
Definition: sound.qh:119
float Q3SURFACEFLAG_NOIMPACT
const float MASK_NORMAL
Definition: csprogsdefs.qc:164
#define IS_DEAD(s)
Definition: utils.qh:26
float drawmask
Definition: csprogsdefs.qc:95
const float ATTEN_NORM
Definition: sound.qh:30
float nextthink
Definition: csprogsdefs.qc:121
bool autocvar_cl_reticle_weapon
Definition: crosshair.qh:5
bool button_zoom
Definition: main.qh:97
const int CH_SHOTS
Definition: sound.qh:14
bool IsFlying(entity this)
Definition: player.qc:804
float w_deathtype
Definition: damage.qh:97
const int PROJECTILE_ROCKETMINSTA_LASER
Definition: projectiles.qh:37
vector(float skel, float bonenum) _skel_get_boneabs_hidden
entity WarpZone_trace_transform
Definition: common.qh:37
float autocvar_g_rm_edgedamage
Definition: sv_instagib.qh:10
IntrusiveList g_projectiles
Definition: common.qh:46
float autocvar_g_rm_laser_speed
Definition: sv_instagib.qh:15
vector v
Definition: ent_cs.qc:116
float GetResource(entity e, Resource res_type)
Returns the current amount of resource the given entity has.
Definition: cl_resources.qc:10
void accuracy_add(entity this, Weapon w, float fired, float hit)
Definition: accuracy.qc:83
entity Notification
always last
Definition: all.qh:82
void weapon_thinkf(entity actor,.entity weaponentity, WFRAME fr, float t, void(Weapon thiswep, entity actor,.entity weaponentity, int fire) func)
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:1057
vector v_right
Definition: csprogsdefs.qc:31
void WarpZone_TrailParticles(entity own, float eff, vector org, vector end)
Definition: common.qc:464
entity realowner
Definition: common.qh:25
#define MUTATOR_CALLHOOK(id,...)
Definition: base.qh:140
float autocvar_g_rm_laser_spread_random
Definition: sv_instagib.qh:17
setorigin(ent, v)
#define setthink(e, f)
#define REGISTER_NET_TEMP(id)
Definition: net.qh:33
void adaptor_think2use_hittype_splash(entity this)
Definition: common.qc:110
void W_DecreaseAmmo(Weapon wep, entity actor, float ammo_use,.entity weaponentity)
vector W_CalculateProjectileVelocity(entity actor, vector pvelocity, vector mvelocity, float forceAbsolute)
Definition: tracing.qc:169
#define sound(e, c, s, v, a)
Definition: sound.qh:52
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:231
float autocvar_g_rm_laser_lifetime
Definition: sv_instagib.qh:18
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
Definition: weapon.qh:41
float particles_alphamax
float time
Definition: csprogsdefs.qc:16
int m_id
Definition: weapon.qh:42
bool accuracy_canbegooddamage(entity attacker)
Definition: accuracy.qc:132
#define makevectors
Definition: post.qh:21
float W_WeaponRateFactor(entity this)
Definition: weaponsystem.qc:33
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:202
entity EFFECT_VAPORIZER(int teamid)
Definition: all.inc:67
float DAMAGE_NO
Definition: progsdefs.qc:282
float autocvar_g_rm_laser_refire
Definition: sv_instagib.qh:20
IntrusiveList g_drawables
Definition: main.qh:77
void set_movetype(entity this, int mt)
#define IS_PLAYER(v)
Definition: utils.qh:9
#define colormapPaletteColor(c, isPants)
Definition: color.qh:5
var void func_null()
float yoda
Definition: damage.qh:51
float autocvar_g_rm_laser_rapid_refire
Definition: sv_instagib.qh:22
float autocvar_g_rm_laser
Definition: sv_instagib.qh:13
void W_Reload(entity actor,.entity weaponentity, float sent_ammo_min, Sound sent_sound)
int projectiledeathtype
Definition: common.qh:20
float autocvar_g_rm_damage
Definition: sv_instagib.qh:9
#define particleeffectnum(e)
Definition: effect.qh:3