Class Equipper

  extended by us.asciiroth.client.core.AbstractPiece
      extended by us.asciiroth.client.terrain.decorators.Decorator
          extended by us.asciiroth.client.terrain.decorators.Equipper
All Implemented Interfaces:
ColorListener, Piece, Terrain, TerrainProxy

public class Equipper
extends Decorator

A utility terrain. When it receives a color event, it adds the indicated item to the player's inventory. (It doesn't matter if the player already has an item of this type). You do not have to use this piece to equip a player at the beginning of a scenario; boards allow you to set starting items for a player if he/she starts the game at that board.

Field Summary
static Serializer<Equipper> SERIALIZER
          Type serializer.
Constructor Summary
Equipper(Terrain terrain, Color color, Item item)
Method Summary
 void onColorEventInternal(Context ctx, Cell cell, Cell origin)
          Override this method in subclasses in order to augment the onTrigger behavior of the decorated terrain.
 Terrain proxy(Terrain terrain)
Methods inherited from class us.asciiroth.client.terrain.decorators.Decorator
canEnter, canExit, getProxiedTerrain, is, not, onAdjacentTo, onAgentEnter, onAgentExit, onColorEvent, onDrop, onEnter, onExit, onFlyOver, onNotAdjacentTo, onPickup
Methods inherited from class us.asciiroth.client.core.AbstractPiece
getColor, getName, getSymbol
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface us.asciiroth.client.core.Piece
getColor, getName, getSymbol

Field Detail


public static final Serializer<Equipper> SERIALIZER
Type serializer.

Constructor Detail


public Equipper(Terrain terrain,
                Color color,
                Item item)

terrain -
color -
item -
Method Detail


public void onColorEventInternal(Context ctx,
                                 Cell cell,
                                 Cell origin)
Description copied from class: Decorator
Override this method in subclasses in order to augment the onTrigger behavior of the decorated terrain.


public Terrain proxy(Terrain terrain)
a new proxy, with the same behavior but wrapping a different terrain


2009 Alx Dark