us.asciiroth.client.items
Class RedRing

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

public class RedRing
extends AbstractItem

When this ring is worn, the player can move through lava. However, the player cannot take the ring off while in the lava. That would just be foolish.


Field Summary
static Serializer<RedRing> SERIALIZER
          Type serializer.
 
Method Summary
 void onDeselect(Event event, Cell cell)
          Notification that the user is trying to deselect the item.
 void onDrop(Event event, Cell cell)
          Notification that the item is about to be dropped.
 void onSelect(Context context, Cell cell)
          Notification that the user is trying to select the item.
 void onThrow(Event event, Cell cell)
          Notification that the item is about to be thrown.
 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, onFire, onHit, onSteppedOn, 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<RedRing> SERIALIZER
Type serializer.

Method Detail

onDeselect

public void onDeselect(Event event,
                       Cell cell)
Description copied from interface: Item
Notification that the user is trying to deselect the item. Cancelling the event prevents the item from being deselected.

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

onDrop

public void onDrop(Event event,
                   Cell cell)
Description copied from interface: Item
Notification that the item is about to be dropped. Cancelling the event at this time prevents the item from leaving the agent's possession (it cannot be dropped for some reason).

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

onSelect

public void onSelect(Context context,
                     Cell cell)
Description copied from interface: Item
Notification that the user is trying to select the item. Cancelling the event has no effect because it creates an odd game experience, but you can undertake work in this method if the item changes the environment

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

onThrow

public void onThrow(Event event,
                    Cell cell)
Description copied from interface: Item
Notification that the item is about to be thrown. If the event is canceled at this time, the item will not be thrown and it stays in the possession of the agent.

Specified by:
onThrow in interface Item
Overrides:
onThrow 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