|
||||||||||
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.PayTeleporter
A pay teleporter. Set the "teleport-cost" property on the teleporter to set how many gold coins it costs.
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 | |
PayTeleporter()
|
Method Summary | |
void |
apply(Commandable agent)
User applied the staircase. |
CommandEvent |
createEvent(CommandEvent initial)
Creates an event to encapsulate the purchase. |
boolean |
execute(CommandEvent event)
Executes the event. |
void |
initialize()
Initializes the object's default properties. |
boolean |
knowsCommand(java.lang.String command)
Returns true if we want to handle the command. |
boolean |
payForTeleport(Monster agent)
Charges the agent for the teleporter |
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 PayTeleporter()
Method Detail |
public void initialize()
GameObject
initialize
in interface GameObject
initialize
in class Teleporter
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 "buy" event
public boolean payForTeleport(Monster agent)
agent
- the agent
public void apply(Commandable agent)
apply
in interface Applyable
apply
in class Teleporter
agent
- the user
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |