fix(SceneScriptManager.java): Catch Lua groups NPE

this is a weird issue; found it while testing networking stack and it also crashed the network thread
This commit is contained in:
KingRainbow44 2024-07-06 22:47:37 -04:00
parent f29189be8f
commit af70de316e
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE

View File

@ -507,6 +507,12 @@ public class SceneScriptManager {
.forEach(
block -> {
block.load(sceneId, meta.context);
if (block.groups == null) {
Grasscutter.getLogger()
.error("block.groups null for block {}", block.id);
return;
}
block.groups.values().stream()
.filter(g -> !g.dynamic_load)
.forEach(