don't render empty remaining tick bars for iron curtain / chrono

This commit is contained in:
Matthias Mailänder
2013-04-04 19:11:57 +02:00
parent 2fe20b13f1
commit 4a580c3780
2 changed files with 6 additions and 2 deletions

View File

@@ -82,9 +82,11 @@ namespace OpenRA.Mods.RA
// Show the remaining time as a bar
public float GetValue()
{
if (chronoshiftReturnTicks == 0) // otherwise an empty bar is rendered all the time
return 0f;
return (float)chronoshiftReturnTicks / TotalTicks;
}
public Color GetColor() { return Color.White; }
}
}