|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.planet_ink.coffee_mud.Areas.StdBoardableShip
com.planet_ink.coffee_mud.Areas.StdSpaceShip
public class StdSpaceShip
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Items.interfaces.SpaceShip |
|---|
SpaceShip.ShipFlag |
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.core.interfaces.SpaceObject |
|---|
SpaceObject.Distance |
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.core.interfaces.BoundedObject |
|---|
BoundedObject.BoundedCube |
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Areas.interfaces.Area |
|---|
Area.AreaInstanceChild, Area.CompleteRoomEnumerator, Area.RoomComparator, Area.RoomIDComparator, Area.RoomIDEnumerator, Area.State, Area.Stats |
| Field Summary | |
|---|---|
protected int |
atmosphere
|
protected static Climate |
climateObj
|
protected Ability |
gravityFloaterA
|
protected ShipEngine |
lastEngine
|
protected double |
lastEThrust
|
protected TimeClock |
localClock
|
protected int |
mass
|
protected long |
nextStaleCheck
|
protected long |
nextStaleWarn
|
protected double |
omlCoeff
|
protected long |
radius
|
protected SpaceObject |
spaceSource
|
protected java.util.Set<java.lang.String> |
staleAirList
|
| Fields inherited from class com.planet_ink.coffee_mud.Areas.StdBoardableShip |
|---|
affects, amDestroyed, author, basePhyStats, behaviors, blurbFlags, currency, description, displayText, empty, flag, imageName, me, miscText, myRooms, name, parents, phyStats, properRoomIDSet, savedDock, scripts, shipExitCache, shipItem, tickStatus, xtraValues |
| Fields inherited from interface com.planet_ink.coffee_mud.Areas.interfaces.Area |
|---|
FLAG_INSTANCE_CHILD, FLAG_INSTANCE_PARENT, FLAG_THIN, THEME_ALLTHEMES, THEME_BIT_NAMES, THEME_FANTASY, THEME_HEROIC, THEME_INHERIT, THEME_NAMES, THEME_PHRASE, THEME_PHRASE_EXT, THEME_SKILLONLYMASK, THEME_TECHNOLOGY, TIME_PASSIVE_LAPSE |
| Fields inherited from interface com.planet_ink.coffee_mud.core.interfaces.Places |
|---|
ALL_CLIMATE_MASK, ATMOSPHERE_INHERIT, CLIMASK_COLD, CLIMASK_DRY, CLIMASK_HOT, CLIMASK_INHERIT, CLIMASK_NORMAL, CLIMASK_WET, CLIMASK_WINDY, CLIMATE_DESCS, NUM_CLIMATES |
| Constructor Summary | |
|---|---|
StdSpaceShip()
|
|
| Method Summary | |
|---|---|
int[] |
addMaskAndReturn(int[] one,
int[] two)
|
protected boolean |
changeRoomAir(Room R,
Room notifyRoom,
int atmoResource)
|
protected void |
cloneFix(StdBoardableShip ship)
|
long[] |
coordinates()
The current absolute coordinates of the object |
CMObject |
copyOf()
Similar to Cloneable.clone(), but does its best to make sure that any internal objects to this class are also copyOfed. |
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. |
double[] |
direction()
The direction of travel of this object in radians. |
protected void |
doAtmosphereChanges()
|
void |
dockHere(Room roomR)
Designates that this ship is landed and docked in the given planetary room. |
protected void |
doGravityChanges()
|
protected void |
doStaleCheck()
|
void |
executeMsg(Environmental myHost,
CMMsg msg)
The general message event handler for the object. |
double[] |
facing()
The direction of facing of this object in radians. |
long |
flags()
Return basic attributed flag about the area. |
int |
getAtmosphere()
Returns the resource that represents the atmosphere of this area. |
int |
getAtmosphereCode()
Returns the resource (or -1) that represents the atmosphere of this area. |
BoundedObject.BoundedCube |
getBounds()
|
Climate |
getClimateObj()
Returns a reference to the Climate object that represents the current and future weather for this area. |
int |
getClimateType()
Returns a bitmap of the climate for this place. |
int |
getClimateTypeCode()
Returns a bitmap of climate flags for this area which will be used to influence the weather for the area in addition to season and other factors. |
protected Ability |
getGravityFloat()
|
Room |
getIsDocked()
Returns the Room where this ship is docked, or NULL if in space. |
long |
getMass()
Returns the mass of this object, derived from its radius and type, or perhaps from other things. |
double |
getOMLCoeff()
The Outer Mold Line coefficient -- how streamlined are you? |
boolean |
getShipFlag(SpaceShip.ShipFlag flag)
Gets one of the ship flags |
SpaceObject |
getShipSpaceObject()
Space ships are unique in having an Item stand-in for planet-side access, as well as an Area object. |
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. |
int |
getTheme()
Returns the technology level supported by this area. |
int |
getThemeCode()
Returns the technology level supported by this area. |
TimeClock |
getTimeObj()
Returns a reference to the TimeClock object that represents the calendar and date/time for this area. |
java.lang.String |
ID()
The CoffeeMud Java Class ID shared by all instances of this object. |
void |
initializeClass()
Called ONCE after all objects are loaded, but before the map is read in during initialization. |
boolean |
isGeneric()
Whether the fields of this item are set in code, or set by builders. |
boolean |
isStat(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. |
SpaceObject |
knownSource()
The source object from which this space object is travelling from |
SpaceObject |
knownTarget()
If this object is targeting another space object as a destination, this will return it |
protected void |
moveAtmosphereOut(java.util.Set<Room> doneRooms,
Room startRoom,
int atmo)
|
CMObject |
newInstance()
Returns a new instance of this class. |
long |
radius()
The current radius of the object |
double |
roll()
The full 360 orientation of the top of the object in radians. |
void |
setAtmosphere(int resourceCode)
Sets the resource (or -1) that represents the atmosphere of this area. |
void |
setClimateObj(Climate obj)
Sets a reference to the Climate object that represents the current and future weather for this area. |
void |
setClimateType(int newClimateType)
Returns a bitmap of climate flags for this area which will be used to influence the weather for the area in addition to season and other factors. |
void |
setCoords(long[] coords)
Sets the current absolute coordinates of the object |
void |
setDirection(double[] dir)
Sets the direction of travel of this object in radians. |
void |
setDockableItem(Item dockableItem)
When a boardable ship area is created, it is bound to an item that resides in a room when docked, or possibly, always. |
void |
setFacing(double[] dir)
Sets the direction of facing of this object in radians. |
void |
setKnownSource(SpaceObject O)
Sets the source object from which this space object is travelling from |
void |
setKnownTarget(SpaceObject O)
If this object is targeting another space object as a destination, this will set it |
void |
setName(java.lang.String newName)
Sets the raw unmodified name of this object as stored in the database. |
void |
setOMLCoeff(double coeff)
Set the Outer Mold Line coefficient -- how streamlined are you? |
void |
setRadius(long radius)
Set the current radius of the object |
void |
setRoll(double dir)
Sets the full 360 orientation of the top of the object in radians. |
void |
setShipFlag(SpaceShip.ShipFlag flag,
boolean setShipFlag)
Sets one of the ship flags |
void |
setSpeed(double v)
Sets the speed of the object through space |
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 |
setTheme(int level)
Sets the technology level supported by this area. |
void |
setTimeObj(TimeClock obj)
Sets a reference to the TimeClock object that represents the calendar and date/time for this area. |
double |
speed()
The speed of the object through space |
boolean |
tick(Tickable ticking,
int tickID)
this is the method which is called periodically by the threading engine. |
| 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.Items.interfaces.BoardableShip |
|---|
getHomePortID, getShipArea, getShipItem, renameShip, setHomePortID, setShipArea, unDock |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Environmental |
|---|
description, displayText, expirationDate, image, L, maxRange, minRange, miscTextFormat, Name, rawImage, sameAs, setDescription, setDisplayText, setExpirationDate, setImage, setMiscText, text |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Tickable |
|---|
getTickStatus, name |
| 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 |
|---|
okMessage |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Contingent |
|---|
amDestroyed, isSavable, setSavable |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Modifiable |
|---|
getSaveStatIndex |
| Field Detail |
|---|
protected static Climate climateObj
protected volatile ShipEngine lastEngine
protected volatile double lastEThrust
protected volatile int mass
protected SpaceObject spaceSource
protected TimeClock localClock
protected int atmosphere
protected long radius
protected double omlCoeff
protected volatile long nextStaleCheck
protected volatile long nextStaleWarn
protected java.util.Set<java.lang.String> staleAirList
protected Ability gravityFloaterA
| Constructor Detail |
|---|
public StdSpaceShip()
| Method Detail |
|---|
public java.lang.String ID()
CMObject
ID in interface CMObjectID in class StdBoardableShippublic void initializeClass()
CMObject
initializeClass in interface CMObjectinitializeClass in class StdBoardableShippublic Room getIsDocked()
BoardableShip
getIsDocked in interface BoardableShipgetIsDocked in class StdBoardableShippublic void setClimateObj(Climate obj)
Area
setClimateObj in interface AreasetClimateObj in class StdBoardableShipobj - a com.planet_ink.coffee_mud.Common.interfaces.Climate objectClimatepublic Climate getClimateObj()
Area
getClimateObj in interface AreagetClimateObj in class StdBoardableShipClimatepublic double getOMLCoeff()
SpaceShip
getOMLCoeff in interface SpaceShippublic void setOMLCoeff(double coeff)
SpaceShip
setOMLCoeff in interface SpaceShipcoeff - the Outer Mold Line coefficientpublic TimeClock getTimeObj()
Area
getTimeObj in interface AreagetTimeObj in class StdBoardableShipTimeClockpublic void setTimeObj(TimeClock obj)
Area
setTimeObj in interface AreasetTimeObj in class StdBoardableShipobj - a com.planet_ink.coffee_mud.Common.interfaces.TimeClock objectTimeClockpublic int getAtmosphereCode()
Places
getAtmosphereCode in interface PlacesgetAtmosphereCode in class StdBoardableShipRawMaterial.MATERIAL_GASpublic void setAtmosphere(int resourceCode)
Places
setAtmosphere in interface PlacessetAtmosphere in class StdBoardableShipresourceCode - the RawMaterial resource to useRawMaterial.MATERIAL_GASpublic int getAtmosphere()
Places
getAtmosphere in interface PlacesgetAtmosphere in class StdBoardableShipRawMaterial.MATERIAL_GASpublic long radius()
SpaceObject
radius in interface SpaceObjectpublic void setRadius(long radius)
SpaceObject
setRadius in interface SpaceObjectradius - the current radius of the objectpublic long flags()
Area
flags in interface Areaflags in class StdBoardableShipArea.FLAG_THINpublic SpaceObject knownSource()
SpaceObject
knownSource in interface SpaceObjectpublic void setKnownSource(SpaceObject O)
SpaceObject
setKnownSource in interface SpaceObjectO - the source of this objectpublic long[] coordinates()
SpaceObject
coordinates in interface SpaceObjectpublic void setCoords(long[] coords)
SpaceObject
setCoords in interface SpaceObjectcoords - 3 dimensional array of the coordinates in spacepublic double[] direction()
SpaceObject
direction in interface SpaceObjectpublic double roll()
SpaceShip
roll in interface SpaceShippublic void setRoll(double dir)
SpaceShip
setRoll in interface SpaceShipdir - radian for the direction of orientationpublic void setDirection(double[] dir)
SpaceObject
setDirection in interface SpaceObjectdir - 2 dimensional array for the direction of movementpublic double[] facing()
SpaceShip
facing in interface SpaceShippublic void setFacing(double[] dir)
SpaceShip
setFacing in interface SpaceShipdir - 2 dimensional array for the direction of facingpublic double speed()
SpaceObject
speed in interface SpaceObjectpublic void setSpeed(double v)
SpaceObject
setSpeed in interface SpaceObjectv - the speedpublic SpaceObject knownTarget()
SpaceObject
knownTarget in interface SpaceObjectpublic void setKnownTarget(SpaceObject O)
SpaceObject
setKnownTarget in interface SpaceObjectO - the target destination
public void setShipFlag(SpaceShip.ShipFlag flag,
boolean setShipFlag)
SpaceShip
setShipFlag in interface SpaceShipflag - the flag to set or clearsetShipFlag - the flag valueSpaceShip.ShipFlag,
SpaceShip.getShipFlag(ShipFlag)public boolean getShipFlag(SpaceShip.ShipFlag flag)
SpaceShip
getShipFlag in interface SpaceShipflag - the flag to set or clear
SpaceShip.ShipFlag,
SpaceShip.setShipFlag(ShipFlag, boolean)public void setDockableItem(Item dockableItem)
BoardableShip
setDockableItem in interface BoardableShipsetDockableItem in class StdBoardableShipdockableItem - the item that acts as dockable itempublic BoundedObject.BoundedCube getBounds()
getBounds in interface BoundedObjectpublic long getMass()
SpaceObject
getMass in interface SpaceObjectpublic void destroy()
Contingent
destroy in interface Contingentdestroy in class StdBoardableShippublic int getClimateTypeCode()
Places
getClimateTypeCode in interface PlacesgetClimateTypeCode in class StdBoardableShipPlaces.CLIMASK_COLDpublic int getClimateType()
Places
getClimateType in interface PlacesgetClimateType in class StdBoardableShipPlaces.CLIMASK_COLDpublic void setClimateType(int newClimateType)
Places
setClimateType in interface PlacessetClimateType in class StdBoardableShipnewClimateType - a CLIMASK bitmapPlaces.CLIMASK_COLDpublic void setName(java.lang.String newName)
Environmental
setName in interface EnvironmentalsetName in class StdBoardableShipnewName - the raw base name of this object on the map.Environmental.Name()public int getTheme()
Area
getTheme in interface AreagetTheme in class StdBoardableShipArea.THEME_FANTASYpublic int getThemeCode()
Area
getThemeCode in interface AreagetThemeCode in class StdBoardableShipArea.THEME_FANTASYpublic void setTheme(int level)
Area
setTheme in interface AreasetTheme in class StdBoardableShiplevel - the bitmap representing the tech levelArea.THEME_FANTASYpublic CMObject newInstance()
CMObject
newInstance in interface CMObjectnewInstance in class StdBoardableShippublic boolean isGeneric()
Environmental
isGeneric in interface EnvironmentalisGeneric in class StdBoardableShipEnvironmental.text()protected void cloneFix(StdBoardableShip ship)
cloneFix in class StdBoardableShippublic CMObject copyOf()
CMObject
copyOf in interface CMObjectcopyOf in class StdBoardableShip
public void executeMsg(Environmental myHost,
CMMsg msg)
MsgListener
executeMsg in interface MsgListenerexecuteMsg in class StdBoardableShipmyHost - either the initiator of the event, or the host of this objectmsg - the CMMsg that needs to be executedCMMsg
public int[] addMaskAndReturn(int[] one,
int[] two)
protected boolean changeRoomAir(Room R,
Room notifyRoom,
int atmoResource)
protected void moveAtmosphereOut(java.util.Set<Room> doneRooms,
Room startRoom,
int atmo)
protected void doStaleCheck()
protected Ability getGravityFloat()
protected void doGravityChanges()
protected void doAtmosphereChanges()
public boolean tick(Tickable ticking,
int tickID)
Tickable
tick in interface Tickabletick in class StdBoardableShipticking - a reference to this Tickable objecttickID - the TICKID_ constant describing this periodic call, as defined in Tickable
Tickable,
ServiceEngine,
TickableGrouppublic void dockHere(Room roomR)
BoardableShip
dockHere in interface BoardableShipdockHere in class StdBoardableShiproomR - the coordinate toom in which the ship is docked.public SpaceObject getShipSpaceObject()
SpaceShip
getShipSpaceObject in interface SpaceShippublic java.lang.String[] getStatCodes()
Modifiable
getStatCodes in interface ModifiablegetStatCodes in class StdBoardableShipModifiable.getStat(String),
Modifiable.setStat(String, String)public boolean isStat(java.lang.String code)
Modifiable
isStat in interface ModifiableisStat in class StdBoardableShipcode - the name of the field to read.
Modifiable.getStatCodes()public java.lang.String getStat(java.lang.String code)
Modifiable
getStat in interface ModifiablegetStat in class StdBoardableShipcode - 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 StdBoardableShipcode - the name of the field to setval - the value to set the field toModifiable.getStatCodes()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||