Updated Upstream (Paper)

Upstream has released updates that appear to apply and compile correctly

Paper Changes:
PaperMC/Paper@2040c1e Player Flying Fall Damage API (#5357)
PaperMC/Paper@fa42c68 Expose pre-collision moving velocity to VehicleBlockCollisionEvent (#8457)
PaperMC/Paper@90750a6 Rework filtering spawn egg and tile entity nbt config (#6613)
This commit is contained in:
Encode42
2022-12-29 00:19:27 -05:00
parent f7dafcae34
commit dad13788ad
163 changed files with 117 additions and 227 deletions

View File

@@ -0,0 +1,23 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: BillyGalbreath <blake.galbreath@gmail.com>
Date: Sat, 9 Jul 2022 00:57:32 -0500
Subject: [PATCH] Add local difficulty api
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index f8d321e925bf2708e51590542325c1bdc67d5964..fcc6ac180a74daffa173866be3dd97a3ad63ebd7 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -2237,6 +2237,12 @@ public class CraftWorld extends CraftRegionAccessor implements World {
return (this.getHandle().dragonFight() == null) ? null : new CraftDragonBattle(this.getHandle().dragonFight());
}
+ // Purpur start
+ public float getLocalDifficultyAt(Location location) {
+ return getHandle().getCurrentDifficultyAt(io.papermc.paper.util.MCUtil.toBlockPosition(location)).getEffectiveDifficulty();
+ }
+ // Purpur end
+
@Override
public PersistentDataContainer getPersistentDataContainer() {
return this.persistentDataContainer;