mirror of
https://github.com/yquake2/rogue.git
synced 2024-11-10 06:42:21 +00:00
Merge pull request #59 from BjossiAlfreds/timeout-fix
Fix for insane marines not firing deathtarget right away
This commit is contained in:
commit
f7b99b07c3
2 changed files with 5 additions and 5 deletions
|
@ -1222,10 +1222,10 @@ struct edict_s
|
|||
void (*die)(edict_t *self, edict_t *inflictor, edict_t *attacker,
|
||||
int damage, vec3_t point);
|
||||
|
||||
float touch_debounce_time; /* are all these legit? do we need more/less of them? */
|
||||
float touch_debounce_time;
|
||||
float pain_debounce_time;
|
||||
float damage_debounce_time;
|
||||
float fly_sound_debounce_time; /* move to clientinfo */
|
||||
float fly_sound_debounce_time; /* now also used by insane marines to store pain sound timeout */
|
||||
float last_move_time;
|
||||
|
||||
int health;
|
||||
|
|
|
@ -55,7 +55,7 @@ insane_moan(edict_t *self)
|
|||
}
|
||||
|
||||
/* suppress screaming so pain sounds can play */
|
||||
if (self->delay > level.time)
|
||||
if (self->fly_sound_debounce_time > level.time)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
@ -72,7 +72,7 @@ insane_scream(edict_t *self)
|
|||
}
|
||||
|
||||
/* suppress screaming so pain sounds can play */
|
||||
if (self->delay > level.time)
|
||||
if (self->fly_sound_debounce_time > level.time)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
@ -658,7 +658,7 @@ insane_pain(edict_t *self, edict_t *other /* unused */, float kick, int damage)
|
|||
gi.sound(self, CHAN_VOICE, gi.soundindex(va("player/male/pain%i_%i.wav", l, r)), 1, ATTN_IDLE, 0);
|
||||
|
||||
/* suppress screaming and moaning for 1 second so pain sound plays */
|
||||
self->delay = level.time + 1;
|
||||
self->fly_sound_debounce_time = level.time + 1;
|
||||
|
||||
if (skill->value == 3)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue