Changed an 'if' to 'else' in Health.Tick
Since the two 'if's were mutually exclusive, the 2nd 'if' was turned into an 'else' to potentially skip that check if the 1st succeeds.
This commit is contained in:
@@ -171,10 +171,9 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
void ITick.Tick(Actor self)
|
||||
{
|
||||
if (hp > DisplayHP)
|
||||
if (hp >= DisplayHP)
|
||||
DisplayHP = hp;
|
||||
|
||||
if (DisplayHP > hp)
|
||||
else
|
||||
DisplayHP = (2 * DisplayHP + hp) / 3;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user