|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object wyvern.kernel.properties.PList wyvern.kernel.maps.MapObject wyvern.lib.classes.Teleporter wyvern.lib.classes.construct.SpiralStair
A staircase that has 2 destination teleporters, one for "up" and one for "down".
Field Summary |
Fields inherited from class wyvern.lib.classes.Teleporter |
FORCE_PLAYERS, MAX_DISTANCE, PLEASE_WAIT_MSG |
Fields inherited from class wyvern.kernel.maps.MapObject |
IN_MAP_EDITOR, listenerList_ |
Fields inherited from class wyvern.kernel.properties.PList |
readOnly_ |
Fields inherited from interface wyvern.lib.PropertyList |
PROPERTY_PACKAGE |
Constructor Summary | |
SpiralStair()
|
Method Summary | |
void |
apply(Commandable agent)
User applied the staircase. |
CommandEvent |
createEvent(CommandEvent initial)
Creates an event to encapsulate the move. |
boolean |
execute(CommandEvent event)
Executes the event. |
Teleporter |
getDownTeleporter()
Returns the down-teleporter instance, if any. |
Teleporter |
getUpTeleporter()
Returns the up-teleporter instance, if any. |
boolean |
goDownstairs(Commandable agent)
Sends the agent through the down-teleporter. |
boolean |
goUpstairs(Commandable agent)
Sends the agent through the up-teleporter. |
void |
initialize()
Initializes the object's default properties. |
boolean |
knowsCommand(java.lang.String command)
Returns true if we want to handle the command. |
protected void |
setDestinationTeleporters()
Creates "@up-loc" and "@down-loc" Teleporters for the "up" and/or "down" Location properties. |
void |
setDownTeleporter(Teleporter down)
Sets the "down" destination for this staircase. |
void |
setUpTeleporter(Teleporter up)
Sets the "up" destination for this staircase. |
Methods inherited from class wyvern.lib.classes.Teleporter |
checkBounds, checkPerPlayer, checkRelativePath, chooseRandomLocation, getDestination, getDestLoc, getDestMap, getWaitMessage, loadMap, parseDestination, passedClaim, pathOutIsBlocked, printLoadMessage, setDestination, setDestination, setMap, startTeleport, steppedOn, teleport, teleport, teleport, teleport, toString, tryForcing, validateLevel |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public SpiralStair()
Method Detail |
public void initialize()
GameObject
initialize
in interface GameObject
initialize
in class Teleporter
protected void setDestinationTeleporters()
public boolean knowsCommand(java.lang.String command)
knowsCommand
in interface Command
command
- the entire command string, including arguments
public CommandEvent createEvent(CommandEvent initial)
createEvent
in interface Command
initial
- a "blank" CommandEvent containing only the
command text and the agent who's performing the command. This
initial event is created by the originator of the event (e.g.
the AI or player's command preprocessor).
public boolean execute(CommandEvent event)
execute
in interface Command
event
- the "up" or "down" event
public boolean goUpstairs(Commandable agent)
public boolean goDownstairs(Commandable agent)
public void apply(Commandable agent)
apply
in interface Applyable
apply
in class Teleporter
agent
- to teleportpublic Teleporter getUpTeleporter()
public Teleporter getDownTeleporter()
public void setUpTeleporter(Teleporter up)
public void setDownTeleporter(Teleporter down)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |