remove unused building HP
This commit is contained in:
@@ -132,15 +132,12 @@ TEST_CASE("WaveSystem: HQ has correct initial HP from config", "[wave]")
|
||||
static_cast<float>(sim.config().stations.hq.hpFormula.evaluate(0.0));
|
||||
bool found = false;
|
||||
float actualHp = 0.0f;
|
||||
for (const Building& b : sim.buildings().allBuildings())
|
||||
{
|
||||
if (b.type == BuildingType::Hq)
|
||||
sim.admin().forEach<HqProxy, Health>(
|
||||
[&](entt::entity /*e*/, const HqProxy& /*hq*/, const Health& h)
|
||||
{
|
||||
found = true;
|
||||
actualHp = b.hp;
|
||||
break;
|
||||
}
|
||||
}
|
||||
actualHp = h.hp;
|
||||
});
|
||||
|
||||
REQUIRE(found);
|
||||
REQUIRE(actualHp == Approx(expectedHp));
|
||||
|
||||
Reference in New Issue
Block a user