|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.planet_ink.coffee_mud.Common.DefaultEnvStats
public class DefaultEnvStats
| Field Summary | |
|---|---|
protected java.lang.String[] |
ambiances
|
protected java.lang.String |
replacementName
|
protected double |
Speed
|
protected int[] |
stats
|
| Constructor Summary | |
|---|---|
DefaultEnvStats()
|
|
| Method Summary | |
|---|---|
int |
ability()
Returns the ability level (a secondary level, e.g. |
void |
addAmbiance(java.lang.String ambiance)
Adds an ambiance (extra word, visible field) to the list that are tacked onto the display text of this Environmental. |
java.lang.String[] |
ambiances()
Returns a list of ambiances (extra words, visible fields) that are tacked onto the display text of this Environmental. |
int |
armor()
Returns the defensive capability number of this Environmental. |
int |
attackAdjustment()
Returns the rawcombat attack prowess of this Environmental Usually mobs or weapons |
int |
compareTo(CMObject o)
|
void |
copyInto(EnvStats intoStats)
Copies the internal data of this object into another of kind. |
CMObject |
copyOf()
Similar to Cloneable.clone(), but does its best to make sure that any internal objects to this class are also copyOfed. |
int |
damage()
Returns the maximum damaging ability of this Environmental |
void |
delAmbiance(java.lang.String ambiance)
Removes an ambiance (extra word, visible field) from the list that are tacked onto the display text of this Environmental. |
int |
disposition()
Returns a bitmask for disposition related flags of Environmentals (IS_ constants). |
protected int |
getCodeNum(java.lang.String code)
|
java.lang.String |
getCombatStats()
Returns a single string summary of several important stats from this object. |
int |
getSaveStatIndex()
Returns the index into the stat codes array where extra savable fields begins. |
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 |
height()
Returns the height of this Environmental, in inches |
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 |
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. |
int |
level()
Returns the experience level of the mob, item, exit, Environmental. |
CMObject |
newInstance()
Returns a new instance of this class. |
java.lang.String |
newName()
Returns a modified name for this Environmental, usually null for no change. |
int |
rejuv()
Returns the number of ticks before an Environmental removed from the game (due to death, destruction, or just removal from home) is restored. |
boolean |
sameAs(EnvStats E)
Returns whether the given object is substantially the same as this one |
int |
sensesMask()
Returns a bitmask for sense related flags of mobs (CAN_ constants), or miscellaneous runtime flags for items and other Environmentals (SENSE_ constants). |
void |
setAbility(int newAdjustment)
Sets the ability level (a secondary level, e.g. |
void |
setAllValues(int def)
Sets all the stats in this object to the given value |
void |
setArmor(int newArmor)
Sets the defensive capability number of this Environmental. |
void |
setAttackAdjustment(int newAdjustment)
Sets the rawcombat attack prowess of this Environmental Usually mobs or weapons |
void |
setDamage(int newDamage)
Sets the maximum damaging ability of this Environmental |
void |
setDisposition(int newDisposition)
Sets a bitmask for disposition related flags of Environmentals (IS_ constants). |
void |
setHeight(int newHeight)
Sets the height of this Environmental, in inches |
void |
setLevel(int newLevel)
Sets the experience level of the mob, item, exit, Environmental. |
void |
setName(java.lang.String newName)
Sets a modified name for this Environmental, usually null for no change. |
void |
setRejuv(int newRejuv)
Sets the number of ticks before an Environmental removed from the game (due to death, destruction, or just removal from home) is restored. |
void |
setSensesMask(int newMask)
Sets a bitmask for sense related flags of mobs (CAN_ constants), or miscellaneous runtime flags for items and other Environmentals (SENSE_ constants). |
void |
setSpeed(double newSpeed)
Sets the number of actions this mob can do per tick |
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 |
setWeight(int newWeight)
Sets the weight of this Environmental, in pounds. |
double |
speed()
Returns the number of actions this mob can do per tick. |
int |
weight()
Returns the weight of this Environmental, in pounds. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected int[] stats
protected double Speed
protected java.lang.String replacementName
protected java.lang.String[] ambiances
| Constructor Detail |
|---|
public DefaultEnvStats()
| Method Detail |
|---|
public java.lang.String ID()
CMObject
ID in interface CMObjectpublic void setAllValues(int def)
EnvStats
setAllValues in interface EnvStatsdef - a value to set all the stats topublic int sensesMask()
EnvStats
sensesMask in interface EnvStatsEnvStats.SENSE_ITEMNEVERSAVED,
EnvStats.CAN_NOT_SEE,
EnvStats.setSensesMask(int)public int disposition()
EnvStats
disposition in interface EnvStatsEnvStats.IS_BONUS,
EnvStats.setDisposition(int)public int level()
EnvStats
level in interface EnvStatsEnvStats.setLevel(int)public int ability()
EnvStats
ability in interface EnvStatsEnvStats.setAbility(int)public int rejuv()
EnvStats
rejuv in interface EnvStatsEnvStats.setRejuv(int)public int weight()
EnvStats
weight in interface EnvStatsEnvStats.setWeight(int)public int height()
EnvStats
height in interface EnvStatsEnvStats.setHeight(int)public int armor()
EnvStats
armor in interface EnvStatsEnvStats.setArmor(int)public int damage()
EnvStats
damage in interface EnvStatsEnvStats.setDamage(int)public double speed()
EnvStats
speed in interface EnvStatsEnvStats.setSpeed(double)public int attackAdjustment()
EnvStats
attackAdjustment in interface EnvStatsEnvStats.setAttackAdjustment(int)public java.lang.String newName()
EnvStats
newName in interface EnvStatsEnvStats.setName(String)public java.lang.String[] ambiances()
EnvStats
ambiances in interface EnvStatsEnvStats.addAmbiance(String),
EnvStats.delAmbiance(String)public void setRejuv(int newRejuv)
EnvStats
setRejuv in interface EnvStatsnewRejuv - the new number of ticks before rejuv (0==never)EnvStats.rejuv()public void setLevel(int newLevel)
EnvStats
setLevel in interface EnvStatsnewLevel - the new experience levelEnvStats.level()public void setArmor(int newArmor)
EnvStats
setArmor in interface EnvStatsnewArmor - the defensive capability number of this EnvironmentalEnvStats.armor()public void setDamage(int newDamage)
EnvStats
setDamage in interface EnvStatsnewDamage - the new maximum damaging ability of this EnvironmentalEnvStats.damage()public void setWeight(int newWeight)
EnvStats
setWeight in interface EnvStatsnewWeight - the new weight of this EnvironmentalEnvStats.weight()public void setSpeed(double newSpeed)
EnvStats
setSpeed in interface EnvStatsnewSpeed - the new number of actions this mob can do per tickEnvStats.speed()public void setAttackAdjustment(int newAdjustment)
EnvStats
setAttackAdjustment in interface EnvStatsnewAdjustment - the new raw combat attack prowess of this EnvironmentalEnvStats.attackAdjustment()public void setAbility(int newAdjustment)
EnvStats
setAbility in interface EnvStatsnewAdjustment - the new ability level (or misc integer)EnvStats.ability()public void setDisposition(int newDisposition)
EnvStats
setDisposition in interface EnvStatsnewDisposition - a bitmask of disposition flagsEnvStats.IS_BONUS,
EnvStats.disposition()public void setSensesMask(int newMask)
EnvStats
setSensesMask in interface EnvStatsnewMask - a bitmask made up of SENSE_ constants or CAN_ constantsEnvStats.SENSE_ITEMNEVERSAVED,
EnvStats.CAN_NOT_SEE,
EnvStats.setSensesMask(int)public void setHeight(int newHeight)
EnvStats
setHeight in interface EnvStatsnewHeight - the new height of this Environmental, in inches (0=indeterminate)EnvStats.height()public void setName(java.lang.String newName)
EnvStats
setName in interface EnvStatsnewName - the modified name, or nullEnvStats.newName()public java.lang.String getCombatStats()
EnvStats
getCombatStats in interface EnvStatspublic void addAmbiance(java.lang.String ambiance)
EnvStats
addAmbiance in interface EnvStatsambiance - a new ambiance stringEnvStats.ambiances(),
EnvStats.delAmbiance(String)public void delAmbiance(java.lang.String ambiance)
EnvStats
delAmbiance in interface EnvStatsambiance - the old ambiance stringpublic CMObject newInstance()
CMObject
newInstance in interface CMObjectpublic void initializeClass()
CMObject
initializeClass in interface CMObjectpublic void copyInto(EnvStats intoStats)
EnvStats
copyInto in interface EnvStatsintoStats - another EnvStats object.public CMObject copyOf()
CMObject
copyOf in interface CMObjectpublic int getSaveStatIndex()
CMModifiable
getSaveStatIndex in interface CMModifiableCMModifiable.getStatCodes(),
CMModifiable.getStat(String),
CMModifiable.setStat(String, String)public java.lang.String[] getStatCodes()
CMModifiable
getStatCodes in interface CMModifiableCMModifiable.getStat(String),
CMModifiable.setStat(String, String)public boolean isStat(java.lang.String code)
CMModifiable
isStat in interface CMModifiablecode - the name of the field to read.
CMModifiable.getStatCodes()protected int getCodeNum(java.lang.String code)
public boolean sameAs(EnvStats E)
EnvStats
sameAs in interface EnvStatsE - the EnvStats to compare to
public void setStat(java.lang.String code,
java.lang.String val)
CMModifiable
setStat in interface CMModifiablecode - the name of the field to setval - the value to set the field toCMModifiable.getStatCodes()public java.lang.String getStat(java.lang.String code)
CMModifiable
getStat in interface CMModifiablecode - the name of the field to read.
CMModifiable.getStatCodes()public int compareTo(CMObject o)
compareTo in interface java.lang.Comparable<CMObject>
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||