mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-18 08:57:44 +01:00
drop vanilla command permission fix since hasPermission(i, bukkitPermission) works as expected now
This commit is contained in:
23
patches/server/0269-Add-local-difficulty-api.patch
Normal file
23
patches/server/0269-Add-local-difficulty-api.patch
Normal 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 86ffc869b57410fd4993c0fd0ae000da2e2c070c..ada46470d5b774d44b16a6f22fffeae631576690 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -2263,6 +2263,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;
|
||||
Reference in New Issue
Block a user