geforkt von Mirrors/Paper
9da047989c
By: md_5 <git@md-5.net>
21 Zeilen
1.4 KiB
Diff
21 Zeilen
1.4 KiB
Diff
--- a/net/minecraft/server/commands/CommandGamerule.java
|
|
+++ b/net/minecraft/server/commands/CommandGamerule.java
|
|
@@ -29,7 +29,7 @@
|
|
|
|
private static <T extends GameRules.GameRuleValue<T>> int b(CommandContext<CommandListenerWrapper> commandcontext, GameRules.GameRuleKey<T> gamerules_gamerulekey) {
|
|
CommandListenerWrapper commandlistenerwrapper = (CommandListenerWrapper) commandcontext.getSource();
|
|
- T t0 = commandlistenerwrapper.getServer().getGameRules().get(gamerules_gamerulekey);
|
|
+ T t0 = commandlistenerwrapper.getWorld().getGameRules().get(gamerules_gamerulekey); // CraftBukkit
|
|
|
|
t0.b(commandcontext, "value");
|
|
commandlistenerwrapper.sendMessage(new ChatMessage("commands.gamerule.set", new Object[]{gamerules_gamerulekey.a(), t0.toString()}), true);
|
|
@@ -37,7 +37,7 @@
|
|
}
|
|
|
|
private static <T extends GameRules.GameRuleValue<T>> int b(CommandListenerWrapper commandlistenerwrapper, GameRules.GameRuleKey<T> gamerules_gamerulekey) {
|
|
- T t0 = commandlistenerwrapper.getServer().getGameRules().get(gamerules_gamerulekey);
|
|
+ T t0 = commandlistenerwrapper.getWorld().getGameRules().get(gamerules_gamerulekey); // CraftBukkit
|
|
|
|
commandlistenerwrapper.sendMessage(new ChatMessage("commands.gamerule.query", new Object[]{gamerules_gamerulekey.a(), t0.toString()}), false);
|
|
return t0.getIntValue();
|