|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object us.asciiroth.client.core.AbstractPiece us.asciiroth.client.items.AbstractItem us.asciiroth.client.items.Head
public class Head
The head of an agent. You would create this using the PieceCreator
on the death of a specific agent, in order to create something that the player
could pick up and carry back in order to finish a "slay monster" type quest.
A head does attract the same attention as fish and bones. But there are some restrictions, based on decorum, as to what you can do with it. ;-)
NOTE: A whole agent isn't used here because otherwise this piece couldn't be embedded into a PieceCreator, as it would involve escaping to two levels. So just the name is used.
Field Summary | |
---|---|
static Serializer<Head> |
SERIALIZER
Type serializer. |
Constructor Summary | |
---|---|
Head(java.lang.String name)
Constructor. |
Method Summary | |
---|---|
void |
onSteppedOn(Event event,
Cell agentLoc,
Agent agent)
Notification that an agent has entered the same square as this 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, onDeselect, onDrop, onFire, onHit, onSelect, 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 |
---|
public static final Serializer<Head> SERIALIZER
Constructor Detail |
---|
public Head(java.lang.String name)
name
- Method Detail |
---|
public void onSteppedOn(Event event, Cell agentLoc, Agent agent)
Item
onSteppedOn
in interface Item
onSteppedOn
in class AbstractItem
public void onThrow(Event event, Cell cell)
Item
onThrow
in interface Item
onThrow
in class AbstractItem
public void onUse(Event event)
Item
onUse
in interface Item
onUse
in class AbstractItem
|
0.7 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
© 2009 Alx Dark