Skip to content

Commit

Permalink
fix: entity call be null in EntityMobGriefingEvent
Browse files Browse the repository at this point in the history
  • Loading branch information
desht committed Dec 27, 2023
1 parent b9dc65f commit 8fc6138
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ private void entityInteractSpecific(PlayerInteractEvent.EntityInteractSpecific e
}

private void mobGriefing(EntityMobGriefingEvent event) {
if (event.getEntity().getLevel().isClientSide) {
if (event.getEntity() == null || event.getEntity().getLevel().isClientSide) {
// shouldn't ever be called clientside but yay Optifine :(
return;
}
Expand Down

0 comments on commit 8fc6138

Please sign in to comment.