mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-31 04:13:51 -07:00
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/commands/CommandDifficulty.java
|
||||
+++ b/net/minecraft/server/commands/CommandDifficulty.java
|
||||
@@ -42,11 +42,12 @@
|
||||
@@ -44,11 +44,12 @@
|
||||
|
||||
public static int setDifficulty(CommandListenerWrapper commandlistenerwrapper, EnumDifficulty enumdifficulty) throws CommandSyntaxException {
|
||||
MinecraftServer minecraftserver = commandlistenerwrapper.getServer();
|
||||
@@ -12,6 +12,6 @@
|
||||
} else {
|
||||
- minecraftserver.setDifficulty(enumdifficulty, true);
|
||||
+ worldServer.serverLevelData.setDifficulty(enumdifficulty); // CraftBukkit
|
||||
commandlistenerwrapper.sendSuccess(IChatBaseComponent.translatable("commands.difficulty.success", enumdifficulty.getDisplayName()), true);
|
||||
return 0;
|
||||
}
|
||||
commandlistenerwrapper.sendSuccess(() -> {
|
||||
return IChatBaseComponent.translatable("commands.difficulty.success", enumdifficulty.getDisplayName());
|
||||
}, true);
|
||||
|
Reference in New Issue
Block a user