us.asciiroth.client.items
Class Fish

java.lang.Object
  extended by us.asciiroth.client.core.AbstractPiece
      extended by us.asciiroth.client.items.AbstractItem
          extended by us.asciiroth.client.items.Fish
All Implemented Interfaces:
Item, Piece

public class Fish
extends AbstractItem

A fish. You can eat it and it will heal you, or throw it and it will attract monsters, who will eat it until it turns into a bone, then eat the bone, etc.


Field Summary
static Serializer<Fish> SERIALIZER
          Type serializer.
 
Method Summary
 void onSteppedOn(Event event, Cell agentLoc, Agent agent)
          Notification that an agent has entered the same square as this item.
 void onUse(Event event)
          The player has used the item without indicating any particular direction for use.
 
Methods inherited from class us.asciiroth.client.items.AbstractItem
getDefiniteNoun, getIndefiniteNoun, onDeselect, onDrop, onFire, onHit, onSelect, onThrow, onThrowEnd
 
Methods inherited from class us.asciiroth.client.core.AbstractPiece
getColor, getName, getSymbol, is, not
 
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, is, not
 

Field Detail

SERIALIZER

public static final Serializer<Fish> SERIALIZER
Type serializer.

Method Detail

onSteppedOn

public void onSteppedOn(Event event,
                        Cell agentLoc,
                        Agent agent)
Description copied from interface: Item
Notification that an agent has entered the same square as this item.

Specified by:
onSteppedOn in interface Item
Overrides:
onSteppedOn in class AbstractItem

onUse

public void onUse(Event event)
Description copied from interface: Item
The player has used the item without indicating any particular direction for use. Even if the item has no intrinsic use, it's helpful to cancel the event with a message explaining that the item requires a direction to be useful.

Specified by:
onUse in interface Item
Overrides:
onUse in class AbstractItem

0.7

© 2009 Alx Dark