2013-04-22 09:37:53 +02:00
|
|
|
package com.massivecraft.factions.entity;
|
2013-04-11 09:25:26 +02:00
|
|
|
|
2016-03-15 20:43:54 +01:00
|
|
|
import java.util.List;
|
2014-10-22 07:50:30 +02:00
|
|
|
import java.util.Map;
|
2013-04-24 11:16:37 +02:00
|
|
|
import java.util.Set;
|
2013-04-11 09:25:26 +02:00
|
|
|
|
2013-04-22 09:37:53 +02:00
|
|
|
import com.massivecraft.factions.RelationParticipator;
|
|
|
|
import com.massivecraft.factions.TerritoryAccess;
|
2014-06-04 14:02:23 +02:00
|
|
|
import com.massivecraft.massivecore.ps.PS;
|
2013-04-11 09:25:26 +02:00
|
|
|
|
|
|
|
public interface BoardInterface
|
|
|
|
{
|
|
|
|
// GET
|
|
|
|
public TerritoryAccess getTerritoryAccessAt(PS ps);
|
|
|
|
public Faction getFactionAt(PS ps);
|
|
|
|
|
|
|
|
// SET
|
|
|
|
public void setTerritoryAccessAt(PS ps, TerritoryAccess territoryAccess);
|
|
|
|
public void setFactionAt(PS ps, Faction faction);
|
|
|
|
|
|
|
|
// REMOVE
|
|
|
|
public void removeAt(PS ps);
|
|
|
|
public void removeAll(Faction faction);
|
|
|
|
public void clean();
|
2013-04-24 11:16:37 +02:00
|
|
|
|
|
|
|
// CHUNKS
|
|
|
|
public Set<PS> getChunks(Faction faction);
|
2014-10-22 07:50:30 +02:00
|
|
|
public Set<PS> getChunks(String factionId);
|
|
|
|
public Map<Faction, Set<PS>> getFactionToChunks();
|
2013-04-11 09:25:26 +02:00
|
|
|
|
|
|
|
// COUNT
|
|
|
|
public int getCount(Faction faction);
|
2014-10-18 18:30:13 +02:00
|
|
|
public int getCount(String factionId);
|
2014-10-22 07:50:30 +02:00
|
|
|
public Map<Faction, Integer> getFactionToCount();
|
2013-04-11 09:25:26 +02:00
|
|
|
|
|
|
|
// NEARBY DETECTION
|
|
|
|
public boolean isBorderPs(PS ps);
|
2014-10-13 11:42:40 +02:00
|
|
|
public boolean isAnyBorderPs(Set<PS> pss);
|
2013-04-11 09:25:26 +02:00
|
|
|
public boolean isConnectedPs(PS ps, Faction faction);
|
2014-10-13 11:42:40 +02:00
|
|
|
public boolean isAnyConnectedPs(Set<PS> pss, Faction faction);
|
2013-04-11 09:25:26 +02:00
|
|
|
|
|
|
|
// MAP
|
|
|
|
// TODO: Could the degrees be embedded in centerPs yaw instead?
|
2016-03-15 20:43:54 +01:00
|
|
|
public List<Object> getMap(RelationParticipator observer, PS centerPs, double inDegrees, int width, int height);
|
2013-04-11 09:25:26 +02:00
|
|
|
|
|
|
|
}
|