Cleaning some warnings

This commit is contained in:
Teo-CD 2019-06-09 14:59:17 +02:00
parent 9f28383d7e
commit 4ed9180694
4 changed files with 13 additions and 6 deletions

View file

@ -6,8 +6,8 @@
Level::Level(const pugi::xml_document& xmlDoc, const TextureStore& textureStore)
: textures(textureStore),
size(xmlDoc.child("Level").attribute("w").as_int(),xmlDoc.child("Level").attribute("h").as_int())
: size(xmlDoc.child("Level").attribute("w").as_int(),xmlDoc.child("Level").attribute("h").as_int()),
textures(textureStore)
{
pugi::xml_node levelNode = xmlDoc.child("Level");
for(const pugi::xml_node& child : levelNode.children())
@ -45,6 +45,7 @@ void Level::runStep()
case State::Moving:
{
heuristicSign = 1;
[[fallthrough]];
}
case State::Fleeing:
{
@ -181,7 +182,7 @@ Orientation Level::findPath(pro_maat::GridPos start, pro_maat::GridPos goal, int
pathCosts.insert_or_assign(neighbour,newPathCost);
estimatedCosts.insert_or_assign(neighbour,newPathCost + pro_maat::manhattanDistance(neighbour,goal));
auto returnPathIt = paths.insert_or_assign(neighbour,currentNode);
paths.insert_or_assign(neighbour,currentNode);
}
}