Quake II RTX doxygen
1.0 dev
|
|
#include "g_local.h"
#include "m_tank.h"
Go to the source code of this file.
|
static int | sound_thud |
|
static int | sound_pain |
|
static int | sound_idle |
|
static int | sound_die |
|
static int | sound_step |
|
static int | sound_sight |
|
static int | sound_windup |
|
static int | sound_strike |
|
mframe_t | tank_frames_stand [] |
|
mmove_t | tank_move_stand = {FRAME_stand01, FRAME_stand30, tank_frames_stand, NULL} |
|
mframe_t | tank_frames_start_walk [] |
|
mmove_t | tank_move_start_walk = {FRAME_walk01, FRAME_walk04, tank_frames_start_walk, tank_walk} |
|
mframe_t | tank_frames_walk [] |
|
mmove_t | tank_move_walk = {FRAME_walk05, FRAME_walk20, tank_frames_walk, NULL} |
|
mframe_t | tank_frames_stop_walk [] |
|
mmove_t | tank_move_stop_walk = {FRAME_walk21, FRAME_walk25, tank_frames_stop_walk, tank_stand} |
|
mframe_t | tank_frames_start_run [] |
|
mmove_t | tank_move_start_run = {FRAME_walk01, FRAME_walk04, tank_frames_start_run, tank_run} |
|
mframe_t | tank_frames_run [] |
|
mmove_t | tank_move_run = {FRAME_walk05, FRAME_walk20, tank_frames_run, NULL} |
|
mframe_t | tank_frames_stop_run [] |
|
mmove_t | tank_move_stop_run = {FRAME_walk21, FRAME_walk25, tank_frames_stop_run, tank_walk} |
|
mframe_t | tank_frames_pain1 [] |
|
mmove_t | tank_move_pain1 = {FRAME_pain101, FRAME_pain104, tank_frames_pain1, tank_run} |
|
mframe_t | tank_frames_pain2 [] |
|
mmove_t | tank_move_pain2 = {FRAME_pain201, FRAME_pain205, tank_frames_pain2, tank_run} |
|
mframe_t | tank_frames_pain3 [] |
|
mmove_t | tank_move_pain3 = {FRAME_pain301, FRAME_pain316, tank_frames_pain3, tank_run} |
|
mframe_t | tank_frames_attack_blast [] |
|
mmove_t | tank_move_attack_blast = {FRAME_attak101, FRAME_attak116, tank_frames_attack_blast, tank_reattack_blaster} |
|
mframe_t | tank_frames_reattack_blast [] |
|
mmove_t | tank_move_reattack_blast = {FRAME_attak111, FRAME_attak116, tank_frames_reattack_blast, tank_reattack_blaster} |
|
mframe_t | tank_frames_attack_post_blast [] |
|
mmove_t | tank_move_attack_post_blast = {FRAME_attak117, FRAME_attak122, tank_frames_attack_post_blast, tank_run} |
|
mframe_t | tank_frames_attack_strike [] |
|
mmove_t | tank_move_attack_strike = {FRAME_attak201, FRAME_attak238, tank_frames_attack_strike, tank_poststrike} |
|
mframe_t | tank_frames_attack_pre_rocket [] |
|
mmove_t | tank_move_attack_pre_rocket = {FRAME_attak301, FRAME_attak321, tank_frames_attack_pre_rocket, tank_doattack_rocket} |
|
mframe_t | tank_frames_attack_fire_rocket [] |
|
mmove_t | tank_move_attack_fire_rocket = {FRAME_attak322, FRAME_attak330, tank_frames_attack_fire_rocket, tank_refire_rocket} |
|
mframe_t | tank_frames_attack_post_rocket [] |
|
mmove_t | tank_move_attack_post_rocket = {FRAME_attak331, FRAME_attak353, tank_frames_attack_post_rocket, tank_run} |
|
mframe_t | tank_frames_attack_chain [] |
|
mmove_t | tank_move_attack_chain = {FRAME_attak401, FRAME_attak429, tank_frames_attack_chain, tank_run} |
|
mframe_t | tank_frames_death1 [] |
|
mmove_t | tank_move_death = {FRAME_death101, FRAME_death132, tank_frames_death1, tank_dead} |
|
◆ SP_monster_tank()
void SP_monster_tank |
( |
edict_t * |
self | ) |
|
Definition at line 752 of file m_tank.c.
759 self->s.modelindex =
gi.modelindex(
"models/monsters/tank/tris.md2");
760 VectorSet(self->mins, -32, -32, -16);
761 VectorSet(self->maxs, 32, 32, 72);
763 self->solid = SOLID_BBOX;
774 gi.soundindex(
"tank/tnkatck1.wav");
775 gi.soundindex(
"tank/tnkatk2a.wav");
776 gi.soundindex(
"tank/tnkatk2b.wav");
777 gi.soundindex(
"tank/tnkatk2c.wav");
778 gi.soundindex(
"tank/tnkatk2d.wav");
779 gi.soundindex(
"tank/tnkatk2e.wav");
780 gi.soundindex(
"tank/tnkatck3.wav");
782 if (strcmp(self->classname,
"monster_tank_commander") == 0) {
784 self->gib_health = -225;
787 self->gib_health = -200;
797 self->monsterinfo.dodge = NULL;
799 self->monsterinfo.melee = NULL;
810 if (strcmp(self->classname,
"monster_tank_commander") == 0)
◆ tank_attack()
void tank_attack |
( |
edict_t * |
self | ) |
|
Definition at line 625 of file m_tank.c.
631 if (self->enemy->health < 0) {
637 VectorSubtract(self->enemy->s.origin, self->s.origin, vec);
638 range = VectorLength(vec);
647 }
else if (
range <= 250) {
657 self->pain_debounce_time =
level.
time + 5.0;
Referenced by SP_monster_tank().
◆ tank_dead()
void tank_dead |
( |
edict_t * |
self | ) |
|
Definition at line 668 of file m_tank.c.
670 VectorSet(self->mins, -16, -16, -16);
671 VectorSet(self->maxs, 16, 16, -0);
673 self->svflags |= SVF_DEADMONSTER;
◆ tank_die()
void tank_die |
( |
edict_t * |
self, |
|
|
edict_t * |
inflictor, |
|
|
edict_t * |
attacker, |
|
|
int |
damage, |
|
|
vec3_t |
point |
|
) |
| |
Definition at line 714 of file m_tank.c.
719 if (self->health <= self->gib_health) {
720 gi.sound(
self, CHAN_VOICE,
gi.soundindex(
"misc/udeath.wav"), 1, ATTN_NORM, 0);
721 for (n = 0; n < 1 ; n++)
723 for (n = 0; n < 4; n++)
735 gi.sound(
self, CHAN_VOICE,
sound_die, 1, ATTN_NORM, 0);
Referenced by SP_monster_tank().
◆ tank_doattack_rocket()
void tank_doattack_rocket |
( |
edict_t * |
self | ) |
|
◆ tank_footstep()
void tank_footstep |
( |
edict_t * |
self | ) |
|
◆ tank_idle()
void tank_idle |
( |
edict_t * |
self | ) |
|
◆ tank_pain()
void tank_pain |
( |
edict_t * |
self, |
|
|
edict_t * |
other, |
|
|
float |
kick, |
|
|
int |
damage |
|
) |
| |
Definition at line 272 of file m_tank.c.
274 if (self->health < (self->max_health / 2))
275 self->s.skinnum |= 1;
280 if (
level.
time < self->pain_debounce_time)
288 if (
skill->value >= 2) {
295 self->pain_debounce_time =
level.
time + 3;
296 gi.sound(
self, CHAN_VOICE,
sound_pain, 1, ATTN_NORM, 0);
298 if (
skill->value == 3)
303 else if (damage <= 60)
Referenced by SP_monster_tank().
◆ tank_poststrike()
void tank_poststrike |
( |
edict_t * |
self | ) |
|
◆ tank_reattack_blaster()
void tank_reattack_blaster |
( |
edict_t * |
self | ) |
|
Definition at line 444 of file m_tank.c.
446 if (
skill->value >= 2)
447 if (
visible(
self, self->enemy))
448 if (self->enemy->health > 0)
◆ tank_refire_rocket()
void tank_refire_rocket |
( |
edict_t * |
self | ) |
|
Definition at line 607 of file m_tank.c.
610 if (
skill->value >= 2)
611 if (self->enemy->health > 0)
612 if (
visible(
self, self->enemy))
◆ tank_run()
void tank_run |
( |
edict_t * |
self | ) |
|
◆ tank_sight()
void tank_sight |
( |
edict_t * |
self, |
|
|
edict_t * |
other |
|
) |
| |
◆ tank_stand()
void tank_stand |
( |
edict_t * |
self | ) |
|
◆ tank_thud()
void tank_thud |
( |
edict_t * |
self | ) |
|
◆ tank_walk()
void tank_walk |
( |
edict_t * |
self | ) |
|
◆ tank_windup()
void tank_windup |
( |
edict_t * |
self | ) |
|
◆ TankBlaster()
void TankBlaster |
( |
edict_t * |
self | ) |
|
Definition at line 314 of file m_tank.c.
323 flash_number = MZ2_TANK_BLASTER_1;
325 flash_number = MZ2_TANK_BLASTER_2;
327 flash_number = MZ2_TANK_BLASTER_3;
332 VectorCopy(self->enemy->s.origin, end);
333 end[2] +=
self->enemy->viewheight;
334 VectorSubtract(end, start, dir);
◆ TankMachineGun()
void TankMachineGun |
( |
edict_t * |
self | ) |
|
Definition at line 370 of file m_tank.c.
378 flash_number = MZ2_TANK_MACHINEGUN_1 + (
self->s.frame -
FRAME_attak406);
384 VectorCopy(self->enemy->s.origin, vec);
385 vec[2] +=
self->enemy->viewheight;
386 VectorSubtract(vec, start, vec);
393 dir[1] =
self->s.angles[1] - 8 * (
self->s.frame -
FRAME_attak411);
395 dir[1] =
self->s.angles[1] + 8 * (
self->s.frame -
FRAME_attak419);
◆ TankRocket()
void TankRocket |
( |
edict_t * |
self | ) |
|
Definition at line 344 of file m_tank.c.
353 flash_number = MZ2_TANK_ROCKET_1;
355 flash_number = MZ2_TANK_ROCKET_2;
357 flash_number = MZ2_TANK_ROCKET_3;
362 VectorCopy(self->enemy->s.origin, vec);
363 vec[2] +=
self->enemy->viewheight;
364 VectorSubtract(vec, start, dir);
◆ TankStrike()
void TankStrike |
( |
edict_t * |
self | ) |
|
◆ sound_die
◆ sound_idle
◆ sound_pain
◆ sound_sight
◆ sound_step
◆ sound_strike
◆ sound_thud
◆ sound_windup
◆ tank_frames_attack_blast
Initial value:
Definition at line 404 of file m_tank.c.
◆ tank_frames_attack_chain
◆ tank_frames_attack_fire_rocket
mframe_t tank_frames_attack_fire_rocket[] |
Initial value:
Definition at line 532 of file m_tank.c.
◆ tank_frames_attack_post_blast
mframe_t tank_frames_attack_post_blast[] |
Initial value:
Definition at line 434 of file m_tank.c.
◆ tank_frames_attack_post_rocket
mframe_t tank_frames_attack_post_rocket[] |
Initial value:
Definition at line 545 of file m_tank.c.
◆ tank_frames_attack_pre_rocket
mframe_t tank_frames_attack_pre_rocket[] |
Initial value:
Definition at line 505 of file m_tank.c.
◆ tank_frames_attack_strike
◆ tank_frames_death1
◆ tank_frames_pain1
Initial value:
Definition at line 234 of file m_tank.c.
◆ tank_frames_pain2
Initial value:
Definition at line 242 of file m_tank.c.
◆ tank_frames_pain3
Initial value:
Definition at line 251 of file m_tank.c.
◆ tank_frames_reattack_blast
Initial value:
Definition at line 424 of file m_tank.c.
◆ tank_frames_run
Initial value:
Definition at line 181 of file m_tank.c.
◆ tank_frames_stand
◆ tank_frames_start_run
Initial value:
Definition at line 173 of file m_tank.c.
◆ tank_frames_start_walk
Initial value:
Definition at line 124 of file m_tank.c.
◆ tank_frames_stop_run
Initial value:
Definition at line 201 of file m_tank.c.
◆ tank_frames_stop_walk
Initial value:
Definition at line 152 of file m_tank.c.
◆ tank_frames_walk
Initial value:
Definition at line 132 of file m_tank.c.
◆ tank_move_attack_blast
◆ tank_move_attack_chain
◆ tank_move_attack_fire_rocket
◆ tank_move_attack_post_blast
◆ tank_move_attack_post_rocket
◆ tank_move_attack_pre_rocket
◆ tank_move_attack_strike
◆ tank_move_death
◆ tank_move_pain1
◆ tank_move_pain2
◆ tank_move_pain3
◆ tank_move_reattack_blast
◆ tank_move_run
◆ tank_move_stand
◆ tank_move_start_run
◆ tank_move_start_walk
◆ tank_move_stop_run
◆ tank_move_stop_walk
◆ tank_move_walk
void tank_die(edict_t *self, edict_t *inflictor, edict_t *attacker, int damage, vec3_t point)
void G_ProjectSource(const vec3_t point, const vec3_t distance, const vec3_t forward, const vec3_t right, vec3_t result)
mmove_t tank_move_reattack_blast
void tank_idle(edict_t *self)
#define DEFAULT_BULLET_HSPREAD
void ThrowGib(edict_t *self, char *gibname, int damage, int type)
void tank_stand(edict_t *self)
void ai_charge(edict_t *self, float dist)
void walkmonster_start(edict_t *self)
mmove_t tank_move_attack_blast
void vectoangles(vec3_t vec, vec3_t angles)
#define DEFAULT_BULLET_VSPREAD
void G_FreeEdict(edict_t *e)
void TankRocket(edict_t *self)
void tank_footstep(edict_t *self)
void ai_walk(edict_t *self, float dist)
void AngleVectors(vec3_t angles, vec3_t forward, vec3_t right, vec3_t up)
void tank_walk(edict_t *self)
void monster_fire_bullet(edict_t *self, vec3_t start, vec3_t dir, int damage, int kick, int hspread, int vspread, int flashtype)
void monster_fire_rocket(edict_t *self, vec3_t start, vec3_t dir, int damage, int speed, int flashtype)
mmove_t tank_move_attack_post_rocket
void tank_run(edict_t *self)
void ai_move(edict_t *self, float dist)
void monster_fire_blaster(edict_t *self, vec3_t start, vec3_t dir, int damage, int speed, int flashtype, int effect)
mmove_t tank_move_attack_pre_rocket
qboolean visible(edict_t *self, edict_t *other)
mmove_t tank_move_attack_chain
mmove_t tank_move_attack_strike
void ai_run(edict_t *self, float dist)
void tank_pain(edict_t *self, edict_t *other, float kick, int damage)
void tank_attack(edict_t *self)
const vec3_t monster_flash_offset[256]
void ThrowHead(edict_t *self, char *gibname, int damage, int type)
void tank_sight(edict_t *self, edict_t *other)
int range(edict_t *self, edict_t *other)
mmove_t tank_move_attack_post_blast
mmove_t tank_move_start_run
vec_t VectorNormalize(vec3_t v)
void TankBlaster(edict_t *self)
mmove_t tank_move_attack_fire_rocket