|
||||||||||
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.BasicBag wyvern.lib.classes.Chest
A chest that can be opened, closed, locked and unlocked.
Nested Class Summary |
Nested classes inherited from class wyvern.lib.Bag |
Bag.FullBagException, Bag.InvalidItemException |
Field Summary |
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 |
Fields inherited from interface wyvern.lib.Bag |
BAG_CUT_PERCENT_CAP, BAG_DEFAULT_CAPACITY |
Constructor Summary | |
Chest()
|
Method Summary | |
boolean |
close(Commandable agent)
Notifies object that it's being closed. |
protected void |
ensureLock()
Creates a Lock if the chest is locked. |
void |
initialize()
Initializes the object's default properties. |
boolean |
isClosed()
Returns true if chest is currently close.d |
boolean |
isLocked()
Returns true if the chest is locked. |
boolean |
isOpen()
Returns true if the chest is currently open. |
void |
lock(Commandable agent)
Locks the lock. |
boolean |
open(Commandable agent)
Notifies object that it's being opened. |
void |
unlock(Commandable agent)
Unlocks the lock. |
protected void |
updateDescription()
Don't show full description unless it's open. |
Methods inherited from class wyvern.lib.classes.BasicBag |
add, addGroupable, adjust, apply, canHoldMore, checkFilter, checkWeight, contains, filter, find, findByName, getCapacity, getEmptyTitle, getItems, getItemWeight, getMaxCount, getPosition, getRemainingCapacity, getTitle, getWeight, hasRoomFor, hasRoomFor, indexOf, initContents, initFilter, insert, invalidate, isBag, isEmpty, isInventory, isMap, iterator, objectAt, printItemList, readData, remove, remove, removeAll, removeAll, removeFirst, removeFirst, setCapacity, setCapacity, setCapacity, setContainer, setObjectAt, setUplinks, shouldWrite, size, visitObjects, writeData, writeItemList |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface wyvern.lib.MethodHookable |
addMethodHook, removeMethodHook, runMethodHook |
Methods inherited from interface wyvern.lib.Broadcaster |
broadcast, broadcast, broadcast, broadcast, broadcast |
Constructor Detail |
public Chest()
Method Detail |
public void initialize()
GameObject
initialize
in interface GameObject
initialize
in class BasicBag
protected void ensureLock()
public boolean isLocked()
isLocked
in interface Openable
public boolean isOpen()
isOpen
in interface Openable
public boolean isClosed()
public boolean open(Commandable agent)
open
in interface Openable
agent
- the agent opening it (can be null)
an
- exception with the appropriate detail message if
the object can't be opened.public boolean close(Commandable agent)
close
in interface Openable
agent
- the agent closed it (can be null)
an
- exception with an appropriate detail message
if the object cannot be closed.protected void updateDescription()
updateDescription
in class BasicBag
public void unlock(Commandable agent)
unlock
in interface Openable
public void lock(Commandable agent)
lock
in interface Openable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |