mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-07 03:51:50 +00:00
Minor refactor and fixes
This commit is contained in:
parent
1b935aa081
commit
5175c9be92
4 changed files with 12 additions and 10 deletions
|
|
@ -72,7 +72,6 @@ MenuScreen::MenuScreen(Engine* engine_) : Screen(engine_) {
|
|||
});
|
||||
panel->add(shared_ptr<UINode>(button));
|
||||
}
|
||||
|
||||
this->panel = shared_ptr<UINode>(panel);
|
||||
engine->getGUI()->add(this->panel);
|
||||
}
|
||||
|
|
@ -100,15 +99,12 @@ LevelScreen::~LevelScreen() {
|
|||
delete hud;
|
||||
delete worldRenderer;
|
||||
|
||||
|
||||
std::cout << "-- writing world" << std::endl;
|
||||
World* world = level->world;
|
||||
|
||||
std::cout << "-- saving world" << std::endl;
|
||||
world->write(level, !engine->getSettings().debug.generatorTestMode);
|
||||
|
||||
delete world;
|
||||
delete level;
|
||||
|
||||
delete world;
|
||||
}
|
||||
|
||||
void LevelScreen::updateHotkeys() {
|
||||
|
|
@ -151,4 +147,4 @@ void LevelScreen::draw(float delta) {
|
|||
if (level->player->debug) {
|
||||
hud->drawDebug( 1 / delta, occlusion);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue