public interface Tile extends Serializable, com.sun.sgs.app.ManagedObject
ManagedObjects because they are
included as private state for other ManagedObjects.| Modifier and Type | Method and Description |
|---|---|
boolean |
addCharacter(CharacterManager mgr)
Adds the given character to this tile if possible.
|
boolean |
addItem(Item item)
Adds the given item to this tile if possible.
|
boolean |
canOccupy(CharacterManager mgr)
Returns whether or not this tile, in its current state, can be
occupied by the given character.
|
int |
getID()
Returns the identifier for this tile.
|
int[] |
getIdStack()
Returns a stack of identifiers, specifying everything on this
Tile. |
LevelBoard.ActionResult |
getItem(CharacterManager characterManager)
Tries to take an item on this tile.
|
boolean |
isPassable(CharacterManager mgr)
Returns whether or not this space could be entered by the given
character.
|
LevelBoard.ActionResult |
moveTo(CharacterManager characterManager)
Test to move the given character to this tile.
|
boolean |
removeCharacter(CharacterManager mgrRef)
Removes the given character from this tile, if and only if this
character is already on this tile.
|
boolean |
removeItem(Item item)
Removes the given item from this tile, if and only if this item
is already on this tile.
|
int getID()
int[] getIdStack()
Tile. The the zeroeith index is always the same value
as calling getID. If there is am item on this tile,
it is in the next index, and if there is a character on this
tile, it always appears last. There may be multiple items or
characters on a tile, depending on implementation.boolean isPassable(CharacterManager mgr)
canOccupy.mgr - the manager for a characterboolean canOccupy(CharacterManager mgr)
isPassable.mgr - the manager for a characterboolean addCharacter(CharacterManager mgr)
mgr - the manager for a characterboolean removeCharacter(CharacterManager mgrRef)
mgr - the manager for a characterboolean addItem(Item item)
item - the manager for the itemboolean removeItem(Item item)
item - the manager for the itemLevelBoard.ActionResult moveTo(CharacterManager characterManager)
characterManager - the manager for a characterLevelBoard.ActionResult getItem(CharacterManager characterManager)
moveTo,
this actually will remove items from the tile if they are
successfully taken.characterManager - the manager for a characterCopyright © 2013. All Rights Reserved.