Fixed possible NPE in our events, and BrewingStands now remember who last interacted with them, this allows for hoppers to be used with Alchemy Fixes #5004 Fixes #4958 Fixes #4641

This commit is contained in:
nossr50
2024-05-12 14:09:00 -07:00
parent 17052861d1
commit 3ba6b93135
80 changed files with 1137 additions and 797 deletions

View File

@ -18,6 +18,8 @@ import org.jetbrains.annotations.Nullable;
import java.util.*;
import static com.gmail.nossr50.util.MobMetadataUtils.removeMobFlags;
public class TransientEntityTracker {
//These two are updated in step with each other
private final @NotNull HashMap<UUID, HashMap<CallOfTheWildType, HashSet<TrackedTamingEntity>>> perPlayerTransientEntityMap;
@ -273,7 +275,7 @@ public class TransientEntityTracker {
}
//Remove our metadata
mcMMO.getMetadataService().getMobMetadataService().removeMobFlags(livingEntity);
removeMobFlags(livingEntity);
//Clean from trackers
unregisterEntity(livingEntity);