Factions/src/com/massivecraft/factions/entity/UConf.java

112 lines
3.6 KiB
Java
Raw Normal View History

2013-04-22 16:26:44 +02:00
package com.massivecraft.factions.entity;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Set;
import com.massivecraft.factions.Const;
import com.massivecraft.factions.FFlag;
import com.massivecraft.factions.FPerm;
import com.massivecraft.factions.Rel;
2013-04-22 16:26:44 +02:00
import com.massivecraft.mcore.store.Entity;
import com.massivecraft.mcore.util.MUtil;
2013-04-22 16:26:44 +02:00
public class UConf extends Entity<UConf>
{
// -------------------------------------------- //
// META
// -------------------------------------------- //
public static UConf get(Object oid)
2013-04-22 16:26:44 +02:00
{
return UConfColls.get().get2(oid);
2013-04-22 16:26:44 +02:00
}
// -------------------------------------------- //
// CORE
2013-04-22 16:26:44 +02:00
// -------------------------------------------- //
2013-04-23 14:00:18 +02:00
public int factionMemberLimit = 0;
public double factionPowerMax = 1000.0;
public int factionTagLengthMin = 3;
public int factionTagLengthMax = 10;
public boolean factionTagForceUpperCase = false;
// -------------------------------------------- //
// ASSORTED
// -------------------------------------------- //
public boolean permanentFactionsDisableLeaderPromotion = false;
public int actionDeniedPainAmount = 2;
public boolean disablePVPForFactionlessPlayers = false;
public boolean enablePVPAgainstFactionlessInAttackersLand = false;
public double territoryShieldFactor = 0.3;
// -------------------------------------------- //
2013-04-23 14:00:18 +02:00
// DEFAULTS
// -------------------------------------------- //
2013-04-23 14:00:18 +02:00
// TODO: should I add a nofaction id here?
// And perhaps for safezone and warzone as well.
2013-04-23 14:00:18 +02:00
public String defaultPlayerFactionId = Const.FACTIONID_NONE;
public double defaultPlayerPower = 0.0;
public Rel defaultPlayerRole = Rel.RECRUIT;
2013-04-23 14:00:18 +02:00
public boolean defaultFactionOpen = false;
public Map<FFlag, Boolean> defaultFactionFlags = FFlag.getDefaultDefaults();
public Map<FPerm, Set<Rel>> defaultFactionPerms = FPerm.getDefaultDefaults();
// -------------------------------------------- //
// POWER
// -------------------------------------------- //
public double powerMax = 10.0;
public double powerMin = 0.0;
public double powerPerHour = 2.0;
public double powerPerDeath = -2.0;
public boolean canLeaveWithNegativePower = true;
// -------------------------------------------- //
// HOMES
// -------------------------------------------- //
public boolean homesEnabled = true;
public boolean homesMustBeInClaimedTerritory = true;
public boolean homesTeleportCommandEnabled = true;
public boolean homesTeleportAllowedFromEnemyTerritory = true;
public boolean homesTeleportAllowedFromDifferentWorld = true;
public double homesTeleportAllowedEnemyDistance = 32.0;
public boolean homesTeleportIgnoreEnemiesIfInOwnTerritory = true;
// -------------------------------------------- //
// DENY COMMANDS
// -------------------------------------------- //
// commands which will be prevented if the player is a member of a permanent faction
public List<String> denyCommandsPermanentFactionMember = new ArrayList<String>();
// commands which will be prevented when in claimed territory of another faction
2013-04-23 12:31:07 +02:00
public Map<Rel, List<String>> denyCommandsTerritoryRelation = MUtil.map(
Rel.ENEMY, MUtil.list("home", "sethome", "spawn", "tpahere", "tpaccept", "tpa", "warp"),
Rel.NEUTRAL, new ArrayList<String>(),
Rel.TRUCE, new ArrayList<String>(),
Rel.ALLY, new ArrayList<String>(),
Rel.MEMBER, new ArrayList<String>()
);
// -------------------------------------------- //
// INTEGRATION: LWC
// -------------------------------------------- //
public boolean onUnclaimResetLwcLocks = false;
public boolean onCaptureResetLwcLocks = false;
}