mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 01:37:37 +00:00
(Temporarily) Include datapacks in debugpaste
This commit is contained in:
parent
b4f9ade5bd
commit
e1d18dc896
@ -30,6 +30,7 @@ import com.sk89q.worldedit.bukkit.BukkitAdapter;
|
|||||||
import com.sk89q.worldedit.bukkit.BukkitPlayer;
|
import com.sk89q.worldedit.bukkit.BukkitPlayer;
|
||||||
import com.sk89q.worldedit.internal.util.LogManagerCompat;
|
import com.sk89q.worldedit.internal.util.LogManagerCompat;
|
||||||
import io.papermc.lib.PaperLib;
|
import io.papermc.lib.PaperLib;
|
||||||
|
import io.papermc.paper.datapack.Datapack;
|
||||||
import org.apache.logging.log4j.Logger;
|
import org.apache.logging.log4j.Logger;
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
@ -147,7 +148,7 @@ public class FaweBukkit implements IFawe, Listener {
|
|||||||
StringBuilder msg = new StringBuilder();
|
StringBuilder msg = new StringBuilder();
|
||||||
Plugin[] plugins = Bukkit.getServer().getPluginManager().getPlugins();
|
Plugin[] plugins = Bukkit.getServer().getPluginManager().getPlugins();
|
||||||
msg.append("Server Version: ").append(Bukkit.getVersion()).append("\n");
|
msg.append("Server Version: ").append(Bukkit.getVersion()).append("\n");
|
||||||
msg.append("Plugins (").append(plugins.length).append("): \n");
|
msg.append("Plugins (").append(plugins.length).append("):\n");
|
||||||
for (Plugin p : plugins) {
|
for (Plugin p : plugins) {
|
||||||
msg.append(" - ").append(p.getName()).append(":").append("\n")
|
msg.append(" - ").append(p.getName()).append(":").append("\n")
|
||||||
.append(" • Version: ").append(p.getDescription().getVersion()).append("\n")
|
.append(" • Version: ").append(p.getDescription().getVersion()).append("\n")
|
||||||
@ -159,6 +160,13 @@ public class FaweBukkit implements IFawe, Listener {
|
|||||||
.append(" • Soft Dependencies: ").append(p.getDescription().getSoftDepend()).append("\n")
|
.append(" • Soft Dependencies: ").append(p.getDescription().getSoftDepend()).append("\n")
|
||||||
.append(" • Provides: ").append(p.getDescription().getProvides()).append("\n");
|
.append(" • Provides: ").append(p.getDescription().getProvides()).append("\n");
|
||||||
}
|
}
|
||||||
|
if (PaperLib.isPaper()) {
|
||||||
|
Collection<Datapack> datapacks = Bukkit.getServer().getDatapackManager().getEnabledPacks();
|
||||||
|
msg.append("Enabled Datapacks (").append(datapacks.size()).append("):\n");
|
||||||
|
for (Datapack dp : datapacks) {
|
||||||
|
msg.append(" - ").append(dp.getName()).append("\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
return msg.toString();
|
return msg.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user