mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-30 00:10:53 +00:00
Fix soldiers never showing their pain skins as long as they're alive.
Since `self->helth` is set after calling `master_start()` `self->max_health is always 0. Found by @drakonorodny and analyzed by @BjossiAlfreds. Closes #761.
This commit is contained in:
parent
4456eccc8f
commit
e42d2736fa
1 changed files with 6 additions and 6 deletions
|
@ -1596,8 +1596,6 @@ SP_monster_soldier_light(edict_t *self)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
SP_monster_soldier_x(self);
|
|
||||||
|
|
||||||
sound_pain_light = gi.soundindex("soldier/solpain2.wav");
|
sound_pain_light = gi.soundindex("soldier/solpain2.wav");
|
||||||
sound_death_light = gi.soundindex("soldier/soldeth2.wav");
|
sound_death_light = gi.soundindex("soldier/soldeth2.wav");
|
||||||
gi.modelindex("models/objects/laser/tris.md2");
|
gi.modelindex("models/objects/laser/tris.md2");
|
||||||
|
@ -1607,6 +1605,8 @@ SP_monster_soldier_light(edict_t *self)
|
||||||
self->s.skinnum = 0;
|
self->s.skinnum = 0;
|
||||||
self->health = 20;
|
self->health = 20;
|
||||||
self->gib_health = -30;
|
self->gib_health = -30;
|
||||||
|
|
||||||
|
SP_monster_soldier_x(self);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1626,8 +1626,6 @@ SP_monster_soldier(edict_t *self)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
SP_monster_soldier_x(self);
|
|
||||||
|
|
||||||
sound_pain = gi.soundindex("soldier/solpain1.wav");
|
sound_pain = gi.soundindex("soldier/solpain1.wav");
|
||||||
sound_death = gi.soundindex("soldier/soldeth1.wav");
|
sound_death = gi.soundindex("soldier/soldeth1.wav");
|
||||||
gi.soundindex("soldier/solatck1.wav");
|
gi.soundindex("soldier/solatck1.wav");
|
||||||
|
@ -1635,6 +1633,8 @@ SP_monster_soldier(edict_t *self)
|
||||||
self->s.skinnum = 2;
|
self->s.skinnum = 2;
|
||||||
self->health = 30;
|
self->health = 30;
|
||||||
self->gib_health = -30;
|
self->gib_health = -30;
|
||||||
|
|
||||||
|
SP_monster_soldier_x(self);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1654,8 +1654,6 @@ SP_monster_soldier_ss(edict_t *self)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
SP_monster_soldier_x(self);
|
|
||||||
|
|
||||||
sound_pain_ss = gi.soundindex("soldier/solpain3.wav");
|
sound_pain_ss = gi.soundindex("soldier/solpain3.wav");
|
||||||
sound_death_ss = gi.soundindex("soldier/soldeth3.wav");
|
sound_death_ss = gi.soundindex("soldier/soldeth3.wav");
|
||||||
gi.soundindex("soldier/solatck3.wav");
|
gi.soundindex("soldier/solatck3.wav");
|
||||||
|
@ -1663,4 +1661,6 @@ SP_monster_soldier_ss(edict_t *self)
|
||||||
self->s.skinnum = 4;
|
self->s.skinnum = 4;
|
||||||
self->health = 40;
|
self->health = 40;
|
||||||
self->gib_health = -30;
|
self->gib_health = -30;
|
||||||
|
|
||||||
|
SP_monster_soldier_x(self);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue