mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-01 02:46:41 +00:00
Add AsyncCommandBuilder as replacement for AsyncCommandHelper.
See full explanation at https://github.com/EngineHub/WorldGuard/pull/408
This commit is contained in:
@ -67,7 +67,7 @@ public class WorldEditCommands {
|
||||
aliases = { "ver" },
|
||||
desc = "Get WorldEdit version"
|
||||
)
|
||||
public void version(Actor actor) throws WorldEditException {
|
||||
public void version(Actor actor) {
|
||||
actor.print("WorldEdit version " + WorldEdit.getVersion());
|
||||
actor.print("https://github.com/EngineHub/worldedit/");
|
||||
|
||||
@ -90,7 +90,7 @@ public class WorldEditCommands {
|
||||
desc = "Reload configuration"
|
||||
)
|
||||
@CommandPermissions("worldedit.reload")
|
||||
public void reload(Actor actor) throws WorldEditException {
|
||||
public void reload(Actor actor) {
|
||||
we.getPlatformManager().queryCapability(Capability.CONFIGURATION).reload();
|
||||
we.getEventBus().post(new ConfigurationLoadEvent(we.getPlatformManager().queryCapability(Capability.CONFIGURATION).getConfiguration()));
|
||||
actor.print("Configuration reloaded!");
|
||||
@ -100,7 +100,7 @@ public class WorldEditCommands {
|
||||
name = "report",
|
||||
desc = "Writes a report on WorldEdit"
|
||||
)
|
||||
@CommandPermissions({"worldedit.report"})
|
||||
@CommandPermissions("worldedit.report")
|
||||
public void report(Actor actor,
|
||||
@Switch(name = 'p', desc = "Pastebins the report")
|
||||
boolean pastebin) throws WorldEditException {
|
||||
@ -119,10 +119,7 @@ public class WorldEditCommands {
|
||||
|
||||
if (pastebin) {
|
||||
actor.checkPermission("worldedit.report.pastebin");
|
||||
ActorCallbackPaste.pastebin(
|
||||
we.getSupervisor(), actor, result, "WorldEdit report: %s.report",
|
||||
WorldEdit.getInstance().getPlatformManager().getPlatformCommandManager().getExceptionConverter()
|
||||
);
|
||||
ActorCallbackPaste.pastebin(we.getSupervisor(), actor, result, "WorldEdit report: %s.report");
|
||||
}
|
||||
}
|
||||
|
||||
@ -130,7 +127,7 @@ public class WorldEditCommands {
|
||||
name = "cui",
|
||||
desc = "Complete CUI handshake (internal usage)"
|
||||
)
|
||||
public void cui(Player player, LocalSession session) throws WorldEditException {
|
||||
public void cui(Player player, LocalSession session) {
|
||||
session.setCUISupport(true);
|
||||
session.dispatchCUISetup(player);
|
||||
}
|
||||
@ -141,7 +138,7 @@ public class WorldEditCommands {
|
||||
)
|
||||
public void tz(Player player, LocalSession session,
|
||||
@Arg(desc = "The timezone to set")
|
||||
String timezone) throws WorldEditException {
|
||||
String timezone) {
|
||||
try {
|
||||
ZoneId tz = ZoneId.of(timezone);
|
||||
session.setTimezone(tz);
|
||||
|
Reference in New Issue
Block a user