Merge branch 'Movement' of github.com:teamfisk/TacticalZ into Movement

This commit is contained in:
viktorljung
2016-03-13 22:14:11 +01:00
+1 -1
View File
@@ -35,7 +35,7 @@ void HealthHUDSystem::Update(double dt)
if(entity.HasComponent("Fill")) {
double health = (const double&)entityIDParent["Health"]["Health"];
double maxHealth = (const double&)entityIDParent["Health"]["Health"];
double maxHealth = (const double&)entityIDParent["Health"]["MaxHealth"];
float healthPercentage = health/maxHealth;
entity["Fill"]["Color"] = glm::vec4(1.0 - healthPercentage, 0.f, healthPercentage, glm::vec4(entity["Fill"]["Color"]).a);
entity["Fill"]["Percentage"] = (double)healthPercentage;