Add some patches, fix compile
This commit is contained in:
@@ -20,9 +20,15 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+ if (d0 <= 128.0) {
|
||||
+ list = world.getEntitiesOfClass(Player.class, axisalignedbb);
|
||||
+ } else {
|
||||
+ list = (List)world.getNearbyPlayers(null, (double)blockposition.getX() + 0.5, (double)blockposition.getY() + 0.5, (double)blockposition.getZ() + 0.5, -1.0, (net.minecraft.world.entity.Entity entity) -> {
|
||||
+ return !entity.isSpectator() && entity.getBoundingBox().intersects(axisalignedbb);
|
||||
+ });
|
||||
+ list = new java.util.ArrayList<>();
|
||||
+ for (Player player : world.players()) {
|
||||
+ if (player.isSpectator()) {
|
||||
+ continue;
|
||||
+ }
|
||||
+ if (player.getBoundingBox().intersects(axisalignedbb)) {
|
||||
+ list.add(player);
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+ // Paper end - optimize player lookup for beacons
|
||||
|
||||
|
||||
Reference in New Issue
Block a user