Saber-Factions/src/main/java/com/massivecraft/factions/cmd/CmdReload.java
2015-01-21 19:25:45 -06:00

42 lines
1.1 KiB
Java

package com.massivecraft.factions.cmd;
import com.massivecraft.factions.Conf;
import com.massivecraft.factions.P;
import com.massivecraft.factions.struct.Permission;
import com.massivecraft.factions.zcore.util.TL;
public class CmdReload extends FCommand {
public CmdReload() {
super();
this.aliases.add("reload");
//this.requiredArgs.add("");
this.optionalArgs.put("file", "all");
this.permission = Permission.RELOAD.node;
this.disableOnLock = false;
senderMustBePlayer = false;
senderMustBeMember = false;
senderMustBeModerator = false;
senderMustBeAdmin = false;
}
@Override
public void perform() {
long timeInitStart = System.currentTimeMillis();
Conf.load();
P.p.reloadConfig();
P.p.loadLang();
long timeReload = (System.currentTimeMillis() - timeInitStart);
msg(TL.COMMAND_RELOAD_TIME, timeReload);
}
@Override
public TL getUsageTranslation() {
return TL.COMMAND_RELOAD_DESCRIPTION;
}
}