mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-09 11:44:19 +01:00
78ff16111e
By: md_5 <git@md-5.net>
16 lines
620 B
Diff
16 lines
620 B
Diff
--- a/net/minecraft/server/WorldAccess.java
|
|
+++ b/net/minecraft/server/WorldAccess.java
|
|
@@ -5,6 +5,12 @@
|
|
WorldServer getMinecraftWorld();
|
|
|
|
default void addAllEntities(Entity entity) {
|
|
- entity.recursiveStream().forEach(this::addEntity);
|
|
+ // CraftBukkit start
|
|
+ this.addAllEntities(entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.DEFAULT);
|
|
}
|
|
+
|
|
+ default void addAllEntities(Entity entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason reason) {
|
|
+ entity.recursiveStream().forEach((e) -> this.addEntity(e, reason));
|
|
+ }
|
|
+ // CraftBukkit end
|
|
}
|