public class BitmapMapSource extends AbstractMapSource
STEP
Constructor and Description |
---|
BitmapMapSource(BufferedImage[] territories,
int[] ownTerritories,
SortedMap<Integer,int[]> enemyIdsAndTerritories,
BufferedImage sailable) |
BitmapMapSource(BufferedImage[] territories,
int[] ownTerritories,
SortedMap<Integer,int[]> enemyIdsAndTerritories,
BufferedImage sailable,
Logger log) |
Modifier and Type | Method and Description |
---|---|
SortedMap<Integer,BufferedImage> |
getOwnTerritories() |
BufferedImage |
getTerritorry(int index) |
boolean |
hasEnemyTerritoryFlag(double x,
double y,
int enemyId)
Returns true if the given location is a valid territory for the given
teamId.
|
boolean |
hasEnemyTerritoryFlag(double x,
double y,
int enemyId,
boolean seaArea) |
boolean |
hasEnemyTerritoryFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location,
int enemyId)
Returns true if the given location is a valid territory for the given
teamId.
|
boolean |
hasEnemyTerritoryFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location,
int enemyId,
boolean seaArea)
Returns true if the given location is a valid territory for the given
teamId.
|
boolean |
hasFlag(double x,
double y,
BasicFlag flag)
Returns true if the flag is present on the given location.
|
boolean |
hasFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location,
BasicFlag flag)
Returns true if the flag is present on the given location.
|
void |
setTerritorry(int index,
BufferedImage bitmap) |
traceFromTo, traceFromTo
public BitmapMapSource(BufferedImage[] territories, int[] ownTerritories, SortedMap<Integer,int[]> enemyIdsAndTerritories, BufferedImage sailable)
public BitmapMapSource(BufferedImage[] territories, int[] ownTerritories, SortedMap<Integer,int[]> enemyIdsAndTerritories, BufferedImage sailable, Logger log)
public void setTerritorry(int index, BufferedImage bitmap)
public BufferedImage getTerritorry(int index)
public SortedMap<Integer,BufferedImage> getOwnTerritories()
public boolean hasFlag(double x, double y, BasicFlag flag)
IFlagChecker
public boolean hasFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location, BasicFlag flag)
IFlagChecker
public boolean hasEnemyTerritoryFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location, int enemyId)
IFlagChecker
public boolean hasEnemyTerritoryFlag(double x, double y, int enemyId)
IFlagChecker
public boolean hasEnemyTerritoryFlag(cz.cuni.amis.pogamut.base3d.worldview.object.Location location, int enemyId, boolean seaArea)
IFlagChecker
seaArea
- if true then checks, whether [x, y] is a sea territorypublic boolean hasEnemyTerritoryFlag(double x, double y, int enemyId, boolean seaArea)
Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.