Moved the last stuff away from ConfServer.

This commit is contained in:
Olof Larsson
2013-04-24 08:39:26 +02:00
parent d9a23241ec
commit 825d937c84
22 changed files with 195 additions and 200 deletions

View File

@@ -2,7 +2,7 @@ package com.massivecraft.factions.cmd.req;
import org.bukkit.command.CommandSender;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.entity.UConf;
import com.massivecraft.mcore.cmd.MCommand;
import com.massivecraft.mcore.cmd.req.ReqAbstract;
import com.massivecraft.mcore.util.Txt;
@@ -25,17 +25,16 @@ public class ReqBankCommandsEnabled extends ReqAbstract
@Override
public boolean apply(CommandSender sender, MCommand command)
{
return ConfServer.econEnabled && ConfServer.bankEnabled;
return UConf.get(sender).econEnabled && UConf.get(sender).bankEnabled;
}
@Override
public String createErrorMessage(CommandSender sender, MCommand command)
{
if (!ConfServer.bankEnabled)
if (!UConf.get(sender).bankEnabled)
{
return Txt.parse("<b>The Factions bank system is disabled on this server.");
}
return Txt.parse("<b>The Factions economy features are disabled on this server.");
}