minor subcmd tweaks
This commit is contained in:
parent
0afffdd1a1
commit
7b24c2b3f5
@ -19,17 +19,17 @@ public class ReloadSubCmd extends SubCommand {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public TextComponent getSyntax() {
|
public TextComponent getSyntax() {
|
||||||
return Component.text("/villageroptimizer reload").color(NamedTextColor.GOLD);
|
return Component.text("/villageroptimizer reload").color(NamedTextColor.BLUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void perform(CommandSender sender, String[] args) {
|
public void perform(CommandSender sender, String[] args) {
|
||||||
if (sender.hasPermission(Permissions.Commands.RELOAD.get())) {
|
if (sender.hasPermission(Permissions.Commands.RELOAD.get())) {
|
||||||
sender.sendMessage(Component.text("Reloading VillagerOptimizer...").color(NamedTextColor.WHITE));
|
sender.sendMessage(Component.text("Reloading VillagerOptimizer...").color(NamedTextColor.BLUE));
|
||||||
VillagerOptimizer plugin = VillagerOptimizer.getInstance();
|
VillagerOptimizer plugin = VillagerOptimizer.getInstance();
|
||||||
plugin.getServer().getAsyncScheduler().runNow(plugin, reloadPlugin -> {
|
plugin.getServer().getAsyncScheduler().runNow(plugin, reloadPlugin -> {
|
||||||
plugin.reloadPlugin();
|
plugin.reloadPlugin();
|
||||||
sender.sendMessage(Component.text("Reload complete.").color(NamedTextColor.GREEN));
|
sender.sendMessage(Component.text("Reload complete.").color(NamedTextColor.AQUA));
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
sender.sendMessage(VillagerOptimizer.getLang(sender).no_permission);
|
sender.sendMessage(VillagerOptimizer.getLang(sender).no_permission);
|
||||||
|
@ -33,7 +33,7 @@ public class VersionSubCmd extends SubCommand {
|
|||||||
Component.newline()
|
Component.newline()
|
||||||
.append(Component.text(pluginMeta.getName()+" "+pluginMeta.getVersion()).color(NamedTextColor.BLUE).decorate(TextDecoration.BOLD)
|
.append(Component.text(pluginMeta.getName()+" "+pluginMeta.getVersion()).color(NamedTextColor.BLUE).decorate(TextDecoration.BOLD)
|
||||||
.append(Component.text(" by ").color(NamedTextColor.GRAY))
|
.append(Component.text(" by ").color(NamedTextColor.GRAY))
|
||||||
.append(Component.text(pluginMeta.getAuthors().get(0)).color(NamedTextColor.DARK_AQUA))
|
.append(Component.text(pluginMeta.getAuthors().get(0)).color(NamedTextColor.WHITE))
|
||||||
.clickEvent(ClickEvent.openUrl(pluginMeta.getWebsite())))
|
.clickEvent(ClickEvent.openUrl(pluginMeta.getWebsite())))
|
||||||
.append(Component.newline())
|
.append(Component.newline())
|
||||||
);
|
);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user