Adding a onStart onStop

This commit is contained in:
Zoe Roux
2021-06-09 16:00:06 +02:00
parent c544a83ee8
commit c94237dedc
13 changed files with 79 additions and 38 deletions

View File

@@ -132,12 +132,10 @@ namespace BBM
{UPPERFLOOR, &createUpperFloor},
};
try {
auto element = elements.at(blockType);
element(coords, scene);
} catch (std::exception const &err) {
if (blockType == NOTHING || blockType == SPAWNER)
return;
}
auto element = elements.at(blockType);
element(coords, std::move(scene));
}
void MapGenerator::createBreakable(Vector3f coords, std::shared_ptr<WAL::Scene> scene)