mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-02-27 09:42:53 +08:00
Deregister scenes if no one is in them instead of deregistering when no entities are in them
This commit is contained in:
parent
c22c7ecb44
commit
331c02020c
@ -225,7 +225,7 @@ public class Scene {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Deregister scene if not in use
|
// Deregister scene if not in use
|
||||||
if (this.getEntities().size() <= 0 && !this.dontDestroyWhenEmpty()) {
|
if (this.getPlayerCount() <= 0 && !this.dontDestroyWhenEmpty()) {
|
||||||
this.getWorld().deregisterScene(this);
|
this.getWorld().deregisterScene(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user