From 35e4935497910a37711fc744646d05efced90e3e Mon Sep 17 00:00:00 2001 From: Tleety Date: Thu, 11 Feb 2016 10:01:11 +0100 Subject: [PATCH] Some assets and HUD stuff --- assets | 2 +- .../Schema/Entities/CapturePointHUDGroup | 172 ++++++++++++++++++ .../Schema/Entities/QualityAssurance.xml | 75 ++++---- src/Game/Systems/CapturePointHUDSystem.cpp | 5 +- 4 files changed, 215 insertions(+), 39 deletions(-) create mode 100644 resources/Schema/Entities/CapturePointHUDGroup diff --git a/assets b/assets index 7531e441..0580eeae 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 7531e441fea639076d69c6cf05e3ae8ff7170cf9 +Subproject commit 0580eeae80919127622e16f2ec4f4083668d36cd diff --git a/resources/Schema/Entities/CapturePointHUDGroup b/resources/Schema/Entities/CapturePointHUDGroup new file mode 100644 index 00000000..9dce0ffb --- /dev/null +++ b/resources/Schema/Entities/CapturePointHUDGroup @@ -0,0 +1,172 @@ + + + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + 2 + + + + + + Textures/Core/UnitHexagon_Rotated.png + + + + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + 3 + + + 0.80222018197612788 + + + + Textures/Core/UnitHexagon_Rotated.png + + + + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + 4 + + + + + + Textures/Core/UnitHexagon_Rotated.png + + + + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + 1 + + + + + + Textures/Core/UnitHexagon_Rotated.png + + + + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + + + + + Textures/Core/UnitHexagon_Rotated.png + + + + + + + + + + + + + + diff --git a/resources/Schema/Entities/QualityAssurance.xml b/resources/Schema/Entities/QualityAssurance.xml index ce6a650e..2c77bc30 100644 --- a/resources/Schema/Entities/QualityAssurance.xml +++ b/resources/Schema/Entities/QualityAssurance.xml @@ -40,7 +40,7 @@ - + @@ -180,7 +180,7 @@ - + @@ -671,7 +671,7 @@ - + @@ -718,7 +718,7 @@ - + @@ -778,7 +778,7 @@ - + @@ -825,7 +825,7 @@ - + @@ -871,7 +871,7 @@ - + @@ -918,7 +918,7 @@ - + @@ -965,7 +965,7 @@ - + @@ -1023,6 +1023,7 @@ + 15 Models/Core/UnitCube.mesh @@ -1162,7 +1163,6 @@ - -12.033302729641917 3 @@ -1212,6 +1212,7 @@ + -15 4 @@ -1378,7 +1379,7 @@ - + @@ -1387,7 +1388,7 @@ true - 0.75158864645285173 + 0.75184169309215043 3.7999999523162842 true @@ -1434,7 +1435,7 @@ - + @@ -1443,7 +1444,7 @@ - 1.2014943970669589 + 1.2017474437062576 Models/Characters/Assault/AssaultTPose.mesh @@ -1486,7 +1487,7 @@ - + @@ -1497,7 +1498,7 @@ true - 0.68494018072689011 + 0.68519322736618882 true @@ -1542,7 +1543,7 @@ - + @@ -1552,7 +1553,7 @@ true - 0.95103870157425385 + 0.95129174821355256 10 3 @@ -1600,7 +1601,7 @@ - + @@ -1610,7 +1611,7 @@ true - 1.3510669629503185 + 1.3513200095896172 true 5 true @@ -1791,7 +1792,7 @@ true - 1.3677400229854642 + 1.3679930696247629 3.7999999523162842 true @@ -1965,7 +1966,7 @@ Textures/Core/UnitHexagon.png - + @@ -1978,7 +1979,7 @@ 2 - 0.5 + Textures/Core/UnitHexagon_Rotated.png @@ -1986,7 +1987,7 @@ - + @@ -1997,7 +1998,7 @@ Textures/Core/UnitHexagon.png - + @@ -2010,7 +2011,7 @@ 3 - 0.5 + Textures/Core/UnitHexagon_Rotated.png @@ -2018,7 +2019,7 @@ - + @@ -2029,7 +2030,7 @@ Textures/Core/UnitHexagon.png - + @@ -2042,7 +2043,8 @@ 4 - 0.5 + 1 + Textures/Core/UnitHexagon_Rotated.png @@ -2050,7 +2052,7 @@ - + @@ -2061,7 +2063,7 @@ Textures/Core/UnitHexagon.png - + @@ -2074,7 +2076,7 @@ 1 - 0.5 + Textures/Core/UnitHexagon_Rotated.png @@ -2082,7 +2084,7 @@ - + @@ -2093,7 +2095,7 @@ Textures/Core/UnitHexagon.png - + @@ -2104,7 +2106,8 @@ - 0.5 + 1 + Textures/Core/UnitHexagon_Rotated.png @@ -2112,7 +2115,7 @@ - + diff --git a/src/Game/Systems/CapturePointHUDSystem.cpp b/src/Game/Systems/CapturePointHUDSystem.cpp index 5c4c2b60..ad8cc63a 100644 --- a/src/Game/Systems/CapturePointHUDSystem.cpp +++ b/src/Game/Systems/CapturePointHUDSystem.cpp @@ -13,7 +13,7 @@ CapturePointHUDSystem::CapturePointHUDSystem(World* world, EventBroker* eventBro void CapturePointHUDSystem::Update(double dt) { - bool LoadCheck = false; + bool LoadCheck = true; int redTeam; int blueTeam; int spectatorTeam; @@ -32,10 +32,11 @@ void CapturePointHUDSystem::Update(double dt) //Check if the HUD corresponds to the Capture Point Number if (HUD_ID == (int)entityCP["CapturePoint"]["CapturePointNumber"]) { ComponentWrapper& teamComponent = entityCP["Team"]; - if (!LoadCheck) { + if (LoadCheck) { redTeam = (int)teamComponent["Team"].Enum("Red"); blueTeam = (int)teamComponent["Team"].Enum("Blue"); spectatorTeam = (int)teamComponent["Team"].Enum("Spectator"); + LoadCheck = false; } //Color hud with team color auto capturePointTeam = (int)teamComponent["Team"];