Skip to content

Commit

Permalink
SceneScriptManager fix nullPointer error
Browse files Browse the repository at this point in the history
Merge pull request Grasscutters#1581 from akatatsu27/development
  • Loading branch information
KingRainbow44 authored Jul 26, 2022
2 parents 7600f70 + 7ca947b commit 107111d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ public void checkRegions() {
}

for(int entityId : region.getEntities()) {
if(!region.getMetaRegion().contains(getScene().getEntityById(entityId).getPosition())) {
if(getScene().getEntityById(entityId) == null || !region.getMetaRegion().contains(getScene().getEntityById(entityId).getPosition())) {
region.removeEntity(entityId);

}
Expand Down

0 comments on commit 107111d

Please sign in to comment.