|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.planet_ink.coffee_mud.Locales.StdRoom
com.planet_ink.coffee_mud.Locales.StdGrid
public class StdGrid
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Locales.interfaces.GridLocale |
|---|
GridLocale.ThinGridEntry, GridLocale.ThinGridEntryConverter |
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.core.interfaces.ItemPossessor |
|---|
ItemPossessor.Expire, ItemPossessor.Find, ItemPossessor.Move |
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Areas.interfaces.GridZones |
|---|
GridZones.XYVector |
| Field Summary | |
|---|---|
protected java.lang.String[] |
descriptions
|
protected java.lang.String[] |
displayTexts
|
protected SVector<WorldMap.CrossExit> |
gridexits
|
protected Room[][] |
subMap
|
protected int |
xsize
|
protected int |
ysize
|
| Fields inherited from class com.planet_ink.coffee_mud.Locales.StdRoom |
|---|
affects, amDestroyed, basePhyStats, behaviors, cachedImageName, contents, description, displayText, doors, exits, expirationDate, gridParent, inhabitants, mobility, myArea, myID, myResource, name, phyStats, rawImageName, resourceFound, scripts, skyedYet, STDCODES, tickStatus, xtraValues |
| Constructor Summary | |
|---|---|
StdGrid()
|
|
| Method Summary | |
|---|---|
void |
addOuterExit(WorldMap.CrossExit x)
|
protected Room |
alternativeLink(Room room,
Room defaultRoom,
int dir)
|
protected void |
buildFinalLinks()
|
void |
buildGrid()
|
void |
clearGrid(Room backHere)
|
protected void |
cloneFix(Room E)
|
void |
delOuterExit(WorldMap.CrossExit x)
|
void |
destroy()
Utterly and permanently destroy this object, not only removing it from the map, but causing this object to be collected as garbage by Java. |
void |
fillInTheExtraneousExternals(Room[][] subMap,
Exit ox)
|
protected Room |
findCenterRoom(int dirCode)
|
java.util.List<Room> |
getAllRooms()
|
Room |
getAltRoomFrom(Room loc,
int direction)
|
protected Room[][] |
getBuiltGrid()
|
java.util.Iterator<Room> |
getExistingRooms()
|
Room |
getGridChild(GridZones.XYVector xy)
Returns the Room object at the given coordinates. |
Room |
getGridChild(int x,
int y)
Returns the Room object at the given coordinates. |
Room |
getGridChild(java.lang.String childCode)
Returns the fully-qualified Room ID of this room |
java.lang.String |
getGridChildCode(Room loc)
Returns the fully-qualified Room ID of this room |
java.lang.String |
getGridChildLocaleID()
|
int |
getGridChildX(Room loc)
Returns the X coordinate of the given Room object |
int |
getGridChildY(Room loc)
Returns the Y coordinate of the given Room object |
protected Room |
getGridRoom(int x,
int y)
|
Room |
getRandomGridChild()
Returns a random Room object that is a child of this one. |
GridZones.XYVector |
getRoomXY(Room room)
Returns the XY coordinates of the Room, if a child of this gridzone, in XYVector format. |
GridZones.XYVector |
getRoomXY(java.lang.String roomID)
Returns the XY coordinates of the Room with the given roomID in XYVector format. |
java.lang.String |
getStat(java.lang.String code)
An alternative means of retreiving the values of those fields on this object which are modifiable at run-time by builders. |
java.lang.String[] |
getStatCodes()
Returns an array of the string names of those fields which are modifiable on this object at run-time by builders. |
protected int |
getStdGridCodeNum(java.lang.String code)
|
protected void |
halfLink(Room room,
Room loc,
int dirCode,
Exit o)
|
java.lang.String |
ID()
The CoffeeMud Java Class ID shared by all instances of this object. |
protected int[] |
initCenterRoomAdjustsXY(int dirCode)
|
protected int[] |
initCenterRoomXY(int dirCode)
|
boolean |
isMyGridChild(Room loc)
Returns whether the given Room is a child of this particular Grid instance. |
protected void |
linkRoom(Room room,
Room loc,
int dirCode,
Exit o,
Exit ao)
|
CMObject |
newInstance()
Returns a new instance of this class. |
boolean |
okMessage(Environmental myHost,
CMMsg msg)
The general message event previewer for the object. |
java.util.Iterator<WorldMap.CrossExit> |
outerExits()
|
Room |
prepareGridLocale(Room fromRoom,
Room toRoom,
int direction)
|
Room |
prepareRoomInDir(Room fromRoom,
int direction)
|
void |
setDescription(java.lang.String newDescription)
Sets the basic description of this object, as shown when the item is directly LOOKed at. |
void |
setDisplayText(java.lang.String newDisplayText)
Sets the raw string used to show what this object looks like in the room. |
void |
setStat(java.lang.String code,
java.lang.String val)
An alternative means of setting the values of those fields on this object which are modifiable at run-time by builders. |
void |
setXGridSize(int x)
Sets the total width of this grid. |
void |
setYGridSize(int y)
Sets the total height of this grid. |
void |
tryFillInExtraneousExternal(WorldMap.CrossExit EX,
Exit ox)
|
int |
xGridSize()
Returns the total width of this grid. |
int |
yGridSize()
Returns the total height of this grid |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.planet_ink.coffee_mud.Locales.interfaces.Room |
|---|
addInhabitant, bringMobHere, clearSky, delInhabitant, domainConditions, domainType, fetchFromMOBRoomFavorsItems, fetchFromMOBRoomFavorsMOBs, fetchFromMOBRoomItemExit, fetchFromRoomFavorItems, fetchFromRoomFavorMOBs, fetchInhabitant, fetchInhabitant, fetchInhabitants, fetchPCInhabitant, getArea, getContextName, getExitInDir, getGridParent, getMobility, getPairedExit, getRawExit, getReverseExit, getRoomInDir, giveASky, inhabitants, isHere, isInhabitant, isSameRoom, myResource, numInhabitants, numPCInhabitants, pointsPerMove, rawDoors, recoverRoomStats, resourceChoices, roomDescription, roomID, roomTitle, send, sendOthers, setArea, setGridParent, setRawExit, setResource, setRoomID, show, show, show, show, show, showHappens, showHappens, showOthers, showOthers, showSource, showSource, startItemRejuv, thirstPerRound, toggleMobility |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.ItemPossessor |
|---|
addItem, addItem, delItem, findItem, findItem, findItems, findItems, getItem, isContent, items, moveItemTo, moveItemTo, numItems |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Environmental |
|---|
description, displayText, expirationDate, image, isGeneric, maxRange, minRange, miscTextFormat, name, Name, rawImage, sameAs, setExpirationDate, setImage, setMiscText, setName, text |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Tickable |
|---|
getTickStatus, tick |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.StatsAffecting |
|---|
affectCharState, affectCharStats, affectPhyStats |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.MsgListener |
|---|
executeMsg |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Contingent |
|---|
amDestroyed, isSavable, setSavable |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.CMObject |
|---|
copyOf, initializeClass |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Modifiable |
|---|
getSaveStatIndex, isStat |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Affectable |
|---|
addEffect, addNonUninvokableEffect, basePhyStats, delEffect, effects, fetchEffect, fetchEffect, numEffects, phyStats, recoverPhyStats, setBasePhyStats |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Behavable |
|---|
addBehavior, addScript, behaviors, delBehavior, delScript, fetchBehavior, fetchBehavior, fetchScript, numBehaviors, numScripts, scripts |
| Field Detail |
|---|
protected Room[][] subMap
protected java.lang.String[] descriptions
protected java.lang.String[] displayTexts
protected SVector<WorldMap.CrossExit> gridexits
protected int xsize
protected int ysize
| Constructor Detail |
|---|
public StdGrid()
| Method Detail |
|---|
public java.lang.String ID()
CMObject
ID in interface CMObjectID in class StdRoomprotected void cloneFix(Room E)
cloneFix in class StdRoompublic java.lang.String getGridChildLocaleID()
getGridChildLocaleID in interface GridLocalepublic Room getGridChild(GridZones.XYVector xy)
GridZones
getGridChild in interface GridZonesxy - the x and y coordinate
Room,
GridZones.XYVectorpublic CMObject newInstance()
CMObject
newInstance in interface CMObjectnewInstance in class StdRoompublic void destroy()
Contingent
destroy in interface Contingentdestroy in class StdRoompublic int xGridSize()
GridZones
xGridSize in interface GridZonespublic int yGridSize()
GridZones
yGridSize in interface GridZonespublic void setXGridSize(int x)
GridZones
setXGridSize in interface GridZonesx - the widthpublic void setYGridSize(int y)
GridZones
setYGridSize in interface GridZonesy - the heightpublic GridZones.XYVector getRoomXY(java.lang.String roomID)
GridZones
getRoomXY in interface GridZonesroomID - the roomID of the room to get coordinates for
GridZones.XYVectorpublic GridZones.XYVector getRoomXY(Room room)
GridZones
getRoomXY in interface GridZonesroom - the room to get coordinates for
GridZones.XYVector
public Room prepareRoomInDir(Room fromRoom,
int direction)
prepareRoomInDir in interface RoomprepareRoomInDir in class StdRoom
public Room prepareGridLocale(Room fromRoom,
Room toRoom,
int direction)
prepareGridLocale in interface GridLocalepublic void setDescription(java.lang.String newDescription)
Environmental
setDescription in interface EnvironmentalsetDescription in class StdRoomnewDescription - the basic detail description of this objectpublic void setDisplayText(java.lang.String newDisplayText)
Environmental
setDisplayText in interface EnvironmentalsetDisplayText in class StdRoomnewDisplayText - the string describing how this object looks in the roompublic java.util.Iterator<WorldMap.CrossExit> outerExits()
outerExits in interface GridLocalepublic void addOuterExit(WorldMap.CrossExit x)
addOuterExit in interface GridLocalepublic void delOuterExit(WorldMap.CrossExit x)
delOuterExit in interface GridLocale
public Room getAltRoomFrom(Room loc,
int direction)
protected Room[][] getBuiltGrid()
public Room getRandomGridChild()
GridZones
getRandomGridChild in interface GridZonesRoompublic java.util.List<Room> getAllRooms()
getAllRooms in interface GridLocalepublic final java.util.Iterator<Room> getExistingRooms()
getExistingRooms in interface GridLocale
protected void halfLink(Room room,
Room loc,
int dirCode,
Exit o)
protected Room alternativeLink(Room room,
Room defaultRoom,
int dir)
protected void linkRoom(Room room,
Room loc,
int dirCode,
Exit o,
Exit ao)
protected int[] initCenterRoomXY(int dirCode)
protected int[] initCenterRoomAdjustsXY(int dirCode)
protected Room findCenterRoom(int dirCode)
protected void buildFinalLinks()
public void tryFillInExtraneousExternal(WorldMap.CrossExit EX,
Exit ox)
public void fillInTheExtraneousExternals(Room[][] subMap,
Exit ox)
public void buildGrid()
buildGrid in interface GridLocalepublic boolean isMyGridChild(Room loc)
GridZones
isMyGridChild in interface GridZonesloc - a Room object
Roompublic void clearGrid(Room backHere)
clearGrid in interface GridLocalepublic java.lang.String getGridChildCode(Room loc)
GridZones
getGridChildCode in interface GridZonesloc - a Room object
Room,
GridZones.getGridChild(String)public int getGridChildX(Room loc)
GridZones
getGridChildX in interface GridZonesloc - the Room object
Roompublic int getGridChildY(Room loc)
GridZones
getGridChildY in interface GridZonesloc - the Room object
Roompublic Room getGridChild(java.lang.String childCode)
GridZones
getGridChild in interface GridZoneschildCode - a fully-qualified Room ID for this Room
Room,
GridZones.getGridChildCode(Room)
public Room getGridChild(int x,
int y)
GridZones
getGridChild in interface GridZonesx - the x coordinatey - the y coordinate
Room
protected Room getGridRoom(int x,
int y)
public boolean okMessage(Environmental myHost,
CMMsg msg)
MsgListener
okMessage in interface MsgListenerokMessage in class StdRoommyHost - either the initiator of the event, or the host of this objectmsg - the CMMsg that wants to be executed
CMMsg,
CMMsg.source()public java.lang.String getStat(java.lang.String code)
Modifiable
getStat in interface ModifiablegetStat in class StdRoomcode - the name of the field to read.
Modifiable.getStatCodes()
public void setStat(java.lang.String code,
java.lang.String val)
Modifiable
setStat in interface ModifiablesetStat in class StdRoomcode - the name of the field to setval - the value to set the field toModifiable.getStatCodes()protected int getStdGridCodeNum(java.lang.String code)
public java.lang.String[] getStatCodes()
Modifiable
getStatCodes in interface ModifiablegetStatCodes in class StdRoomModifiable.getStat(String),
Modifiable.setStat(String, String)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||