Removing some deprecated stuff and fixing some ASCII art.

This commit is contained in:
Olof Larsson 2013-04-10 09:40:39 +02:00
parent 27cee7d6f7
commit 57f5372d43
3 changed files with 21 additions and 67 deletions

View File

@ -296,9 +296,9 @@ public class Faction extends Entity implements EconomyParticipator
}
// TODO: Implement a has enough feature.
//----------------------------------------------//
// -------------------------------------------- //
// Power
//----------------------------------------------//
// -------------------------------------------- //
public double getPower()
{
if (this.getFlag(FFlag.INFPOWER))
@ -361,9 +361,9 @@ public class Faction extends Entity implements EconomyParticipator
return this.getLandRounded() > this.getPowerRounded();
}
// -------------------------------
// -------------------------------------------- //
// FPlayers
// -------------------------------
// -------------------------------------------- //
// maintain the reference list of FPlayers in this faction
public void refreshFPlayers()
@ -504,9 +504,9 @@ public class Faction extends Entity implements EconomyParticipator
}
}
//----------------------------------------------//
// -------------------------------------------- //
// Messages
//----------------------------------------------//
// -------------------------------------------- //
public void msg(String message, Object... args)
{
message = Factions.get().txt.parse(message, args);
@ -533,53 +533,9 @@ public class Faction extends Entity implements EconomyParticipator
}
}
//----------------------------------------------//
// Deprecated
//----------------------------------------------//
/**
* @deprecated As of release 1.7, replaced by {@link #getFPlayerLeader()}
*/
public FPlayer getFPlayerAdmin()
{
return getFPlayerLeader();
}
/**
* @deprecated As of release 1.7, replaced by {@link #getFlag()}
*/
public boolean isPeaceful()
{
return this.getFlag(FFlag.PEACEFUL);
}
/**
* @deprecated As of release 1.7, replaced by {@link #getFlag()}
*/
public boolean getPeacefulExplosionsEnabled()
{
return this.getFlag(FFlag.EXPLOSIONS);
}
/**
* @deprecated As of release 1.7, replaced by {@link #getFlag()}
*/
public boolean noExplosionsInTerritory()
{
return ! this.getFlag(FFlag.EXPLOSIONS);
}
/**
* @deprecated As of release 1.7, replaced by {@link #getFlag()}
*/
public boolean isSafeZone()
{
return ! this.getFlag(FFlag.EXPLOSIONS);
}
//----------------------------------------------//
// -------------------------------------------- //
// Persistance and entity management
//----------------------------------------------//
// -------------------------------------------- //
@Override
public void postDetach()

View File

@ -43,9 +43,9 @@ public class FactionColl extends EntityCollection<Faction>
{
if ( ! super.loadFromDisc()) return false;
//----------------------------------------------//
// -------------------------------------------- //
// Create Default Special Factions
//----------------------------------------------//
// -------------------------------------------- //
if ( ! this.exists("0"))
{
Faction faction = this.create("0");
@ -69,9 +69,9 @@ public class FactionColl extends EntityCollection<Faction>
this.setFlagsForWarZone(faction);
}
//----------------------------------------------//
// -------------------------------------------- //
// Fix From Old Formats
//----------------------------------------------//
// -------------------------------------------- //
Faction wild = this.get("0");
Faction safeZone = this.get("-1");
Faction warZone = this.get("-2");
@ -99,9 +99,9 @@ public class FactionColl extends EntityCollection<Faction>
return true;
}
//----------------------------------------------//
// -------------------------------------------- //
// Flag Setters
//----------------------------------------------//
// -------------------------------------------- //
public void setFlagsForWilderness(Faction faction)
{
faction.setOpen(false);
@ -172,9 +172,9 @@ public class FactionColl extends EntityCollection<Faction>
}
//----------------------------------------------//
// -------------------------------------------- //
// GET
//----------------------------------------------//
// -------------------------------------------- //
@Override
public Faction get(String id)
@ -194,9 +194,9 @@ public class FactionColl extends EntityCollection<Faction>
return this.get("0");
}
//----------------------------------------------//
// -------------------------------------------- //
// Faction tag
//----------------------------------------------//
// -------------------------------------------- //
public static ArrayList<String> validateTag(String str)
{

View File

@ -18,7 +18,7 @@ public class TerritoryAccess
private boolean hostFactionAllowed = true;
public boolean isHostFactionAllowed() { return this.hostFactionAllowed; }
public void setHostFactionAllowed(boolean allowed) { this.hostFactionAllowed = allowed; }
public void setHostFactionAllowed(boolean hostFactionAllowed) { this.hostFactionAllowed = hostFactionAllowed; }
private Set<String> factionIds = new LinkedHashSet<String>();
public Set<String> getFactionIds() { return this.factionIds; }
@ -30,11 +30,9 @@ public class TerritoryAccess
// CONSTRUCT
// -------------------------------------------- //
public TerritoryAccess(String factionID)
public TerritoryAccess(String hostFactionId)
{
hostFactionId = factionID;
this.hostFactionId = hostFactionId;
}
public TerritoryAccess()