Highlighted items glow in the dark, health bars are hidden when health is full, usernames and health bars are drawn at full brightness

This commit is contained in:
Regalis
2016-07-31 19:13:08 +03:00
parent 1a0451d0a8
commit 581a7d5d9f
6 changed files with 26 additions and 9 deletions
+6 -3
View File
@@ -1165,10 +1165,13 @@ namespace Barotrauma
if (isDead) return;
Vector2 healthBarPos = new Vector2(pos.X - 50, DrawPosition.Y + 100.0f);
if (health < maxHealth * 0.98f)
{
Vector2 healthBarPos = new Vector2(pos.X - 50, DrawPosition.Y + 100.0f);
GUI.DrawProgressBar(spriteBatch, healthBarPos, new Vector2(100.0f, 15.0f), health / maxHealth, Color.Lerp(Color.Red, Color.Green, health / maxHealth) * 0.8f);
}
GUI.DrawProgressBar(spriteBatch, healthBarPos, new Vector2(100.0f, 15.0f), health / maxHealth, Color.Lerp(Color.Red, Color.Green, health / maxHealth) * 0.8f);
if (speechBubbleTimer > 0.0f)
{
GUI.SpeechBubbleIcon.Draw(spriteBatch, pos - Vector2.UnitY * 100.0f,