com.planet_ink.coffee_mud.Items.interfaces
Interface Scroll

All Superinterfaces:
Affectable, Behavable, java.lang.Cloneable, CMObject, java.lang.Comparable<CMObject>, Contingent, DBIdentifiable, Environmental, Item, Modifiable, MsgListener, Physical, PhysicalAgent, Readable, Rider, SpellHolder, StatsAffecting, Tickable, Wearable
All Known Implementing Classes:
GenDissertation, GenScroll, ScrollSpell, StdDissertation, StdScroll

public interface Scroll
extends Item, SpellHolder

A scroll is a piece of paper upon which magical spells are written. Scrolls can be used to learn new spells, cast spells directly off them, and copy known spells onto.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.planet_ink.coffee_mud.Items.interfaces.Wearable
Wearable.CODES
 
Field Summary
 
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
 
Method Summary
 boolean isReadableScrollBy(java.lang.String name)
          Checks whether the given mob was the last one to decipher the runes on this scroll through the Read Magic ability, allowing them to freely read the contents of the scroll in the future.
 void readIfAble(MOB mob, java.lang.String spellName)
          Reads the given spell off this scroll for the given mob, if they are able.
 void setReadableScrollBy(java.lang.String name)
          Sets the given mob as the last one to decipher the runes on this scroll through the Read Magic ability, allowing them to freely read the contents of the scroll in the future.
 boolean useTheScroll(Ability A, MOB mob)
          Causes the given mob to cast the given spell/effect through this scroll.
 
Methods inherited from interface com.planet_ink.coffee_mud.Items.interfaces.SpellHolder
getSpellList, getSpells, setSpellList
 
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.CMObject
copyOf, ID, initializeClass, newInstance
 
Methods inherited from interface java.lang.Comparable
compareTo
 
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
 

Method Detail

useTheScroll

boolean useTheScroll(Ability A,
                     MOB mob)
Causes the given mob to cast the given spell/effect through this scroll. This will remove the spell from the scroll.

Parameters:
A - the spell on the scroll to cast
mob - the person reading the spell on the scroll.
Returns:
true if the spell was cast, false otherwise

isReadableScrollBy

boolean isReadableScrollBy(java.lang.String name)
Checks whether the given mob was the last one to decipher the runes on this scroll through the Read Magic ability, allowing them to freely read the contents of the scroll in the future.

Parameters:
name - the name of the player to check
Returns:
true if the player has already read, false otherwise
See Also:
setReadableScrollBy(String)

setReadableScrollBy

void setReadableScrollBy(java.lang.String name)
Sets the given mob as the last one to decipher the runes on this scroll through the Read Magic ability, allowing them to freely read the contents of the scroll in the future.

Parameters:
name - the name of the player to set
See Also:
isReadableScrollBy(String)

readIfAble

void readIfAble(MOB mob,
                java.lang.String spellName)
Reads the given spell off this scroll for the given mob, if they are able. Any errors will be messaged directly to the mob.

Parameters:
mob - the mob who is trying to read
spellName - the spell the mob is trying to read