Package battlecode.common
Class MapInfo
java.lang.Object
battlecode.common.MapInfo
-
Constructor Summary
ConstructorsConstructorDescriptionMapInfo(MapLocation loc, boolean isPassable, boolean isWall, PaintType paint, PaintType mark, boolean hasRuin, boolean isResourcePatternCenter) -
Method Summary
Modifier and TypeMethodDescriptionReturns the location of this squaregetMark()Returns the mark value of this squaregetPaint()Returns the paint value of this squarebooleanhasRuin()Returns if this square has a ruin.booleanReturns if this square is passable.booleanReturns whether this tile is at the center of an ally resource pattern (regardless of whether the pattern is active yet)booleanisWall()Returns if this square is a wall.toString()
-
Constructor Details
-
MapInfo
public MapInfo(MapLocation loc, boolean isPassable, boolean isWall, PaintType paint, PaintType mark, boolean hasRuin, boolean isResourcePatternCenter)
-
-
Method Details
-
isPassable
public boolean isPassable()Returns if this square is passable.- Returns:
- whether this square is passable
- Bytecode cost:
2
-
isWall
public boolean isWall()Returns if this square is a wall.- Returns:
- whether this square is a wall
- Bytecode cost:
2
-
hasRuin
public boolean hasRuin()Returns if this square has a ruin.- Returns:
- whether this square has a ruin
- Bytecode cost:
2
-
getPaint
Returns the paint value of this square- Returns:
- the paint value of this square
- Bytecode cost:
2
-
getMark
Returns the mark value of this square- Returns:
- the mark value of this square
- Bytecode cost:
2
-
getMapLocation
Returns the location of this square- Returns:
- the location of this square
- Bytecode cost:
1
-
isResourcePatternCenter
public boolean isResourcePatternCenter()Returns whether this tile is at the center of an ally resource pattern (regardless of whether the pattern is active yet)- Returns:
- Whether this is a resource pattern center
-
toString
-