mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-17 16:37:43 +01:00
Add permission for F3+N debug
This commit is contained in:
@@ -34,6 +34,10 @@ need to be granted the permissions you want them to have using a permissions plu
|
||||
Hold spacebar while not moving to charge the toggle. Instead of blowing up the powered
|
||||
state will toggle on or off.
|
||||
|
||||
* **purpur.debug.f3n**
|
||||
- **description**: Allows the use of the F3+N debug hotkey to swap gamemodes.
|
||||
Player must have this perm _and_ the gamemode perm for it to work.
|
||||
|
||||
* **purpur.drop.spawners**
|
||||
- **description**: Players with this permission can use a diamond pickaxe with silk
|
||||
touch enchantment to mine up any spawner cage instead of disappearing.
|
||||
|
||||
24
patches/server/0093-Add-permission-for-F3-N-debug.patch
Normal file
24
patches/server/0093-Add-permission-for-F3-N-debug.patch
Normal file
@@ -0,0 +1,24 @@
|
||||
From 58c42c906efcb19a5f6f3bc28d589165f96c5f39 Mon Sep 17 00:00:00 2001
|
||||
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
|
||||
Date: Sat, 28 Dec 2019 04:21:54 -0600
|
||||
Subject: [PATCH] Add permission for F3+N debug
|
||||
|
||||
---
|
||||
src/main/java/net/minecraft/server/PlayerList.java | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index 6398c367f..c48933cd6 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -904,6 +904,7 @@ public abstract class PlayerList {
|
||||
} else {
|
||||
b0 = (byte) (24 + i);
|
||||
}
|
||||
+ if (b0 < 28 && entityplayer.getBukkitEntity().hasPermission("purpur.debug.f3n")) b0 = 28; // Purpur
|
||||
|
||||
entityplayer.playerConnection.sendPacket(new PacketPlayOutEntityStatus(entityplayer, b0));
|
||||
}
|
||||
--
|
||||
2.24.0
|
||||
|
||||
Reference in New Issue
Block a user