Fighter damage indication fix.
This commit is contained in:
parent
2e17d68b47
commit
bd1dac445a
|
@ -464,15 +464,16 @@ void damageFighter(Entity *e, int amount, long flags)
|
||||||
{
|
{
|
||||||
e->shield -= amount;
|
e->shield -= amount;
|
||||||
|
|
||||||
amount = 0;
|
if (e->shield <= 0)
|
||||||
|
|
||||||
if (e->shield < 0)
|
|
||||||
{
|
{
|
||||||
amount = -e->shield;
|
e->armourHit = 255;
|
||||||
|
e->health += e->shield;
|
||||||
|
e->shield = 0;
|
||||||
|
|
||||||
|
playBattleSound(SND_ARMOUR_HIT, e->x, e->y);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
if (amount > 0)
|
|
||||||
{
|
{
|
||||||
e->health -= amount;
|
e->health -= amount;
|
||||||
e->armourHit = 255;
|
e->armourHit = 255;
|
||||||
|
|
Loading…
Reference in New Issue