|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectwyvern.kernel.properties.PList
wyvern.kernel.maps.MapObject
wyvern.lib.classes.construct.ConnectedObject
wyvern.lib.classes.construct.Wall
Basic wall class. Doors are a subclass.
| Field Summary |
| Fields inherited from class wyvern.lib.classes.construct.ConnectedObject |
baseBitmapName_ |
| 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 | |
Wall()
Constructs a new Wall |
|
| Method Summary | |
Predicate |
getNeighborPredicate()
Returns a predicate that returns true if the object is a Wall or a Door. |
void |
initialize()
Sets the class-default properties for this archetype. |
boolean |
predicate(GameObject obj)
Predicate for checking if an object is considered a neighboring wall. |
void |
remove()
Removes from map and unsets opaque bit. |
void |
setMap(GameMap map,
int x,
int y)
Removes any existing wall or door there. |
| Methods inherited from class wyvern.lib.classes.construct.ConnectedObject |
applyBitmap, checkNeighbor, doUpdate, getWallBaseName, haveNeighbor, processNeighbor, setBaseBitmap, stripDirs, teleport, updateBitmap, updateBitmapAndNeighbors |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Wall()
| Method Detail |
public void initialize()
initialize in interface GameObjectinitialize in class ConnectedObject
public void setMap(GameMap map,
int x,
int y)
setMap in interface GameObjectsetMap in class ConnectedObjectmap - game mapx - map xy - map ypublic void remove()
remove in interface GameObjectremove in class ConnectedObjectpublic Predicate getNeighborPredicate()
getNeighborPredicate in class ConnectedObjectpublic boolean predicate(GameObject obj)
This used to be a standalone helper class, but we allocate tens of thousands of wall objects in the game, so making it a function instead is good for performance.
predicate in interface Predicateobj - any GameObject
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||