vkQuake2 doxygen  1.0 dev
m_infantry.c File Reference
#include "g_local.h"
#include "m_infantry.h"

Go to the source code of this file.

Functions

void InfantryMachineGun (edict_t *self)
 
void infantry_stand (edict_t *self)
 
void infantry_fidget (edict_t *self)
 
void infantry_walk (edict_t *self)
 
void infantry_run (edict_t *self)
 
void infantry_pain (edict_t *self, edict_t *other, float kick, int damage)
 
void infantry_sight (edict_t *self, edict_t *other)
 
void infantry_dead (edict_t *self)
 
void infantry_die (edict_t *self, edict_t *inflictor, edict_t *attacker, int damage, vec3_t point)
 
void infantry_duck_down (edict_t *self)
 
void infantry_duck_hold (edict_t *self)
 
void infantry_duck_up (edict_t *self)
 
void infantry_dodge (edict_t *self, edict_t *attacker, float eta)
 
void infantry_cock_gun (edict_t *self)
 
void infantry_fire (edict_t *self)
 
void infantry_swing (edict_t *self)
 
void infantry_smack (edict_t *self)
 
void infantry_attack (edict_t *self)
 
void SP_monster_infantry (edict_t *self)
 

Variables

static int sound_pain1
 
static int sound_pain2
 
static int sound_die1
 
static int sound_die2
 
static int sound_gunshot
 
static int sound_weapon_cock
 
static int sound_punch_swing
 
static int sound_punch_hit
 
static int sound_sight
 
static int sound_search
 
static int sound_idle
 
mframe_t infantry_frames_stand []
 
mmove_t infantry_move_stand = {FRAME_stand50, FRAME_stand71, infantry_frames_stand, NULL}
 
mframe_t infantry_frames_fidget []
 
mmove_t infantry_move_fidget = {FRAME_stand01, FRAME_stand49, infantry_frames_fidget, infantry_stand}
 
mframe_t infantry_frames_walk []
 
mmove_t infantry_move_walk = {FRAME_walk03, FRAME_walk14, infantry_frames_walk, NULL}
 
mframe_t infantry_frames_run []
 
mmove_t infantry_move_run = {FRAME_run01, FRAME_run08, infantry_frames_run, NULL}
 
mframe_t infantry_frames_pain1 []
 
mmove_t infantry_move_pain1 = {FRAME_pain101, FRAME_pain110, infantry_frames_pain1, infantry_run}
 
mframe_t infantry_frames_pain2 []
 
mmove_t infantry_move_pain2 = {FRAME_pain201, FRAME_pain210, infantry_frames_pain2, infantry_run}
 
vec3_t aimangles []
 
mframe_t infantry_frames_death1 []
 
mmove_t infantry_move_death1 = {FRAME_death101, FRAME_death120, infantry_frames_death1, infantry_dead}
 
mframe_t infantry_frames_death2 []
 
mmove_t infantry_move_death2 = {FRAME_death201, FRAME_death225, infantry_frames_death2, infantry_dead}
 
mframe_t infantry_frames_death3 []
 
mmove_t infantry_move_death3 = {FRAME_death301, FRAME_death309, infantry_frames_death3, infantry_dead}
 
mframe_t infantry_frames_duck []
 
mmove_t infantry_move_duck = {FRAME_duck01, FRAME_duck05, infantry_frames_duck, infantry_run}
 
mframe_t infantry_frames_attack1 []
 
mmove_t infantry_move_attack1 = {FRAME_attak101, FRAME_attak115, infantry_frames_attack1, infantry_run}
 
mframe_t infantry_frames_attack2 []
 
mmove_t infantry_move_attack2 = {FRAME_attak201, FRAME_attak208, infantry_frames_attack2, infantry_run}
 

Function Documentation

◆ infantry_attack()

void infantry_attack ( edict_t self)

Definition at line 545 of file m_infantry.c.

546 {
547  if (range (self, self->enemy) == RANGE_MELEE)
548  self->monsterinfo.currentmove = &infantry_move_attack2;
549  else
550  self->monsterinfo.currentmove = &infantry_move_attack1;
551 }

Referenced by SP_monster_infantry().

◆ infantry_cock_gun()

void infantry_cock_gun ( edict_t self)

Definition at line 478 of file m_infantry.c.

479 {
480  int n;
481 
483  n = (rand() & 15) + 3 + 7;
484  self->monsterinfo.pausetime = level.time + n * FRAMETIME;
485 }

◆ infantry_dead()

void infantry_dead ( edict_t self)

Definition at line 304 of file m_infantry.c.

305 {
306  VectorSet (self->mins, -16, -16, -24);
307  VectorSet (self->maxs, 16, 16, -8);
308  self->movetype = MOVETYPE_TOSS;
309  self->svflags |= SVF_DEADMONSTER;
310  gi.linkentity (self);
311 
312  M_FlyCheck (self);
313 }

◆ infantry_die()

void infantry_die ( edict_t self,
edict_t inflictor,
edict_t attacker,
int  damage,
vec3_t  point 
)

Definition at line 386 of file m_infantry.c.

387 {
388  int n;
389 
390 // check for gib
391  if (self->health <= self->gib_health)
392  {
393  gi.sound (self, CHAN_VOICE, gi.soundindex ("misc/udeath.wav"), 1, ATTN_NORM, 0);
394  for (n= 0; n < 2; n++)
395  ThrowGib (self, "models/objects/gibs/bone/tris.md2", damage, GIB_ORGANIC);
396  for (n= 0; n < 4; n++)
397  ThrowGib (self, "models/objects/gibs/sm_meat/tris.md2", damage, GIB_ORGANIC);
398  ThrowHead (self, "models/objects/gibs/head2/tris.md2", damage, GIB_ORGANIC);
399  self->deadflag = DEAD_DEAD;
400  return;
401  }
402 
403  if (self->deadflag == DEAD_DEAD)
404  return;
405 
406 // regular death
407  self->deadflag = DEAD_DEAD;
408  self->takedamage = DAMAGE_YES;
409 
410  n = rand() % 3;
411  if (n == 0)
412  {
413  self->monsterinfo.currentmove = &infantry_move_death1;
414  gi.sound (self, CHAN_VOICE, sound_die2, 1, ATTN_NORM, 0);
415  }
416  else if (n == 1)
417  {
418  self->monsterinfo.currentmove = &infantry_move_death2;
419  gi.sound (self, CHAN_VOICE, sound_die1, 1, ATTN_NORM, 0);
420  }
421  else
422  {
423  self->monsterinfo.currentmove = &infantry_move_death3;
424  gi.sound (self, CHAN_VOICE, sound_die2, 1, ATTN_NORM, 0);
425  }
426 }

Referenced by SP_monster_infantry().

◆ infantry_dodge()

void infantry_dodge ( edict_t self,
edict_t attacker,
float  eta 
)

Definition at line 466 of file m_infantry.c.

467 {
468  if (random() > 0.25)
469  return;
470 
471  if (!self->enemy)
472  self->enemy = attacker;
473 
475 }

Referenced by SP_monster_infantry().

◆ infantry_duck_down()

void infantry_duck_down ( edict_t self)

Definition at line 429 of file m_infantry.c.

430 {
431  if (self->monsterinfo.aiflags & AI_DUCKED)
432  return;
433  self->monsterinfo.aiflags |= AI_DUCKED;
434  self->maxs[2] -= 32;
435  self->takedamage = DAMAGE_YES;
436  self->monsterinfo.pausetime = level.time + 1;
437  gi.linkentity (self);
438 }

◆ infantry_duck_hold()

void infantry_duck_hold ( edict_t self)

Definition at line 440 of file m_infantry.c.

441 {
442  if (level.time >= self->monsterinfo.pausetime)
443  self->monsterinfo.aiflags &= ~AI_HOLD_FRAME;
444  else
445  self->monsterinfo.aiflags |= AI_HOLD_FRAME;
446 }

◆ infantry_duck_up()

void infantry_duck_up ( edict_t self)

Definition at line 448 of file m_infantry.c.

449 {
450  self->monsterinfo.aiflags &= ~AI_DUCKED;
451  self->maxs[2] += 32;
452  self->takedamage = DAMAGE_AIM;
453  gi.linkentity (self);
454 }

◆ infantry_fidget()

void infantry_fidget ( edict_t self)

Definition at line 135 of file m_infantry.c.

136 {
137  self->monsterinfo.currentmove = &infantry_move_fidget;
138  gi.sound (self, CHAN_VOICE, sound_idle, 1, ATTN_IDLE, 0);
139 }

Referenced by SP_monster_infantry().

◆ infantry_fire()

void infantry_fire ( edict_t self)

Definition at line 487 of file m_infantry.c.

488 {
489  InfantryMachineGun (self);
490 
491  if (level.time >= self->monsterinfo.pausetime)
492  self->monsterinfo.aiflags &= ~AI_HOLD_FRAME;
493  else
494  self->monsterinfo.aiflags |= AI_HOLD_FRAME;
495 }

◆ infantry_pain()

void infantry_pain ( edict_t self,
edict_t other,
float  kick,
int  damage 
)

Definition at line 215 of file m_infantry.c.

216 {
217  int n;
218 
219  if (self->health < (self->max_health / 2))
220  self->s.skinnum = 1;
221 
222  if (level.time < self->pain_debounce_time)
223  return;
224 
225  self->pain_debounce_time = level.time + 3;
226 
227  if (skill->value == 3)
228  return; // no pain anims in nightmare
229 
230  n = rand() % 2;
231  if (n == 0)
232  {
233  self->monsterinfo.currentmove = &infantry_move_pain1;
234  gi.sound (self, CHAN_VOICE, sound_pain1, 1, ATTN_NORM, 0);
235  }
236  else
237  {
238  self->monsterinfo.currentmove = &infantry_move_pain2;
239  gi.sound (self, CHAN_VOICE, sound_pain2, 1, ATTN_NORM, 0);
240  }
241 }

Referenced by SP_monster_infantry().

◆ infantry_run()

void infantry_run ( edict_t self)

Definition at line 176 of file m_infantry.c.

177 {
178  if (self->monsterinfo.aiflags & AI_STAND_GROUND)
179  self->monsterinfo.currentmove = &infantry_move_stand;
180  else
181  self->monsterinfo.currentmove = &infantry_move_run;
182 }

Referenced by SP_monster_infantry().

◆ infantry_sight()

void infantry_sight ( edict_t self,
edict_t other 
)

Definition at line 299 of file m_infantry.c.

300 {
301  gi.sound (self, CHAN_BODY, sound_sight, 1, ATTN_NORM, 0);
302 }

Referenced by SP_monster_infantry().

◆ infantry_smack()

void infantry_smack ( edict_t self)

Definition at line 523 of file m_infantry.c.

524 {
525  vec3_t aim;
526 
527  VectorSet (aim, MELEE_DISTANCE, 0, 0);
528  if (fire_hit (self, aim, (5 + (rand() % 5)), 50))
529  gi.sound (self, CHAN_WEAPON, sound_punch_hit, 1, ATTN_NORM, 0);
530 }

◆ infantry_stand()

void infantry_stand ( edict_t self)

Definition at line 75 of file m_infantry.c.

76 {
77  self->monsterinfo.currentmove = &infantry_move_stand;
78 }

Referenced by SP_monster_infantry(), and SP_turret_driver().

◆ infantry_swing()

void infantry_swing ( edict_t self)

Definition at line 518 of file m_infantry.c.

519 {
521 }

◆ infantry_walk()

void infantry_walk ( edict_t self)

Definition at line 158 of file m_infantry.c.

159 {
160  self->monsterinfo.currentmove = &infantry_move_walk;
161 }

Referenced by SP_monster_infantry().

◆ InfantryMachineGun()

void InfantryMachineGun ( edict_t self)

Definition at line 260 of file m_infantry.c.

261 {
262  vec3_t start, target;
264  vec3_t vec;
265  int flash_number;
266 
267  if (self->s.frame == FRAME_attak111)
268  {
269  flash_number = MZ2_INFANTRY_MACHINEGUN_1;
270  AngleVectors (self->s.angles, forward, right, NULL);
271  G_ProjectSource (self->s.origin, monster_flash_offset[flash_number], forward, right, start);
272 
273  if (self->enemy)
274  {
275  VectorMA (self->enemy->s.origin, -0.2, self->enemy->velocity, target);
276  target[2] += self->enemy->viewheight;
277  VectorSubtract (target, start, forward);
279  }
280  else
281  {
282  AngleVectors (self->s.angles, forward, right, NULL);
283  }
284  }
285  else
286  {
287  flash_number = MZ2_INFANTRY_MACHINEGUN_2 + (self->s.frame - FRAME_death211);
288 
289  AngleVectors (self->s.angles, forward, right, NULL);
290  G_ProjectSource (self->s.origin, monster_flash_offset[flash_number], forward, right, start);
291 
292  VectorSubtract (self->s.angles, aimangles[flash_number-MZ2_INFANTRY_MACHINEGUN_2], vec);
293  AngleVectors (vec, forward, NULL, NULL);
294  }
295 
296  monster_fire_bullet (self, start, forward, 3, 4, DEFAULT_BULLET_HSPREAD, DEFAULT_BULLET_VSPREAD, flash_number);
297 }

Referenced by infantry_fire().

◆ SP_monster_infantry()

void SP_monster_infantry ( edict_t self)

Definition at line 556 of file m_infantry.c.

557 {
558  if (deathmatch->value)
559  {
560  G_FreeEdict (self);
561  return;
562  }
563 
564  sound_pain1 = gi.soundindex ("infantry/infpain1.wav");
565  sound_pain2 = gi.soundindex ("infantry/infpain2.wav");
566  sound_die1 = gi.soundindex ("infantry/infdeth1.wav");
567  sound_die2 = gi.soundindex ("infantry/infdeth2.wav");
568 
569  sound_gunshot = gi.soundindex ("infantry/infatck1.wav");
570  sound_weapon_cock = gi.soundindex ("infantry/infatck3.wav");
571  sound_punch_swing = gi.soundindex ("infantry/infatck2.wav");
572  sound_punch_hit = gi.soundindex ("infantry/melee2.wav");
573 
574  sound_sight = gi.soundindex ("infantry/infsght1.wav");
575  sound_search = gi.soundindex ("infantry/infsrch1.wav");
576  sound_idle = gi.soundindex ("infantry/infidle1.wav");
577 
578 
579  self->movetype = MOVETYPE_STEP;
580  self->solid = SOLID_BBOX;
581  self->s.modelindex = gi.modelindex("models/monsters/infantry/tris.md2");
582  VectorSet (self->mins, -16, -16, -24);
583  VectorSet (self->maxs, 16, 16, 32);
584 
585  self->health = 100;
586  self->gib_health = -40;
587  self->mass = 200;
588 
589  self->pain = infantry_pain;
590  self->die = infantry_die;
591 
592  self->monsterinfo.stand = infantry_stand;
593  self->monsterinfo.walk = infantry_walk;
594  self->monsterinfo.run = infantry_run;
595  self->monsterinfo.dodge = infantry_dodge;
596  self->monsterinfo.attack = infantry_attack;
597  self->monsterinfo.melee = NULL;
598  self->monsterinfo.sight = infantry_sight;
599  self->monsterinfo.idle = infantry_fidget;
600 
601  gi.linkentity (self);
602 
603  self->monsterinfo.currentmove = &infantry_move_stand;
604  self->monsterinfo.scale = MODEL_SCALE;
605 
606  walkmonster_start (self);
607 }

Variable Documentation

◆ aimangles

vec3_t aimangles[]
Initial value:
=
{
0.0, 5.0, 0.0,
10.0, 15.0, 0.0,
20.0, 25.0, 0.0,
25.0, 35.0, 0.0,
30.0, 40.0, 0.0,
30.0, 45.0, 0.0,
25.0, 50.0, 0.0,
20.0, 40.0, 0.0,
15.0, 35.0, 0.0,
40.0, 35.0, 0.0,
70.0, 35.0, 0.0,
90.0, 35.0, 0.0
}

Definition at line 244 of file m_infantry.c.

Referenced by InfantryMachineGun().

◆ infantry_frames_attack1

mframe_t infantry_frames_attack1[]
Initial value:

Definition at line 497 of file m_infantry.c.

◆ infantry_frames_attack2

mframe_t infantry_frames_attack2[]
Initial value:

Definition at line 532 of file m_infantry.c.

◆ infantry_frames_death1

mframe_t infantry_frames_death1[]
Initial value:
=
{
ai_move, -4, NULL,
ai_move, -1, NULL,
ai_move, -4, NULL,
ai_move, -1, NULL,
ai_move, -2, NULL,
ai_move, -3, NULL,
}

Definition at line 315 of file m_infantry.c.

◆ infantry_frames_death2

◆ infantry_frames_death3

mframe_t infantry_frames_death3[]
Initial value:
=
{
ai_move, -6, NULL,
ai_move, -11, NULL,
ai_move, -3, NULL,
ai_move, -11, NULL,
}

Definition at line 371 of file m_infantry.c.

◆ infantry_frames_duck

mframe_t infantry_frames_duck[]
Initial value:

Definition at line 456 of file m_infantry.c.

◆ infantry_frames_fidget

mframe_t infantry_frames_fidget[]

Definition at line 81 of file m_infantry.c.

◆ infantry_frames_pain1

mframe_t infantry_frames_pain1[]
Initial value:
=
{
ai_move, -3, NULL,
ai_move, -2, NULL,
ai_move, -1, NULL,
ai_move, -2, NULL,
ai_move, -1, NULL,
ai_move, -1, NULL,
}

Definition at line 185 of file m_infantry.c.

◆ infantry_frames_pain2

mframe_t infantry_frames_pain2[]
Initial value:
=
{
ai_move, -3, NULL,
ai_move, -3, NULL,
ai_move, -1, NULL,
ai_move, -2, NULL,
}

Definition at line 200 of file m_infantry.c.

◆ infantry_frames_run

mframe_t infantry_frames_run[]
Initial value:
=
{
ai_run, 10, NULL,
ai_run, 20, NULL,
ai_run, 5, NULL,
ai_run, 7, NULL,
ai_run, 30, NULL,
ai_run, 35, NULL,
ai_run, 2, NULL,
}

Definition at line 163 of file m_infantry.c.

◆ infantry_frames_stand

mframe_t infantry_frames_stand[]
Initial value:

Definition at line 48 of file m_infantry.c.

◆ infantry_frames_walk

mframe_t infantry_frames_walk[]
Initial value:
=
{
}

Definition at line 141 of file m_infantry.c.

◆ infantry_move_attack1

Definition at line 515 of file m_infantry.c.

Referenced by infantry_attack().

◆ infantry_move_attack2

Definition at line 543 of file m_infantry.c.

Referenced by infantry_attack().

◆ infantry_move_death1

Definition at line 338 of file m_infantry.c.

Referenced by infantry_die().

◆ infantry_move_death2

Definition at line 369 of file m_infantry.c.

Referenced by infantry_die().

◆ infantry_move_death3

Definition at line 383 of file m_infantry.c.

Referenced by infantry_die().

◆ infantry_move_duck

Definition at line 464 of file m_infantry.c.

Referenced by infantry_dodge().

◆ infantry_move_fidget

Definition at line 133 of file m_infantry.c.

Referenced by infantry_fidget().

◆ infantry_move_pain1

Definition at line 198 of file m_infantry.c.

Referenced by infantry_pain().

◆ infantry_move_pain2

Definition at line 213 of file m_infantry.c.

Referenced by infantry_pain().

◆ infantry_move_run

Definition at line 174 of file m_infantry.c.

Referenced by infantry_run().

◆ infantry_move_stand

Definition at line 73 of file m_infantry.c.

Referenced by infantry_run(), infantry_stand(), and SP_monster_infantry().

◆ infantry_move_walk

Definition at line 156 of file m_infantry.c.

Referenced by infantry_walk().

◆ sound_die1

int sound_die1
static

Definition at line 36 of file m_infantry.c.

Referenced by infantry_die(), and SP_monster_infantry().

◆ sound_die2

int sound_die2
static

Definition at line 37 of file m_infantry.c.

Referenced by infantry_die(), and SP_monster_infantry().

◆ sound_gunshot

int sound_gunshot
static

Definition at line 39 of file m_infantry.c.

Referenced by SP_monster_infantry().

◆ sound_idle

int sound_idle
static

Definition at line 45 of file m_infantry.c.

Referenced by infantry_fidget(), and SP_monster_infantry().

◆ sound_pain1

int sound_pain1
static

Definition at line 34 of file m_infantry.c.

Referenced by infantry_pain(), and SP_monster_infantry().

◆ sound_pain2

int sound_pain2
static

Definition at line 35 of file m_infantry.c.

Referenced by infantry_pain(), and SP_monster_infantry().

◆ sound_punch_hit

int sound_punch_hit
static

Definition at line 42 of file m_infantry.c.

Referenced by infantry_smack(), and SP_monster_infantry().

◆ sound_punch_swing

int sound_punch_swing
static

Definition at line 41 of file m_infantry.c.

Referenced by infantry_swing(), and SP_monster_infantry().

◆ sound_search

int sound_search
static

Definition at line 44 of file m_infantry.c.

Referenced by SP_monster_infantry().

◆ sound_sight

int sound_sight
static

Definition at line 43 of file m_infantry.c.

Referenced by infantry_sight(), and SP_monster_infantry().

◆ sound_weapon_cock

int sound_weapon_cock
static

Definition at line 40 of file m_infantry.c.

Referenced by infantry_cock_gun(), and SP_monster_infantry().

gi
game_import_t gi
Definition: g_main.c:25
FRAME_death211
#define FRAME_death211
Definition: m_actor.h:45
G_ProjectSource
void G_ProjectSource(vec3_t point, vec3_t distance, vec3_t forward, vec3_t right, vec3_t result)
Definition: g_utils.c:25
edict_s::s
entity_state_t s
Definition: g_local.h:970
deathmatch
cvar_t * deathmatch
Definition: g_main.c:35
sound_gunshot
static int sound_gunshot
Definition: m_infantry.c:39
DEAD_DEAD
#define DEAD_DEAD
Definition: g_local.h:115
DEFAULT_BULLET_HSPREAD
#define DEFAULT_BULLET_HSPREAD
Definition: g_local.h:670
ThrowGib
void ThrowGib(edict_t *self, char *gibname, int damage, int type)
Definition: g_misc.c:135
edict_s::gib_health
int gib_health
Definition: g_local.h:1059
MELEE_DISTANCE
#define MELEE_DISTANCE
Definition: g_local.h:82
VectorSubtract
#define VectorSubtract(a, b, c)
Definition: q_shared.h:163
entity_state_s::frame
int frame
Definition: q_shared.h:1154
ai_charge
void ai_charge(edict_t *self, float dist)
Definition: g_ai.c:194
infantry_die
void infantry_die(edict_t *self, edict_t *inflictor, edict_t *attacker, int damage, vec3_t point)
Definition: m_infantry.c:386
SOLID_BBOX
@ SOLID_BBOX
Definition: game.h:37
sound_pain1
static int sound_pain1
Definition: m_infantry.c:34
FRAMETIME
#define FRAMETIME
Definition: g_local.h:75
infantry_move_stand
mmove_t infantry_move_stand
Definition: m_infantry.c:73
entity_state_s::origin
vec3_t origin
Definition: q_shared.h:1149
infantry_move_pain1
mmove_t infantry_move_pain1
Definition: m_infantry.c:198
infantry_cock_gun
void infantry_cock_gun(edict_t *self)
Definition: m_infantry.c:478
AI_STAND_GROUND
#define AI_STAND_GROUND
Definition: g_local.h:129
sound_die2
static int sound_die2
Definition: m_infantry.c:37
infantry_duck_up
void infantry_duck_up(edict_t *self)
Definition: m_infantry.c:448
infantry_move_death1
mmove_t infantry_move_death1
Definition: m_infantry.c:338
InfantryMachineGun
void InfantryMachineGun(edict_t *self)
Definition: m_infantry.c:260
MODEL_SCALE
#define MODEL_SCALE
Definition: m_actor.h:506
edict_s::max_health
int max_health
Definition: g_local.h:1058
sound_punch_swing
static int sound_punch_swing
Definition: m_infantry.c:41
sound_pain2
static int sound_pain2
Definition: m_infantry.c:35
DAMAGE_YES
@ DAMAGE_YES
Definition: g_local.h:89
game_import_t::sound
void(* sound)(edict_t *ent, int channel, int soundindex, float volume, float attenuation, float timeofs)
Definition: game.h:109
ATTN_IDLE
#define ATTN_IDLE
Definition: q_shared.h:996
infantry_duck_hold
void infantry_duck_hold(edict_t *self)
Definition: m_infantry.c:440
infantry_fire
void infantry_fire(edict_t *self)
Definition: m_infantry.c:487
infantry_swing
void infantry_swing(edict_t *self)
Definition: m_infantry.c:518
edict_s::mins
vec3_t mins
Definition: g_local.h:990
infantry_walk
void infantry_walk(edict_t *self)
Definition: m_infantry.c:158
range
GLsizei range
Definition: qgl_win.c:121
monsterinfo_t::currentmove
mmove_t * currentmove
Definition: g_local.h:420
fire_hit
qboolean fire_hit(edict_t *self, vec3_t aim, int damage, int kick)
Definition: g_weapon.c:63
ATTN_NORM
#define ATTN_NORM
Definition: q_shared.h:995
sound_weapon_cock
static int sound_weapon_cock
Definition: m_infantry.c:40
walkmonster_start
void walkmonster_start(edict_t *self)
Definition: g_monster.c:692
MOVETYPE_STEP
@ MOVETYPE_STEP
Definition: g_local.h:196
FRAME_attak111
#define FRAME_attak111
Definition: m_boss31.h:34
MZ2_INFANTRY_MACHINEGUN_2
#define MZ2_INFANTRY_MACHINEGUN_2
Definition: q_shared.h:697
SVF_DEADMONSTER
#define SVF_DEADMONSTER
Definition: game.h:28
AngleVectors
void AngleVectors(vec3_t angles, vec3_t forward, vec3_t right, vec3_t up)
Definition: q_shared.c:93
sound_idle
static int sound_idle
Definition: m_infantry.c:45
monster_flash_offset
vec3_t monster_flash_offset[]
Definition: m_flash.c:27
CHAN_VOICE
#define CHAN_VOICE
Definition: q_shared.h:985
DEFAULT_BULLET_VSPREAD
#define DEFAULT_BULLET_VSPREAD
Definition: g_local.h:671
G_FreeEdict
void G_FreeEdict(edict_t *e)
Definition: g_utils.c:452
monsterinfo_t::pausetime
float pausetime
Definition: g_local.h:436
infantry_dodge
void infantry_dodge(edict_t *self, edict_t *attacker, float eta)
Definition: m_infantry.c:466
infantry_attack
void infantry_attack(edict_t *self)
Definition: m_infantry.c:545
game_import_t::soundindex
int(* soundindex)(char *name)
Definition: game.h:122
forward
static vec3_t forward
Definition: p_view.c:29
AI_HOLD_FRAME
#define AI_HOLD_FRAME
Definition: g_local.h:136
game_import_t::modelindex
int(* modelindex)(char *name)
Definition: game.h:121
infantry_move_walk
mmove_t infantry_move_walk
Definition: m_infantry.c:156
edict_s::deadflag
int deadflag
Definition: g_local.h:1060
infantry_smack
void infantry_smack(edict_t *self)
Definition: m_infantry.c:523
infantry_move_attack1
mmove_t infantry_move_attack1
Definition: m_infantry.c:515
infantry_move_pain2
mmove_t infantry_move_pain2
Definition: m_infantry.c:213
cvar_s::value
float value
Definition: q_shared.h:331
aimangles
vec3_t aimangles[]
Definition: m_infantry.c:244
ai_walk
void ai_walk(edict_t *self, float dist)
Definition: g_ai.c:163
random
#define random()
Definition: g_local.h:515
VectorNormalize
vec_t VectorNormalize(vec3_t v)
Definition: q_shared.c:681
NULL
#define NULL
Definition: q_shared.h:67
infantry_duck_down
void infantry_duck_down(edict_t *self)
Definition: m_infantry.c:429
sound_search
static int sound_search
Definition: m_infantry.c:44
monsterinfo_t::aiflags
int aiflags
Definition: g_local.h:421
monster_fire_bullet
void monster_fire_bullet(edict_t *self, vec3_t start, vec3_t dir, int damage, int kick, int hspread, int vspread, int flashtype)
Definition: g_monster.c:31
infantry_pain
void infantry_pain(edict_t *self, edict_t *other, float kick, int damage)
Definition: m_infantry.c:215
skill
cvar_t * skill
Definition: g_main.c:38
edict_s::velocity
vec3_t velocity
Definition: g_local.h:1030
ai_move
void ai_move(edict_t *self, float dist)
Definition: g_ai.c:92
edict_s::pain_debounce_time
float pain_debounce_time
Definition: g_local.h:1052
edict_s::monsterinfo
monsterinfo_t monsterinfo
Definition: g_local.h:1114
RANGE_MELEE
#define RANGE_MELEE
Definition: g_local.h:119
infantry_move_fidget
mmove_t infantry_move_fidget
Definition: m_infantry.c:133
DAMAGE_AIM
@ DAMAGE_AIM
Definition: g_local.h:90
CHAN_WEAPON
#define CHAN_WEAPON
Definition: q_shared.h:984
sound_die1
static int sound_die1
Definition: m_infantry.c:36
level
GLint level
Definition: qgl_win.c:116
ai_run
void ai_run(edict_t *self, float dist)
Definition: g_ai.c:914
MZ2_INFANTRY_MACHINEGUN_1
#define MZ2_INFANTRY_MACHINEGUN_1
Definition: q_shared.h:696
GIB_ORGANIC
#define GIB_ORGANIC
Definition: g_local.h:125
VectorMA
void VectorMA(vec3_t veca, float scale, vec3_t vecb, vec3_t vecc)
Definition: q_shared.c:719
M_FlyCheck
void M_FlyCheck(edict_t *self)
Definition: g_monster.c:123
edict_s::maxs
vec3_t maxs
Definition: g_local.h:990
ThrowHead
void ThrowHead(edict_t *self, char *gibname, int damage, int type)
Definition: g_misc.c:183
infantry_stand
void infantry_stand(edict_t *self)
Definition: m_infantry.c:75
infantry_run
void infantry_run(edict_t *self)
Definition: m_infantry.c:176
infantry_move_death2
mmove_t infantry_move_death2
Definition: m_infantry.c:369
MOVETYPE_TOSS
@ MOVETYPE_TOSS
Definition: g_local.h:198
VectorSet
#define VectorSet(v, x, y, z)
Definition: q_shared.h:168
right
GLdouble right
Definition: qgl_win.c:159
infantry_sight
void infantry_sight(edict_t *self, edict_t *other)
Definition: m_infantry.c:299
CHAN_BODY
#define CHAN_BODY
Definition: q_shared.h:987
infantry_move_death3
mmove_t infantry_move_death3
Definition: m_infantry.c:383
infantry_move_duck
mmove_t infantry_move_duck
Definition: m_infantry.c:464
infantry_move_run
mmove_t infantry_move_run
Definition: m_infantry.c:174
infantry_move_attack2
mmove_t infantry_move_attack2
Definition: m_infantry.c:543
edict_s::enemy
edict_t * enemy
Definition: g_local.h:1076
AI_DUCKED
#define AI_DUCKED
Definition: g_local.h:140
game_import_t::linkentity
void(* linkentity)(edict_t *ent)
Definition: game.h:138
sound_sight
static int sound_sight
Definition: m_infantry.c:43
entity_state_s::angles
vec3_t angles
Definition: q_shared.h:1150
vec3_t
vec_t vec3_t[3]
Definition: q_shared.h:134
ai_stand
void ai_stand(edict_t *self, float dist)
Definition: g_ai.c:106
sound_punch_hit
static int sound_punch_hit
Definition: m_infantry.c:42
infantry_fidget
void infantry_fidget(edict_t *self)
Definition: m_infantry.c:135
edict_s::health
int health
Definition: g_local.h:1057