mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-12-01 08:31:14 +00:00
- removed the MaxAmount fudging from MaxHealth.
This commit is contained in:
parent
933ff805f1
commit
3bb42aaff7
1 changed files with 0 additions and 4 deletions
|
@ -99,9 +99,7 @@ class MaxHealth : Health
|
||||||
override bool TryPickup (in out Actor other)
|
override bool TryPickup (in out Actor other)
|
||||||
{
|
{
|
||||||
bool success = false;
|
bool success = false;
|
||||||
int savedAmount = MaxAmount;
|
|
||||||
let player = PlayerPawn(other);
|
let player = PlayerPawn(other);
|
||||||
MaxAmount = Health;
|
|
||||||
if (player)
|
if (player)
|
||||||
{
|
{
|
||||||
if (player.BonusHealth < savedAmount)
|
if (player.BonusHealth < savedAmount)
|
||||||
|
@ -109,10 +107,8 @@ class MaxHealth : Health
|
||||||
player.BonusHealth = min(player.BonusHealth + Amount, savedAmount);
|
player.BonusHealth = min(player.BonusHealth + Amount, savedAmount);
|
||||||
success = true;
|
success = true;
|
||||||
}
|
}
|
||||||
MaxAmount += player.BonusHealth;
|
|
||||||
}
|
}
|
||||||
success |= Super.TryPickup(other);
|
success |= Super.TryPickup(other);
|
||||||
MaxAmount = savedAmount;
|
|
||||||
if (success) GoAwayAndDie();
|
if (success) GoAwayAndDie();
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue