|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.planet_ink.coffee_mud.Items.Basic.StdItem
com.planet_ink.coffee_mud.Items.Basic.StdContainer
com.planet_ink.coffee_mud.Items.Basic.StdDrink
public class StdDrink
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Items.interfaces.Wearable |
|---|
Wearable.CODES |
| Field Summary | |
|---|---|
protected int |
amountOfLiquidHeld
|
protected int |
amountOfLiquidRemaining
|
protected int |
amountOfThirstQuenched
|
protected long |
decayTime
|
protected boolean |
disappearsAfterDrinking
|
protected int |
liquidType
|
| Fields inherited from class com.planet_ink.coffee_mud.Items.Basic.StdContainer |
|---|
capacity, containType, defaultsClosed, defaultsLocked, hasALid, hasALock, isLocked, isOpen, openDelayTicks |
| Fields inherited from class com.planet_ink.coffee_mud.Items.Basic.StdItem |
|---|
affectPhyStats, affects, baseGoldValue, basePhyStats, behaviors, cachedImageName, CODES, databaseID, description, destroyed, displayText, dispossessionTime, material, me, miscText, myContainer, myUses, myWornCode, name, owner, phyStats, properWornBitmap, rawImageName, riding, scripts, secretIdentity, tickCtr, tickStatus, wornLogicalAnd, xtraValues |
| Fields inherited from interface com.planet_ink.coffee_mud.Items.interfaces.Wearable |
|---|
DEFAULT_WORN_CODES, DEFAULT_WORN_DEPENDENCYGRID, DEFAULT_WORN_DESCS, DEFAULT_WORN_ORDER, DEFAULT_WORN_USUAL_NAMES, DEFAULT_WORN_WEIGHT_POINTS, DEFAULT_WORN_WEIGHTS, FILTER_ANY, FILTER_MOBINVONLY, FILTER_ROOMONLY, FILTER_UNWORNONLY, FILTER_WORNONLY, HIGHEST_WORN_CODE, IN_INVENTORY, WORN_ABOUT_BODY, WORN_ARMS, WORN_BACK, WORN_EARS, WORN_EYES, WORN_FEET, WORN_FLOATING_NEARBY, WORN_HANDS, WORN_HEAD, WORN_HELD, WORN_LEFT_FINGER, WORN_LEFT_WRIST, WORN_LEGS, WORN_MOUTH, WORN_NECK, WORN_RIGHT_FINGER, WORN_RIGHT_WRIST, WORN_TORSO, WORN_WAIST, WORN_WIELD |
| Fields inherited from interface com.planet_ink.coffee_mud.Items.interfaces.Container |
|---|
CONTAIN_ANYTHING, CONTAIN_BODIES, CONTAIN_CAGED, CONTAIN_CLOTHES, CONTAIN_COINS, CONTAIN_DAGGERS, CONTAIN_DESCS, CONTAIN_DRINKABLES, CONTAIN_EATABLES, CONTAIN_FOOTWEAR, CONTAIN_KEYS, CONTAIN_LIQUID, CONTAIN_ONEHANDWEAPONS, CONTAIN_OTHERWEAPONS, CONTAIN_RAWMATERIALS, CONTAIN_READABLES, CONTAIN_SCROLLS, CONTAIN_SMOKEABLES, CONTAIN_SSCOMPONENTS, CONTAIN_SWORDS |
| Constructor Summary | |
|---|---|
StdDrink()
|
|
| Method Summary | |
|---|---|
int |
amountTakenToFillMe(Drink theSource)
Given the liquid source, the amount of liquid which would need to be taken from the source liquid source to fill up THIS liquid source. |
boolean |
containsDrink()
Whether this liquid container still contains any liquid. |
long |
decayTime()
The time, in milliseconds, when this will rot. |
boolean |
disappearsAfterDrinking()
Settable only internally, this method returns whether this entire object is destroyed immediately after it is drank from -- like a potion. |
void |
executeMsg(Environmental myHost,
CMMsg msg)
The general message event handler for the object. |
java.lang.String |
ID()
The CoffeeMud Java Class ID shared by all instances of this object. |
int |
liquidHeld()
The total amount of liquid possible to be contained in this liquid container. |
int |
liquidRemaining()
The amount of liquid remaining in this liquid container. |
int |
liquidType()
The material type of the liquid in this container. |
boolean |
okMessage(Environmental myHost,
CMMsg msg)
The general message event previewer for the object. |
void |
setDecayTime(long time)
Sets the time, in milliseconds, when this will rot. |
void |
setLiquidHeld(int amount)
Sets the total amount of liquid possible to be contained in this liquid container. |
void |
setLiquidRemaining(int amount)
Sets the amount of liquid remaining in this liquid container. |
void |
setLiquidType(int newLiquidType)
Sets the material type of the liquid in this container. |
void |
setThirstQuenched(int amount)
Set the amount of thirst points quenched every time this item is drank from. |
int |
thirstQuenched()
The amount of thirst points quenched every time this item is drank from. |
protected int |
totalDrinkContained()
|
| Methods inherited from class com.planet_ink.coffee_mud.Items.Basic.StdContainer |
|---|
canContain, capacity, containTypes, defaultsClosed, defaultsLocked, emptyPlease, getContents, getDeepContents, hasADoor, hasALock, hasContent, isInside, isLocked, isOpen, keyName, numberOfItems, openDelayTicks, recursiveWeight, setCapacity, setContainTypes, setDoorsNLocks, setKeyName, setMiscText, setOpenDelayTicks, tick |
| 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.Item |
|---|
baseGoldValue, container, material, numberOfItems, owner, rawSecretIdentity, recursiveWeight, removeFromOwnerContainer, secretIdentity, setBaseValue, setContainer, setMaterial, setOwner, setSecretIdentity, setUsesRemaining, stopTicking, subjectToWearAndTear, ultimateContainer, usesRemaining, value |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Rider |
|---|
riding, setRiding |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Physical |
|---|
description, displayText, name |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Environmental |
|---|
description, displayText, expirationDate, image, isGeneric, L, maxRange, minRange, miscTextFormat, Name, rawImage, sameAs, setDescription, setDisplayText, 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.Contingent |
|---|
amDestroyed, destroy, isSavable, setSavable |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.CMObject |
|---|
copyOf, initializeClass, newInstance |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Modifiable |
|---|
getSaveStatIndex, getStat, getStatCodes, isStat, setStat |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Affectable |
|---|
addEffect, addNonUninvokableEffect, basePhyStats, delAllEffects, delEffect, eachEffect, effects, fetchEffect, fetchEffect, numEffects, phyStats, recoverPhyStats, setBasePhyStats |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Behavable |
|---|
addBehavior, addScript, behaviors, delAllBehaviors, delAllScripts, delBehavior, delScript, eachBehavior, eachScript, fetchBehavior, fetchBehavior, fetchScript, numBehaviors, numScripts, scripts |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.DBIdentifiable |
|---|
canSaveDatabaseID, databaseID, setDatabaseID |
| Methods inherited from interface com.planet_ink.coffee_mud.Items.interfaces.Wearable |
|---|
amBeingWornProperly, amWearingAt, canWear, compareProperLocations, fitsOn, rawLogicalAnd, rawProperLocationBitmap, rawWornCode, setRawLogicalAnd, setRawProperLocationBitmap, setRawWornCode, unWear, wearAt, wearEvenIfImpossible, wearIfPossible, wearIfPossible, whereCantWear |
| Methods inherited from interface com.planet_ink.coffee_mud.core.interfaces.Readable |
|---|
isReadable, readableText, setReadable, setReadableText |
| Field Detail |
|---|
protected int amountOfThirstQuenched
protected int amountOfLiquidHeld
protected int amountOfLiquidRemaining
protected boolean disappearsAfterDrinking
protected int liquidType
protected long decayTime
| Constructor Detail |
|---|
public StdDrink()
| Method Detail |
|---|
public java.lang.String ID()
CMObject
ID in interface CMObjectID in class StdContainerpublic long decayTime()
Decayable
decayTime in interface DecayableDecayable.setDecayTime(long)public void setDecayTime(long time)
Decayable
setDecayTime in interface Decayabletime - in milliseconds, when this will rot. 0=neverDecayable.decayTime()public int thirstQuenched()
Drink
thirstQuenched in interface DrinkCharStatepublic int liquidHeld()
Drink
liquidHeld in interface Drinkpublic int liquidRemaining()
Drink
liquidRemaining in interface DrinkDrink.liquidHeld()public boolean disappearsAfterDrinking()
Drink
disappearsAfterDrinking in interface Drinkpublic int liquidType()
Drink
liquidType in interface DrinkRawMaterialpublic void setLiquidType(int newLiquidType)
Drink
setLiquidType in interface DrinknewLiquidType - the type of liquid contained hereinRawMaterialpublic void setThirstQuenched(int amount)
Drink
setThirstQuenched in interface Drinkamount - of thirst quenchedCharStatepublic void setLiquidHeld(int amount)
Drink
setLiquidHeld in interface Drinkamount - total liquid contained herein.public void setLiquidRemaining(int amount)
Drink
setLiquidRemaining in interface Drinkamount - amount of liquid remaining in this liquid container.Drink.setLiquidHeld(int)protected int totalDrinkContained()
public boolean containsDrink()
Drink
containsDrink in interface Drink
public boolean okMessage(Environmental myHost,
CMMsg msg)
MsgListener
okMessage in interface MsgListenerokMessage in class StdContainermyHost - either the initiator of the event, or the host of this objectmsg - the CMMsg that wants to be executed
CMMsg,
CMMsg.source()public int amountTakenToFillMe(Drink theSource)
Drink
amountTakenToFillMe in interface DrinktheSource - the liquid source to fill up from
public void executeMsg(Environmental myHost,
CMMsg msg)
MsgListener
executeMsg in interface MsgListenerexecuteMsg in class StdContainermyHost - either the initiator of the event, or the host of this objectmsg - the CMMsg that needs to be executedCMMsg
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||