PaperMC/paper-server/nms-patches/net/minecraft/server/commands/CommandReload.patch
CraftBukkit/Spigot 9da047989c Repackage NMS
By: md_5 <git@md-5.net>
2021-03-16 09:00:00 +11:00

19 lines
984 B
Diff

--- a/net/minecraft/server/commands/CommandReload.java
+++ b/net/minecraft/server/commands/CommandReload.java
@@ -42,6 +42,16 @@
return collection1;
}
+ // CraftBukkit start
+ public static void reload(MinecraftServer minecraftserver) {
+ ResourcePackRepository resourcepackrepository = minecraftserver.getResourcePackRepository();
+ SaveData savedata = minecraftserver.getSaveData();
+ Collection<String> collection = resourcepackrepository.d();
+ Collection<String> collection1 = a(resourcepackrepository, savedata, collection);
+ minecraftserver.a(collection1);
+ }
+ // CraftBukkit end
+
public static void a(CommandDispatcher<CommandListenerWrapper> commanddispatcher) {
commanddispatcher.register((LiteralArgumentBuilder) ((LiteralArgumentBuilder) net.minecraft.commands.CommandDispatcher.a("reload").requires((commandlistenerwrapper) -> {
return commandlistenerwrapper.hasPermission(2);