PaperMC/paper-server/nms-patches/net/minecraft/server/level/RegionLimitedWorldAccess.patch

17 lines
620 B
Diff
Raw Normal View History

2021-03-15 23:00:00 +01:00
--- a/net/minecraft/server/level/RegionLimitedWorldAccess.java
+++ b/net/minecraft/server/level/RegionLimitedWorldAccess.java
@@ -273,6 +273,13 @@
@Override
public boolean addEntity(Entity entity) {
+ // CraftBukkit start
+ return addEntity(entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.DEFAULT);
+ }
+
+ @Override
+ public boolean addEntity(Entity entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason reason) {
+ // CraftBukkit end
int i = MathHelper.floor(entity.locX() / 16.0D);
int j = MathHelper.floor(entity.locZ() / 16.0D);