com.planet_ink.coffee_mud.MOBS
Class Dragon
java.lang.Object
com.planet_ink.coffee_mud.MOBS.StdMOB
com.planet_ink.coffee_mud.MOBS.Dragon
- All Implemented Interfaces:
- AbilityContainer, Affectable, Behavable, CMObject, Combatant, Contingent, DBIdentifiable, Environmental, FactionMember, Followable<MOB>, ItemCollection, ItemPossessor, Modifiable, MsgListener, MUDCmdProcessor, Physical, PhysicalAgent, Rider, StatsAffecting, Tattooable, Tickable, MOB, java.lang.Cloneable, java.lang.Comparable<CMObject>
- Direct Known Subclasses:
- BlackDragon, BlueDragon, BrassDragon, BronzeDragon, CopperDragon, GoldDragon, GreenDragon, RedDragon, SilverDragon, WhiteDragon
public class Dragon
- extends StdMOB
Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.MOBS.interfaces.MOB |
MOB.Attrib |
Fields inherited from class com.planet_ink.coffee_mud.MOBS.StdMOB |
abilitys, abilityUseCache, abilityUseTrig, affectCharState, affectCharStats, affectPhyStats, affects, ageMinutes, amDead, amDestroyed, amFollowing, atRange, attributesBitmap, baseCharStats, basePhyStats, baseState, behaviors, cachedImageName, charStats, clanAffects, clans, CODES, commandQue, curState, databaseID, description, displayText, experience, expertises, factions, followers, inventory, kickFlag, lastLocation, liegeID, location, maxState, me, miscText, money, moneyVariation, mySession, peaceTime, phyStats, playerStats, possHeldItem, possStartRoom, possWieldedItem, practices, questPoint, racialAffects, rawImageName, recoverAffectP, recoverTickCter, removeFromGame, riding, scripts, soulMate, tattoos, tickAgeCounter, tickStatus, trains, username, victim, wimpHitPoint, worshipCharID, xtraValues |
Method Summary |
protected static int |
determineAge()
|
protected boolean |
digestTastyMorsels()
|
protected int |
DragonAge()
|
protected int |
DragonColor()
|
protected java.lang.StringBuffer |
getAgeDescription(int draconianAge)
|
protected java.lang.StringBuffer |
getColorDescription(int colorVal)
|
java.lang.String |
ID()
The CoffeeMud Java Class ID shared by all instances of
this object. |
DeadBody |
killMeDead(boolean createBody)
Puts this mob in a dead state, removes all temporary effects,
creates a corpse, ends combat, and sends players to their graveyard. |
void |
recoverCharStats()
Causes this mob to recalculate its current char stats by copying the base stats
over and then calling all equipment and spell effects to modify them. |
void |
recoverPhyStats()
This method copies the basePhyStats() object into the phyStats() object, then makes repeated calls to
all surrounding objects with affectPhyStats(Environmental,PhyStats) method. |
void |
setupDragonIfNecessary()
|
boolean |
tick(Tickable ticking,
int tickID)
this is the method which is called periodically by the threading engine. |
protected boolean |
trySwallowWhole()
|
protected boolean |
useBreathWeapon()
|
Methods inherited from class com.planet_ink.coffee_mud.MOBS.StdMOB |
abilities, actions, addAbility, addBehavior, addEffect, addExpertise, addFaction, addFollower, addItem, addItem, addNonUninvokableEffect, addPriorityEffect, addScript, addTattoo, addTattoo, addTattoo, adjustFaction, affectCharState, affectCharStats, affectPhyStats, allAbilities, amActive, amDead, amDestroyed, amFollowing, amUltimatelyFollowing, baseCharStats, basePhyStats, baseState, baseWeight, behaviors, bringToLife, bringToLife, calculateActionCost, canSaveDatabaseID, charStats, clanEffects, clans, clearCommandQueue, cloneFix, commandQueSize, compareTo, confirmLocation, copyFactions, copyOf, curState, databaseID, delAbility, delAllAbilities, delAllBehaviors, delAllEffects, delAllExpertises, delAllItems, delAllScripts, delBehavior, delEffect, delExpertise, delFollower, delItem, delScript, delTattoo, delTattoo, dequeCommand, description, description, destroy, displayText, displayText, dispossess, doCommand, doCommand, eachBehavior, eachEffect, eachItem, eachScript, effects, enqueCommand, enqueCommands, executeMsg, expertises, expirationDate, factions, fetchAbility, fetchAbility, fetchBehavior, fetchBehavior, fetchEffect, fetchEffect, fetchExpertise, fetchFaction, fetchFactionData, fetchFactionRanges, fetchFirstWornItem, fetchFollower, fetchFollower, fetchFollowerOrder, fetchFromInventory, fetchHeldItem, fetchItem, fetchRandomAbility, fetchScript, fetchWieldedItem, fetchWornItems, findAbility, findItem, findItem, findItems, findItems, findTattoo, findTattooStartsWith, fixChannelColors, flagVariableEq, followers, freeWearPositions, genericName, getAbilityUsageCache, getAgeMinutes, getAttributesBitmap, getClanRole, getCodeNum, getCombatant, getDirectionToTarget, getExperience, getExpNeededDelevel, getExpNeededLevel, getExpNextLevel, getExpPrevLevel, getFactionListing, getGroupMembers, getGroupMembersAndRideables, getItem, getLiegeID, getMoney, getMoneyVariation, getMyDeity, getNaturalWeapon, getPeaceTime, getPractices, getQuestPoint, getRandomItem, getRideBuddies, getSaveStatIndex, getStartRoom, getStat, getStatCodes, getTickStatus, getTrains, getVictim, getWearPositions, getWimpHitPoint, getWorshipCharID, hasFaction, hasOnlyGoldInInventory, healthText, image, initializeClass, isAttributeSet, isContent, isEitherOfUsDead, isFollowedBy, isGeneric, isInCombat, isMarriedToLiege, isMine, isMonster, isPermissableToFight, isPlayer, isPossessing, isRacialAbility, isSavable, isStat, items, L, lastTickedDateTime, location, makePeace, maxCarry, maxFollowers, maxItems, maxRange, maxState, mayIFight, mayPhysicallyAttack, minRange, miscTextFormat, moveItemTo, moveItemTo, name, Name, name, newInstance, numAbilities, numAllAbilities, numAllEffects, numBehaviors, numEffects, numFollowers, numItems, numScripts, okMessage, personalEffects, phyStats, playerStats, prequeCommand, prequeCommands, racialEffects, rangeToTarget, rawImage, recoverMaxState, removeFaction, removeFromGame, resetToMaxState, riding, sameAs, scripts, session, setActions, setAgeMinutes, setAttribute, setAttributesBitmap, setBaseCharStats, setBasePhyStats, setBaseState, setClan, setCombatant, setDatabaseID, setDescription, setDisplayText, setExperience, setExpirationDate, setFollowing, setImage, setLiegeID, setLocation, setMiscText, setMoney, setMoneyVariation, setName, setPlayerStats, setPractices, setQuestPoint, setRangeToTarget, setRiding, setSavable, setSession, setSoulMate, setStartRoom, setStat, setTrains, setVictim, setWimpHitPoint, setWorshipCharID, soulMate, tattoos, tell, tell, text, titledName, totalFollowers, willFollowOrdersOf |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
breatheDown
protected int breatheDown
swallowDown
protected int swallowDown
digestDown
protected int digestDown
birthColor
protected int birthColor
birthAge
protected int birthAge
dragonbreath
protected Ability dragonbreath
HATCHLING
public static final int HATCHLING
- See Also:
- Constant Field Values
VERYYOUNG
public static final int VERYYOUNG
- See Also:
- Constant Field Values
YOUNG
public static final int YOUNG
- See Also:
- Constant Field Values
SUBADULT
public static final int SUBADULT
- See Also:
- Constant Field Values
YOUNGADULT
public static final int YOUNGADULT
- See Also:
- Constant Field Values
ADULT
public static final int ADULT
- See Also:
- Constant Field Values
OLD
public static final int OLD
- See Also:
- Constant Field Values
VERYOLD
public static final int VERYOLD
- See Also:
- Constant Field Values
ANCIENT
public static final int ANCIENT
- See Also:
- Constant Field Values
DRAGONCOLORCOUNT
public static final int DRAGONCOLORCOUNT
- See Also:
- Constant Field Values
WHITE
public static final int WHITE
- See Also:
- Constant Field Values
BLACK
public static final int BLACK
- See Also:
- Constant Field Values
BLUE
public static final int BLUE
- See Also:
- Constant Field Values
GREEN
public static final int GREEN
- See Also:
- Constant Field Values
RED
public static final int RED
- See Also:
- Constant Field Values
BRASS
public static final int BRASS
- See Also:
- Constant Field Values
COPPER
public static final int COPPER
- See Also:
- Constant Field Values
BRONZE
public static final int BRONZE
- See Also:
- Constant Field Values
SILVER
public static final int SILVER
- See Also:
- Constant Field Values
GOLD
public static final int GOLD
- See Also:
- Constant Field Values
Stomach
protected Room Stomach
Dragon
public Dragon()
Dragon
public Dragon(int colorValue)
Dragon
public Dragon(int colorValue,
int ageValue)
ID
public java.lang.String ID()
- Description copied from interface:
CMObject
- The CoffeeMud Java Class ID shared by all instances of
this object. Unlike the Java Class name, this method
does not include package information. However, it must
return a String value unique to its class category in
the ClassLoader. Class categories include Libraries, Common,
Areas, Abilities, Behaviors, CharClasses, Commands, Exits
Locales, MOBS, Races, WebMacros, Basic Items, Armor,
Weapons, ClanItems, Tech. The name is typically identical
to the class name.
- Specified by:
ID
in interface CMObject
- Overrides:
ID
in class StdMOB
- Returns:
- the name of this class
DragonColor
protected int DragonColor()
DragonAge
protected int DragonAge()
setupDragonIfNecessary
public void setupDragonIfNecessary()
determineAge
protected static int determineAge()
getAgeDescription
protected java.lang.StringBuffer getAgeDescription(int draconianAge)
getColorDescription
protected java.lang.StringBuffer getColorDescription(int colorVal)
tick
public boolean tick(Tickable ticking,
int tickID)
- Description copied from interface:
Tickable
- this is the method which is called periodically by the threading engine. How often it
is called depends on the parameters passed to the threadding engine when it is submitted
for thread access. Typically the period is once per TIME_TICK period, but that is
determined when the object is submitted to the thread engine.
- Specified by:
tick
in interface Tickable
- Overrides:
tick
in class StdMOB
- Parameters:
ticking
- a reference to this Tickable objecttickID
- the TICKID_ constant describing this periodic call, as defined in Tickable
- Returns:
- true always, unless this object no longer wishes to ever tick again, in which case false
- See Also:
Tickable
,
ServiceEngine
,
TickableGroup
useBreathWeapon
protected boolean useBreathWeapon()
trySwallowWhole
protected boolean trySwallowWhole()
recoverPhyStats
public void recoverPhyStats()
- Description copied from interface:
Affectable
- This method copies the basePhyStats() object into the phyStats() object, then makes repeated calls to
all surrounding objects with affectPhyStats(Environmental,PhyStats) method. Surrounding objects
include the room where the object is located, the Ability objects in the Effects list, the Behaviors
in the behaviors list, and race/charclass/area if applicable. Those methods will then make all necessary
adjustments to the values in the new phyStats() object. When it returns, phyStats() will have a totally
updated object. This method must be called in code whenever the object is placed on the map, or when
anything changes in its environment, such as location, effects, or other states.
- Specified by:
recoverPhyStats
in interface Affectable
- Overrides:
recoverPhyStats
in class StdMOB
- See Also:
Affectable.basePhyStats()
,
Affectable.phyStats()
,
Affectable.addEffect(Ability)
,
Behavable.addBehavior(Behavior)
,
PhyStats
recoverCharStats
public void recoverCharStats()
- Description copied from interface:
MOB
- Causes this mob to recalculate its current char stats by copying the base stats
over and then calling all equipment and spell effects to modify them.
- Specified by:
recoverCharStats
in interface MOB
- Overrides:
recoverCharStats
in class StdMOB
- See Also:
MOB.baseCharStats()
,
MOB.charStats()
,
MOB.setBaseCharStats(CharStats)
digestTastyMorsels
protected boolean digestTastyMorsels()
killMeDead
public DeadBody killMeDead(boolean createBody)
- Description copied from interface:
MOB
- Puts this mob in a dead state, removes all temporary effects,
creates a corpse, ends combat, and sends players to their graveyard.
- Specified by:
killMeDead
in interface MOB
- Overrides:
killMeDead
in class StdMOB
- Parameters:
createBody
- true to create a corpse, false otherwise
- Returns:
- the corpse, if one was created
- See Also:
MOB.amDead()
,
MOB.bringToLife(Room, boolean)
,
MOB.removeFromGame(boolean, boolean)