This is 2.2.2

This commit is contained in:
Olof Larsson 2013-11-11 09:31:04 +01:00
parent fa0c8686c1
commit 1a63c59c54
63 changed files with 651 additions and 171 deletions

View File

@ -1,6 +1,6 @@
main: com.massivecraft.factions.Factions
name: Factions
version: 2.2.1
version: 2.2.2
website: http://massivecraft.com/factions
authors: [Cayorion, Brettflan]
description: §eFactions allows the players to team up and claim land as their own and start wars with other factions. This way we hope to inspire politics, intrigue, and team spirit. §aCayorion §efrom the minecraft server §aMassiveCraft §eis the lead Factions programmer. Feel free to visit us at §bhttp://massivecraft.com

View File

@ -1,25 +0,0 @@
package com.massivecraft.factions;
import java.util.*;
import com.massivecraft.mcore.SimpleConfig;
import com.massivecraft.mcore.util.MUtil;
public class ConfServer extends SimpleConfig
{
// -------------------------------------------- //
// INSTANCE & CONSTRUCT
// -------------------------------------------- //
private static transient ConfServer i = new ConfServer();
public static ConfServer get() { return i; }
public ConfServer() { super(Factions.get()); }
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public static List<String> baseCommandAliases = MUtil.list("f");
public static String dburi = "default";
}

View File

@ -2,18 +2,18 @@ package com.massivecraft.factions;
public class Const
{
// MStore Collection Names
public static final String COLLECTION_BASENAME = "factions";
public static final String COLLECTION_BASENAME_ = COLLECTION_BASENAME+"_";
public static final String COLLECTION_BASENAME_BOARD = COLLECTION_BASENAME_+"board";
public static final String COLLECTION_BASENAME_FACTION = COLLECTION_BASENAME_+"faction";
public static final String COLLECTION_BASENAME_UPLAYER = COLLECTION_BASENAME_+"uplayer";
public static final String COLLECTION_BASENAME_MPLAYER = COLLECTION_BASENAME_+"mplayer";
public static final String COLLECTION_BASENAME_UCONF = COLLECTION_BASENAME_+"uconf";
public static final String COLLECTION_BASENAME_MCONF = COLLECTION_BASENAME_+"mconf";
// Collections & Aspects
public static final String BASENAME = "factions";
public static final String BASENAME_ = BASENAME+"_";
// Aspect Ids
public static final String ASPECT_ID = "factions";
public static final String COLLECTION_BOARD = BASENAME_+"board";
public static final String COLLECTION_FACTION = BASENAME_+"faction";
public static final String COLLECTION_UPLAYER = BASENAME_+"uplayer";
public static final String COLLECTION_MPLAYER = BASENAME_+"mplayer";
public static final String COLLECTION_UCONF = BASENAME_+"uconf";
public static final String COLLECTION_MCONF = BASENAME_+"mconf";
public static final String ASPECT = BASENAME;
// ASCII Map
public static final int MAP_HEIGHT = 8;

View File

@ -94,11 +94,8 @@ public class Factions extends MPlugin
{
if ( ! preEnable()) return;
// Load Server Config
ConfServer.get().load();
// Initialize Aspects
this.aspect = AspectColl.get().get(Const.ASPECT_ID, true);
this.aspect = AspectColl.get().get(Const.ASPECT, true);
this.aspect.register();
this.aspect.setDesc(
"<i>If the factions system even is enabled and how it's configured.",
@ -122,7 +119,7 @@ public class Factions extends MPlugin
// Commands
this.outerCmdFactions = new CmdFactions();
this.outerCmdFactions.register(this);
this.outerCmdFactions.register();
// Setup Listeners
FactionsListenerMain.get().setup();

View File

@ -1,15 +1,19 @@
package com.massivecraft.factions.cmd;
import java.util.Collections;
import java.util.List;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Factions;
import com.massivecraft.factions.Perm;
import com.massivecraft.factions.entity.MConf;
import com.massivecraft.mcore.cmd.HelpCommand;
import com.massivecraft.mcore.cmd.VersionCommand;
public class CmdFactions extends FCommand
{
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public CmdFactionsList cmdFactionsList = new CmdFactionsList();
public CmdFactionsFaction cmdFactionsFaction = new CmdFactionsFaction();
public CmdFactionsPlayer cmdFactionsPlayer = new CmdFactionsPlayer();
@ -47,17 +51,13 @@ public class CmdFactions extends FCommand
public CmdFactionsPowerBoost cmdFactionsPowerBoost = new CmdFactionsPowerBoost();
public VersionCommand cmdFactionsVersion = new VersionCommand(Factions.get(), Perm.VERSION.node, "v", "version");
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactions()
{
this.aliases.addAll(ConfServer.baseCommandAliases);
// remove any nulls from extra commas
// TODO: When is this required? Should this be added to MCore?
this.aliases.removeAll(Collections.singletonList(null));
this.setDesc("The faction base command");
this.setHelp("This command contains all faction stuff.");
// Add SubCommands
this.addSubCommand(HelpCommand.get());
this.addSubCommand(this.cmdFactionsList);
this.addSubCommand(this.cmdFactionsFaction);
@ -95,13 +95,20 @@ public class CmdFactions extends FCommand
this.addSubCommand(this.cmdFactionsAdmin);
this.addSubCommand(this.cmdFactionsPowerBoost);
this.addSubCommand(this.cmdFactionsVersion);
// Misc
this.setDesc("The faction base command");
this.setHelp("This command contains all faction stuff.");
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
public List<String> getAliases()
{
this.getCommandChain().add(this);
HelpCommand.getInstance().execute(this.sender, this.args, this.commandChain);
return MConf.get().aliasesF;
}
}

View File

@ -9,28 +9,43 @@ import com.massivecraft.mcore.cmd.req.ReqIsPlayer;
public class CmdFactionsAccess extends FCommand
{
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public CmdFactionsAccessView cmdFactionsAccessView = new CmdFactionsAccessView();
public CmdFactionsAccessPlayer cmdFactionsAccessPlayer = new CmdFactionsAccessPlayer();
public CmdFactionsAccessFaction cmdFactionsAccessFaction = new CmdFactionsAccessFaction();
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAccess()
{
this.addAliases("access");
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqIsPlayer.get());
this.addRequirements(ReqHasPerm.get(Perm.ACCESS.node));
// Add SubCommands
this.addSubCommand(this.cmdFactionsAccessView);
this.addSubCommand(this.cmdFactionsAccessPlayer);
this.addSubCommand(this.cmdFactionsAccessFaction);
// Aliases
this.addAliases("access");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqIsPlayer.get());
this.addRequirements(ReqHasPerm.get(Perm.ACCESS.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{
this.getCommandChain().add(this);
HelpCommand.getInstance().execute(this.sender, this.args, this.commandChain);
HelpCommand.get().execute(this.sender, this.args, this.commandChain);
}
}

View File

@ -17,16 +17,29 @@ import com.massivecraft.mcore.util.Txt;
public abstract class CmdFactionsAccessAbstract extends FCommand
{
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public PS chunk;
public TerritoryAccess ta;
public Faction hostFaction;
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAccessAbstract()
{
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{
@ -58,4 +71,5 @@ public abstract class CmdFactionsAccessAbstract extends FCommand
}
return Txt.implodeCommaAnd(descriptions, Txt.parse("<i>, "), Txt.parse(" <i>and "));
}
}

View File

@ -10,16 +10,27 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsAccessFaction extends CmdFactionsAccessAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAccessFaction()
{
// Aliases
this.addAliases("f", "faction");
// Args
this.addRequiredArg("faction");
this.addOptionalArg("yes/no", "toggle");
// Requirements
this.addRequirements(ReqHasPerm.get(Perm.ACCESS_FACTION.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void innerPerform()
{
@ -40,4 +51,5 @@ public class CmdFactionsAccessFaction extends CmdFactionsAccessAbstract
// Inform
this.sendAccessInfo();
}
}

View File

@ -10,16 +10,27 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsAccessPlayer extends CmdFactionsAccessAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAccessPlayer()
{
// Aliases
this.addAliases("p", "player");
// Args
this.addRequiredArg("player");
this.addOptionalArg("yes/no", "toggle");
// Requirements
this.addRequirements(ReqHasPerm.get(Perm.ACCESS_PLAYER.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void innerPerform()
{
@ -40,4 +51,5 @@ public class CmdFactionsAccessPlayer extends CmdFactionsAccessAbstract
// Inform
this.sendAccessInfo();
}
}

View File

@ -3,19 +3,29 @@ package com.massivecraft.factions.cmd;
import com.massivecraft.factions.Perm;
import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsAccessView extends CmdFactionsAccessAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAccessView()
{
// Aliases
this.addAliases("v", "view");
// Requirements
this.addRequirements(ReqHasPerm.get(Perm.ACCESS_VIEW.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void innerPerform()
{
this.sendAccessInfo();
}
}

View File

@ -7,15 +7,26 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsAdmin extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAdmin()
{
// Aliases
this.addAliases("admin");
// Args
this.addOptionalArg("on/off", "flip");
//this.addRequirements(ReqFactionsEnabled.get());
// Requirements
// this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.ADMIN.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -36,4 +47,5 @@ public class CmdFactionsAdmin extends FCommand
Factions.get().log(msender.getId() + " DISABLED admin bypass mode.");
}
}
}

View File

@ -12,17 +12,28 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsAutoClaim extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsAutoClaim()
{
// Aliases
this.addAliases("autoclaim");
// Args
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.AUTOCLAIM.node));
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{

View File

@ -15,18 +15,28 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsClaim extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsClaim()
{
// Aliases
this.addAliases("claim");
// Args
this.addOptionalArg("radius", "1");
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqIsPlayer.get());
this.addRequirements(ReqHasPerm.get(Perm.CLAIM.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -98,4 +108,5 @@ public class CmdFactionsClaim extends FCommand
};
}
}

View File

@ -21,20 +21,31 @@ import com.massivecraft.mcore.store.MStore;
public class CmdFactionsCreate extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsCreate()
{
// Aliases
this.addAliases("create");
// Args
this.addRequiredArg("name");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasntFaction.get());
this.addRequirements(ReqHasPerm.get(Perm.CREATE.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{
{
// Args
String newName = this.arg(0);

View File

@ -9,13 +9,19 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsDemote extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsDemote()
{
// Aliases
this.addAliases("demote");
// Args
this.addRequiredArg("player");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.DEMOTE.node));
@ -23,6 +29,10 @@ public class CmdFactionsDemote extends FCommand
//To demote someone from officer -> member you must be a leader.
//We'll handle this internally
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -11,18 +11,29 @@ import com.massivecraft.mcore.mixin.Mixin;
public class CmdFactionsDescription extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsDescription()
{
// Aliases
this.addAliases("desc");
// Args
this.addRequiredArg("desc");
this.setErrorOnToManyArgs(false);
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.DESCRIPTION.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -19,15 +19,26 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsDisband extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsDisband()
{
// Aliases
this.addAliases("disband");
// Args
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.DISBAND.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -81,4 +92,5 @@ public class CmdFactionsDisband extends FCommand
faction.detach();
}
}

View File

@ -26,16 +26,27 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsFaction extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsFaction()
{
// Aliases
this.addAliases("f", "faction");
// Args
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.FACTION.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{

View File

@ -12,18 +12,28 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsFlag extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsFlag()
{
// Aliases
this.addAliases("flag");
// Args
this.addOptionalArg("faction", "you");
this.addOptionalArg("flag", "all");
this.addOptionalArg("yes/no", "read");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.FLAG.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -24,15 +24,25 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsHome extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsHome()
{
// Aliases
this.addAliases("home");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.HOME.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -14,18 +14,29 @@ import com.massivecraft.mcore.cmd.req.ReqIsPlayer;
public class CmdFactionsInvite extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsInvite()
{
// Aliases
this.addAliases("inv", "invite");
// Args
this.addRequiredArg("player");
this.addOptionalArg("yes/no", "toggle");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.INVITE.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -16,16 +16,27 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsJoin extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsJoin()
{
// Aliases
this.addAliases("join");
// Args
this.addRequiredArg("faction");
this.addOptionalArg("player", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.JOIN.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -113,4 +124,5 @@ public class CmdFactionsJoin extends FCommand
}
}
}
}

View File

@ -17,16 +17,26 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsKick extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsKick()
{
// Aliases
this.addAliases("kick");
// Args
this.addRequiredArg("player");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.KICK.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -15,17 +15,27 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
import com.massivecraft.mcore.util.Txt;
public class CmdFactionsLeader extends FCommand
{
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsLeader()
{
// Aliases
this.addAliases("leader");
// Args
this.addRequiredArg("player");
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.LEADER.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -97,4 +107,5 @@ public class CmdFactionsLeader extends FCommand
uplayer.msg("%s<i> gave %s<i> the leadership of %s<i>.", senderIsConsole ? "A server admin" : RelationUtil.describeThatToMe(usender, uplayer, true), newLeader.describeTo(uplayer), targetFaction.describeTo(uplayer));
}
}
}

View File

@ -5,16 +5,26 @@ import com.massivecraft.factions.cmd.req.ReqFactionsEnabled;
import com.massivecraft.factions.cmd.req.ReqHasFaction;
import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsLeave extends FCommand {
public class CmdFactionsLeave extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsLeave()
{
// Aliases
this.addAliases("leave");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.LEAVE.node));
this.addRequirements(ReqHasFaction.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -15,16 +15,27 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsList extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsList()
{
// Aliases
this.addAliases("l", "list");
// Args
this.addOptionalArg("page", "1");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.LIST.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{
@ -69,4 +80,5 @@ public class CmdFactionsList extends FCommand
sendMessage(lines);
}
}

View File

@ -10,16 +10,27 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsMap extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMap()
{
// Aliases
this.addAliases("map");
// Args
this.addOptionalArg("on/off", "once");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MAP.node));
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -3,11 +3,14 @@ package com.massivecraft.factions.cmd;
import com.massivecraft.factions.Perm;
import com.massivecraft.factions.cmd.req.ReqBankCommandsEnabled;
import com.massivecraft.factions.cmd.req.ReqFactionsEnabled;
import com.massivecraft.mcore.cmd.HelpCommand;
import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsMoney extends FCommand
{
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public CmdFactionsMoneyBalance cmdMoneyBalance = new CmdFactionsMoneyBalance();
public CmdFactionsMoneyDeposit cmdMoneyDeposit = new CmdFactionsMoneyDeposit();
public CmdFactionsMoneyWithdraw cmdMoneyWithdraw = new CmdFactionsMoneyWithdraw();
@ -15,27 +18,27 @@ public class CmdFactionsMoney extends FCommand
public CmdFactionsMoneyTransferFp cmdMoneyTransferFp = new CmdFactionsMoneyTransferFp();
public CmdFactionsMoneyTransferPf cmdMoneyTransferPf = new CmdFactionsMoneyTransferPf();
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoney()
{
this.addAliases("money");
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqBankCommandsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY.node));
// Add SubCommands
this.addSubCommand(this.cmdMoneyBalance);
this.addSubCommand(this.cmdMoneyDeposit);
this.addSubCommand(this.cmdMoneyWithdraw);
this.addSubCommand(this.cmdMoneyTransferFf);
this.addSubCommand(this.cmdMoneyTransferFp);
this.addSubCommand(this.cmdMoneyTransferPf);
}
@Override
public void perform()
{
this.getCommandChain().add(this);
HelpCommand.getInstance().execute(this.sender, this.args, this.commandChain);
// Aliases
this.addAliases("money");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqBankCommandsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY.node));
}
}

View File

@ -10,16 +10,27 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsMoneyBalance extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyBalance()
{
// Aliases
this.addAliases("b", "balance");
// Args
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_BALANCE.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -15,20 +15,30 @@ import com.massivecraft.mcore.util.Txt;
import org.bukkit.ChatColor;
public class CmdFactionsMoneyDeposit extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyDeposit()
{
// Aliases
this.addAliases("d", "deposit");
// Args
this.addRequiredArg("amount");
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_DEPOSIT.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -18,18 +18,29 @@ import org.bukkit.ChatColor;
public class CmdFactionsMoneyTransferFf extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyTransferFf()
{
// Aliases
this.addAliases("ff");
// Args
this.addRequiredArg("amount");
this.addRequiredArg("faction");
this.addRequiredArg("faction");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_F2F.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -50,4 +61,5 @@ public class CmdFactionsMoneyTransferFf extends FCommand
Factions.get().log(ChatColor.stripColor(Txt.parse("%s transferred %s from the faction \"%s\" to the faction \"%s\"", usender.getName(), Money.format(from, amount), from.describeTo(null), to.describeTo(null))));
}
}
}

View File

@ -20,19 +20,30 @@ import org.bukkit.ChatColor;
public class CmdFactionsMoneyTransferFp extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyTransferFp()
{
// Aliases
this.addAliases("fp");
// Args
this.addRequiredArg("amount");
this.addRequiredArg("faction");
this.addRequiredArg("player");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_F2P.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
{
@ -52,4 +63,5 @@ public class CmdFactionsMoneyTransferFp extends FCommand
Factions.get().log(ChatColor.stripColor(Txt.parse("%s transferred %s from the faction \"%s\" to the player \"%s\"", usender.getName(), Money.format(from, amount), from.describeTo(null), to.describeTo(null))));
}
}
}

View File

@ -20,18 +20,29 @@ import org.bukkit.ChatColor;
public class CmdFactionsMoneyTransferPf extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyTransferPf()
{
// Aliases
this.addAliases("pf");
// Args
this.addRequiredArg("amount");
this.addRequiredArg("player");
this.addRequiredArg("faction");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_P2F.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -52,4 +63,5 @@ public class CmdFactionsMoneyTransferPf extends FCommand
Factions.get().log(ChatColor.stripColor(Txt.parse("%s transferred %s from the player \"%s\" to the faction \"%s\"", usender.getName(), Money.format(from, amount), from.describeTo(null), to.describeTo(null))));
}
}
}

View File

@ -19,17 +19,28 @@ import org.bukkit.ChatColor;
public class CmdFactionsMoneyWithdraw extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsMoneyWithdraw()
{
// Aliases
this.addAliases("w", "withdraw");
// Args
this.addRequiredArg("amount");
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.MONEY_WITHDRAW.node));
this.addRequirements(ReqBankCommandsEnabled.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -49,4 +60,5 @@ public class CmdFactionsMoneyWithdraw extends FCommand
Factions.get().log(ChatColor.stripColor(Txt.parse("%s withdrew %s from the faction bank: %s", usender.getName(), Money.format(from, amount), from.describeTo(null))));
}
}
}

View File

@ -16,17 +16,28 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsName extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsName()
{
// Aliases
this.addAliases("name");
// Args
this.addRequiredArg("new name");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.NAME.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -10,15 +10,26 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsOfficer extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsOfficer()
{
// Aliases
this.addAliases("officer");
// Args
this.addRequiredArg("player");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.OFFICER.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -11,17 +11,28 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsOpen extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsOpen()
{
// Aliases
this.addAliases("open");
// Args
this.addOptionalArg("yes/no", "toggle");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.OPEN.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -14,19 +14,30 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsPerm extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsPerm()
{
// Aliases
this.addAliases("perm");
// Args
this.addOptionalArg("faction", "you");
this.addOptionalArg("perm", "all");
this.addOptionalArg("relation", "read");
this.addOptionalArg("yes/no", "read");
this.setErrorOnToManyArgs(false);
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.PERM.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -14,15 +14,26 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsPlayer extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsPlayer()
{
// Aliases
this.addAliases("p", "player");
// Args
this.addOptionalArg("player", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.PLAYER.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -70,4 +81,5 @@ public class CmdFactionsPlayer extends FCommand
msg("<k>Power per Death: <v>%.2f", uplayer.getPowerPerDeath());
}
}

View File

@ -12,17 +12,28 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsPowerBoost extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsPowerBoost()
{
// Aliases
this.addAliases("powerboost");
// Args
this.addRequiredArg("p|f|player|faction");
this.addRequiredArg("name");
this.addRequiredArg("#");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.POWERBOOST.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -65,4 +76,5 @@ public class CmdFactionsPowerBoost extends FCommand
msg("<i>"+target+" now has a power bonus/penalty of "+targetPower+" to min and max power levels.");
Factions.get().log(usender.getName()+" has set the power bonus/penalty for "+target+" to "+targetPower+".");
}
}

View File

@ -9,12 +9,19 @@ import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public class CmdFactionsPromote extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsPromote()
{
// Aliases
this.addAliases("promote");
// Args
this.addRequiredArg("player");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.PROMOTE.node));
@ -22,6 +29,10 @@ public class CmdFactionsPromote extends FCommand
//To promote someone from member -> officer you must be a leader.
//We'll handle this internally
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -1,6 +1,5 @@
package com.massivecraft.factions.cmd;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.FFlag;
import com.massivecraft.factions.Perm;
import com.massivecraft.factions.Rel;
@ -9,22 +8,33 @@ import com.massivecraft.factions.cmd.req.ReqFactionsEnabled;
import com.massivecraft.factions.cmd.req.ReqHasFaction;
import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast;
import com.massivecraft.factions.entity.Faction;
import com.massivecraft.factions.entity.MConf;
import com.massivecraft.factions.event.FactionsEventRelationChange;
import com.massivecraft.mcore.cmd.req.ReqHasPerm;
public abstract class CmdFactionsRelationAbstract extends FCommand
{
public Rel targetRelation;
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsRelationAbstract()
{
// Aliases
this.addRequiredArg("faction");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.RELATION.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()
@ -75,7 +85,7 @@ public abstract class CmdFactionsRelationAbstract extends FCommand
else
{
otherFaction.msg("%s<i> wishes to be %s.", usenderFaction.describeTo(otherFaction, true), newRelation.getColor()+newRelation.getDescFactionOne());
otherFaction.msg("<i>Type <c>/"+ConfServer.baseCommandAliases.get(0)+" "+newRelation+" "+usenderFaction.getName()+"<i> to accept.");
otherFaction.msg("<i>Type <c>/"+MConf.get().aliasesF.get(0)+" "+newRelation+" "+usenderFaction.getName()+"<i> to accept.");
usenderFaction.msg("%s<i> were informed that you wish to be %s<i>.", otherFaction.describeTo(usenderFaction, true), newRelation.getColor()+newRelation.getDescFactionOne());
}
@ -93,4 +103,5 @@ public abstract class CmdFactionsRelationAbstract extends FCommand
usenderFaction.msg("<i>This will have no effect while your faction is peaceful.");
}
}
}

View File

@ -4,10 +4,17 @@ import com.massivecraft.factions.Rel;
public class CmdFactionsRelationAlly extends CmdFactionsRelationAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsRelationAlly()
{
// Aliases
this.addAliases("ally");
// Misc
this.targetRelation = Rel.ALLY;
}
}

View File

@ -4,10 +4,17 @@ import com.massivecraft.factions.Rel;
public class CmdFactionsRelationEnemy extends CmdFactionsRelationAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsRelationEnemy()
{
// Aliases
this.addAliases("enemy");
// Misc
this.targetRelation = Rel.ENEMY;
}
}

View File

@ -4,10 +4,17 @@ import com.massivecraft.factions.Rel;
public class CmdFactionsRelationNeutral extends CmdFactionsRelationAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsRelationNeutral()
{
// Aliases
this.addAliases("neutral");
// Misc
this.targetRelation = Rel.NEUTRAL;
}
}

View File

@ -4,10 +4,17 @@ import com.massivecraft.factions.Rel;
public class CmdFactionsRelationTruce extends CmdFactionsRelationAbstract
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsRelationTruce()
{
// Aliases
this.addAliases("truce");
// Misc
this.targetRelation = Rel.TRUCE;
}
}

View File

@ -14,14 +14,24 @@ import com.massivecraft.mcore.ps.PSFormatHumanSpace;
public class CmdFactionsSeeChunk extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsSeeChunk()
{
// Aliases
this.addAliases("sc", "seechunk");
//this.addRequirements(ReqFactionsEnabled.get());
// Requirements
// this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.SEE_CHUNK.node));
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -14,16 +14,27 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsSethome extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsSethome()
{
// Aliases
this.addAliases("sethome");
// Args
this.addOptionalArg("faction", "you");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqIsPlayer.get());
this.addRequirements(ReqHasPerm.get(Perm.SETHOME.node));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -15,17 +15,28 @@ import com.massivecraft.mcore.util.Txt;
public class CmdFactionsTitle extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsTitle()
{
// Aliases
this.addAliases("title");
// Args
this.addRequiredArg("player");
this.addOptionalArg("title", "");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.TITLE.node));
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -11,15 +11,25 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsUnclaim extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsUnclaim()
{
// Aliases
this.addAliases("unclaim");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.UNCLAIM.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqIsPlayer.get());
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -20,15 +20,25 @@ import com.massivecraft.mcore.ps.PS;
public class CmdFactionsUnclaimall extends FCommand
{
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsUnclaimall()
{
// Aliases
this.addAliases("unclaimall");
// Requirements
this.addRequirements(ReqFactionsEnabled.get());
this.addRequirements(ReqHasPerm.get(Perm.UNCLAIM_ALL.node));
this.addRequirements(ReqHasFaction.get());
this.addRequirements(ReqRoleIsAtLeast.get(Rel.OFFICER));
}
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void perform()

View File

@ -10,10 +10,18 @@ import com.massivecraft.mcore.util.Txt;
public abstract class FCommand extends MCommand
{
// -------------------------------------------- //
// FIELDS
// -------------------------------------------- //
public MPlayer msender;
public UPlayer usender;
public Faction usenderFaction;
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public void fixSenderVars()
{
@ -68,4 +76,5 @@ public abstract class FCommand extends MCommand
return false;
}
}

View File

@ -4,7 +4,6 @@ import java.util.ArrayList;
import java.util.HashSet;
import java.util.Set;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Factions;
import com.massivecraft.factions.RelationParticipator;
import com.massivecraft.factions.TerritoryAccess;
@ -21,7 +20,7 @@ public class BoardColl extends Coll<Board> implements BoardInterface
public BoardColl(String name)
{
super(name, Board.class, MStore.getDb(ConfServer.dburi), Factions.get(), false, true, true);
super(name, Board.class, MStore.getDb(), Factions.get(), false, true, true);
}
// -------------------------------------------- //

View File

@ -46,7 +46,7 @@ public class BoardColls extends XColls<BoardColl, Board> implements BoardInterfa
@Override
public String getBasename()
{
return Const.COLLECTION_BASENAME_BOARD;
return Const.COLLECTION_BOARD;
}
@Override

View File

@ -8,7 +8,6 @@ import com.massivecraft.mcore.store.Coll;
import com.massivecraft.mcore.store.MStore;
import com.massivecraft.mcore.util.Txt;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.FFlag;
import com.massivecraft.factions.FPerm;
import com.massivecraft.factions.Factions;
@ -24,7 +23,7 @@ public class FactionColl extends Coll<Faction>
public FactionColl(String name)
{
super(name, Faction.class, MStore.getDb(ConfServer.dburi), Factions.get());
super(name, Faction.class, MStore.getDb(), Factions.get());
}
// -------------------------------------------- //

View File

@ -42,7 +42,7 @@ public class FactionColls extends XColls<FactionColl, Faction>
@Override
public String getBasename()
{
return Const.COLLECTION_BASENAME_FACTION;
return Const.COLLECTION_FACTION;
}
@Override

View File

@ -2,6 +2,7 @@ package com.massivecraft.factions.entity;
import java.util.HashSet;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;
import java.util.TreeSet;
@ -40,6 +41,12 @@ public class MConf extends Entity<MConf>
return this;
}
// -------------------------------------------- //
// COMMAND ALIASES
// -------------------------------------------- //
public List<String> aliasesF = MUtil.list("f");
// -------------------------------------------- //
// TASKS
// -------------------------------------------- //

View File

@ -1,6 +1,5 @@
package com.massivecraft.factions.entity;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Const;
import com.massivecraft.factions.Factions;
import com.massivecraft.mcore.MCore;
@ -17,7 +16,7 @@ public class MConfColl extends Coll<MConf>
public static MConfColl get() { return i; }
private MConfColl()
{
super(Const.COLLECTION_BASENAME_MCONF, MConf.class, MStore.getDb(ConfServer.dburi), Factions.get());
super(Const.COLLECTION_MCONF, MConf.class, MStore.getDb(), Factions.get());
}
// -------------------------------------------- //

View File

@ -1,6 +1,5 @@
package com.massivecraft.factions.entity;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Const;
import com.massivecraft.factions.Factions;
import com.massivecraft.mcore.store.MStore;
@ -16,7 +15,7 @@ public class MPlayerColl extends SenderColl<MPlayer>
public static MPlayerColl get() { return i; }
private MPlayerColl()
{
super(Const.COLLECTION_BASENAME_MPLAYER, MPlayer.class, MStore.getDb(ConfServer.dburi), Factions.get());
super(Const.COLLECTION_MPLAYER, MPlayer.class, MStore.getDb(), Factions.get());
}
}

View File

@ -1,6 +1,5 @@
package com.massivecraft.factions.entity;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Factions;
import com.massivecraft.mcore.MCore;
import com.massivecraft.mcore.store.Coll;
@ -14,7 +13,7 @@ public class UConfColl extends Coll<UConf>
public UConfColl(String name)
{
super(name, UConf.class, MStore.getDb(ConfServer.dburi), Factions.get());
super(name, UConf.class, MStore.getDb(), Factions.get());
}
// -------------------------------------------- //

View File

@ -33,7 +33,7 @@ public class UConfColls extends XColls<UConfColl, UConf>
@Override
public String getBasename()
{
return Const.COLLECTION_BASENAME_UCONF;
return Const.COLLECTION_UCONF;
}
@Override

View File

@ -1,6 +1,5 @@
package com.massivecraft.factions.entity;
import com.massivecraft.factions.ConfServer;
import com.massivecraft.factions.Factions;
import com.massivecraft.factions.Rel;
import com.massivecraft.mcore.mixin.Mixin;
@ -17,7 +16,7 @@ public class UPlayerColl extends SenderColl<UPlayer>
public UPlayerColl(String name)
{
super(name, UPlayer.class, MStore.getDb(ConfServer.dburi), Factions.get());
super(name, UPlayer.class, MStore.getDb(), Factions.get());
}
// -------------------------------------------- //

View File

@ -40,7 +40,7 @@ public class UPlayerColls extends XColls<UPlayerColl, UPlayer>
@Override
public String getBasename()
{
return Const.COLLECTION_BASENAME_UPLAYER;
return Const.COLLECTION_UPLAYER;
}
@Override