mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
fix LevelController::processBeforeQuit
This commit is contained in:
parent
afe0db2275
commit
0711a2d23e
1 changed files with 5 additions and 2 deletions
|
|
@ -123,8 +123,11 @@ void LevelController::update(float delta, bool pause) {
|
|||
}
|
||||
|
||||
void LevelController::processBeforeQuit() {
|
||||
if (localPlayer) {
|
||||
localPlayer->chunks->saveAndClear();
|
||||
// todo: move somewhere else
|
||||
for (auto player : level->players->getAll()) {
|
||||
if (player->chunks) {
|
||||
player->chunks->saveAndClear();
|
||||
}
|
||||
}
|
||||
scripting::process_before_quit();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue