From c9e60f1f6091aec597798811aa19c08f7a71b1fb Mon Sep 17 00:00:00 2001 From: sk89q Date: Fri, 27 Jun 2014 13:14:55 -0700 Subject: [PATCH] Updated /we version with platform information. --- .../sk89q/worldedit/command/WorldEditCommands.java | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/sk89q/worldedit/command/WorldEditCommands.java b/src/main/java/com/sk89q/worldedit/command/WorldEditCommands.java index 6da2a3ecf..203d1c915 100644 --- a/src/main/java/com/sk89q/worldedit/command/WorldEditCommands.java +++ b/src/main/java/com/sk89q/worldedit/command/WorldEditCommands.java @@ -24,6 +24,7 @@ import com.sk89q.minecraft.util.commands.CommandContext; import com.sk89q.minecraft.util.commands.CommandPermissions; import com.sk89q.minecraft.util.commands.Console; import com.sk89q.worldedit.*; +import com.sk89q.worldedit.extension.platform.Capability; import com.sk89q.worldedit.extension.platform.Platform; import com.sk89q.worldedit.extension.platform.PlatformManager; @@ -57,10 +58,15 @@ public class WorldEditCommands { PlatformManager pm = we.getPlatformManager(); - player.printDebug(""); - player.printDebug("Platforms:"); + player.printDebug("----------- Platforms -----------"); for (Platform platform : pm.getPlatforms()) { - player.printDebug(String.format("- %s v%s (WE v%s)", platform.getPlatformName(), platform.getPlatformVersion(), platform.getVersion())); + player.printDebug(String.format("* %s (%s)", platform.getPlatformName(), platform.getPlatformVersion())); + } + + player.printDebug("----------- Capabilities -----------"); + for (Capability capability : Capability.values()) { + Platform platform = pm.queryCapability(capability); + player.printDebug(String.format("%s: %s", capability.name(), platform != null ? platform.getPlatformName() : "NONE")); } }