Introduced Brigadier Command System. More Formatting Coming in next commit.

This commit is contained in:
Driftay
2019-09-14 15:13:01 -04:00
parent b06e6e0f04
commit 3c9b606bb9
207 changed files with 4465 additions and 4017 deletions

View File

@@ -1,6 +1,6 @@
package com.massivecraft.factions.cmd;
import com.massivecraft.factions.P;
import com.massivecraft.factions.FactionsPlugin;
import com.massivecraft.factions.struct.Permission;
import com.massivecraft.factions.zcore.util.TL;
@@ -11,26 +11,18 @@ public class CmdVersion extends FCommand {
this.aliases.add("version");
this.aliases.add("ver");
//this.requiredArgs.add("");
//this.optionalArgs.put("", "");
this.permission = Permission.VERSION.node;
this.disableOnLock = false;
senderMustBePlayer = false;
senderMustBeMember = false;
senderMustBeModerator = false;
senderMustBeAdmin = false;
this.requirements = new CommandRequirements.Builder(Permission.VERSION)
.build();
}
@Override
public void perform() {
msg(TL.COMMAND_VERSION_NAME); // Did this so people can differentiate between P and FactionsUUID (( Requested Feature ))
msg(TL.COMMAND_VERSION_VERSION, P.p.getDescription().getFullName());
public void perform(CommandContext context) {
context.msg(TL.COMMAND_VERSION_NAME); // Did this so people can differentiate between SavageFactions and FactionsUUID (( Requested Feature ))
context.msg(TL.COMMAND_VERSION_VERSION, FactionsPlugin.getInstance().getDescription().getFullName());
}
@Override
public TL getUsageTranslation() {
return TL.COMMAND_VERSION_DESCRIPTION;
}
}
}