Affectable
, Behavable
, CMObject
, Contingent
, DBIdentifiable
, Environmental
, Expireable
, Modifiable
, MsgListener
, Physical
, PhysicalAgent
, Readable
, Rider
, StatsAffecting
, Tickable
, Item
, Software
, Technical
, Wearable
, java.lang.Cloneable
, java.lang.Comparable<CMObject>
GenSoftware
public class StdProgram extends StdItem implements Software
Software.SoftwareProcedure, Software.SWServices
Technical.TechCommand, Technical.TechType
Wearable.CODES
Modifier and Type | Field | Description |
---|---|---|
protected Manufacturer |
cachedManufact |
|
protected java.lang.String |
circuitKey |
|
protected java.lang.String |
currentScreen |
|
protected boolean |
isActivated |
|
protected java.lang.String |
manufacturer |
|
protected java.lang.StringBuilder |
nextMsg |
|
protected java.util.Map<Software.SWServices,java.util.Set<Software>> |
svcs |
idConverter
_name, affectPhyStats, affects, baseGoldValue, basePhyStats, behaviors, cachedImageName, CODES, databaseID, description, destroyed, displayText, dispossessionTime, material, me, miscText, myContainer, myUses, myWornCode, owner, phyStats, properWornBitmap, rawImageName, riding, scripts, secretIdentity, tickCtr, tickStatus, wornLogicalAnd, xtraValues
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
Constructor | Description |
---|---|
StdProgram() |
Modifier and Type | Method | Description |
---|---|---|
void |
addScreenMessage(java.lang.String msg) |
Adds a new message to the screen from this program, which
will be received by those monitoring the computer
|
protected boolean |
checkActivate(MOB mob,
java.lang.String message) |
|
protected boolean |
checkDeactivate(MOB mob,
java.lang.String message) |
|
protected boolean |
checkPowerCurrent(int value) |
|
protected boolean |
checkTyping(MOB mob,
java.lang.String message) |
|
java.lang.String |
display(double[] dir) |
|
java.lang.String |
display(long d) |
|
java.lang.String |
display(long[] coords) |
|
java.lang.String |
displayPerSec(long speed) |
|
protected void |
doServiceRequests(MOB mob) |
|
protected java.util.List<java.lang.String[]> |
doServiceTransaction(Software.SWServices service,
java.lang.String[] parms) |
|
void |
executeMsg(Environmental host,
CMMsg msg) |
The general message event handler for the object.
|
protected void |
forceNewMenuRead() |
|
protected void |
forceNewMessageScan() |
|
protected void |
forceUpMenu() |
|
java.lang.String |
genericName() |
Returns a generic name for this object, devoid of its particular
identifying details.
|
java.lang.String |
getActivationMenu() |
Returns the menu name of this software, so that it can
be identified on its parent screen.
|
protected Software.SWServices[] |
getAppreciatedServices() |
|
java.lang.String |
getCurrentScreenDisplay() |
Returns the full screen appearance of this program when
it is activated and on the screen.
|
Manufacturer |
getFinalManufacturer() |
Returns the Manufacturer object of the manufacturer that
made this electrical item.
|
java.lang.String |
getInternalName() |
Returns the internal name of this software.
|
java.lang.String |
getManufacturerName() |
Gets the Manufacturer ID/Name that made this electrical
item.
|
protected Computer |
getMyComputer() |
|
java.lang.String |
getParentMenu() |
The parent menu that this software gets access from.
|
protected java.util.Set<Computer> |
getPeerComputers() |
|
protected java.util.List<Room> |
getPeerComputingRooms() |
|
protected Software.SWServices[] |
getProvidedServices() |
|
protected Software.SWServices[] |
getRequiredServices() |
|
protected java.util.Set<Computer> |
getResponseComputers(Software SW) |
|
java.lang.String |
getScreenMessage() |
Returns any new messages from this program when
it is activated and on the screen.
|
java.lang.String |
getSettings() |
Returns settings specific to this disk.
|
Technical.TechType |
getTechType() |
Returns the tech type enum for this technical object, which describes more
about its functionality, and is in fact a kind of class proxy.
|
protected void |
handleServices(Environmental host,
CMMsg msg) |
|
java.lang.String |
ID() |
The CoffeeMud Java Class ID shared by all instances of
this object.
|
boolean |
isActivationString(java.lang.String word) |
Returns whether the given computer-entry command
should be responded to by THIS software object
on an activation command.
|
boolean |
isCommandString(java.lang.String word,
boolean isActive) |
Returns whether the given computer-entry command
should be responded to by THIS software object
on a WRITE/ENTER command.
|
boolean |
isDeActivationString(java.lang.String word) |
Returns whether the given computer-entry command
should be responded to by THIS software object
on a deactivation command.
|
boolean |
okMessage(Environmental host,
CMMsg msg) |
The general message event previewer for the object.
|
protected void |
onActivate(MOB mob,
java.lang.String message) |
|
protected void |
onDeactivate(MOB mob,
java.lang.String message) |
|
protected void |
onPowerCurrent(int value) |
|
protected void |
onTyping(MOB mob,
java.lang.String message) |
|
protected void |
provideService(Software.SWServices service,
Software S,
java.lang.String[] parms,
CMMsg msg) |
|
protected void |
sendServiceMsg(MOB mob,
java.util.Set<Computer> puters,
CMMsg msg) |
|
protected void |
sendSoftwareRespMsg(Software S,
CMMsg msg) |
|
void |
setCircuitKey(java.lang.String key) |
Software runs on computers, and computers run on power systems.
|
void |
setCurrentScreenDisplay(java.lang.String msg) |
|
void |
setInternalName(java.lang.String name) |
The internal name of this software.
|
void |
setManufacturerName(java.lang.String name) |
Sets the Manufacturer ID/Name that made this electrical
item.
|
void |
setParentMenu(java.lang.String name) |
The parent menu that this software gets access from.
|
void |
setSettings(java.lang.String var) |
Sets settings specific to this disk.
|
void |
setTechLevel(int lvl) |
One of the most important methods in the tech game, this denotes
the level of technology of the specific instance of this item.
|
int |
techLevel() |
One of the most important methods in the tech game, this denotes
the level of technology of the specific instance of this item.
|
protected java.lang.String |
trimColorsAndTrim(java.lang.String s) |
addBehavior, addScript, behaviors, delAllBehaviors, delAllScripts, delBehavior, delScript, eachBehavior, eachScript, fetchBehavior, fetchBehavior, fetchScript, numBehaviors, numScripts, scripts
copyOf, initializeClass, newInstance
canSaveDatabaseID, databaseID, setDatabaseID
baseGoldValue, container, material, numberOfItems, owner, rawSecretIdentity, recursiveWeight, removeFromOwnerContainer, secretIdentity, setBaseValue, setContainer, setMaterial, setOwner, setSecretIdentity, setUsesRemaining, stopTicking, subjectToWearAndTear, ultimateContainer, usesRemaining, value
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isReadable, readableText, setReadable, setReadableText
abilityImbuesMagic, addBehavior, addEffect, addNonUninvokableEffect, addScript, affectCharState, affectCharStats, affectPhyStats, alreadyWornMsg, amBeingWornProperly, amDestroyed, amWearingAt, baseGoldValue, basePhyStats, behaviors, canSaveDatabaseID, canWear, canWearComplete, cloneFix, compareProperLocations, compareTo, container, copyOf, databaseID, delAllBehaviors, delAllEffects, delAllScripts, delBehavior, delEffect, delScript, description, description, destroy, displayText, displayText, eachBehavior, eachEffect, eachScript, effects, expirationDate, fetchBehavior, fetchBehavior, fetchEffect, fetchEffect, fetchScript, fitsOn, getSaveStatIndex, getStat, getStatCodes, getTickStatus, I, image, initializeClass, isGeneric, isReadable, isSavable, isStat, L, material, maxRange, minRange, miscTextFormat, name, name, Name, newInstance, numBehaviors, numberOfItems, numEffects, numScripts, owner, phyStats, rawImage, rawLogicalAnd, rawProperLocationBitmap, rawSecretIdentity, rawWornCode, readableText, recoverPhyStats, recursiveWeight, removeFromOwnerContainer, riding, sameAs, scripts, secretIdentity, setBasePhyStats, setBaseValue, setContainer, setDatabaseID, setDescription, setDisplayText, setExpirationDate, setImage, setMaterial, setMiscText, setName, setOwner, setRawLogicalAnd, setRawProperLocationBitmap, setRawWornCode, setReadable, setReadableText, setRiding, setSavable, setSecretIdentity, setStat, setUsesRemaining, stopTicking, subjectToWearAndTear, tackOns, text, tick, ultimateContainer, unWear, usesRemaining, value, wearAt, wearEvenIfImpossible, wearIfPossible, wearIfPossible, whereCantWear
amBeingWornProperly, amWearingAt, canWear, compareProperLocations, fitsOn, rawLogicalAnd, rawProperLocationBitmap, rawWornCode, setRawLogicalAnd, setRawProperLocationBitmap, setRawWornCode, unWear, wearAt, wearEvenIfImpossible, wearIfPossible, wearIfPossible, whereCantWear
protected java.lang.StringBuilder nextMsg
protected java.lang.String currentScreen
protected java.lang.String manufacturer
protected Manufacturer cachedManufact
protected java.lang.String circuitKey
protected volatile boolean isActivated
protected java.util.Map<Software.SWServices,java.util.Set<Software>> svcs
public java.lang.String ID()
CMObject
public java.lang.String genericName()
Physical
genericName
in interface Physical
genericName
in class StdItem
public void setCircuitKey(java.lang.String key)
Software
setCircuitKey
in interface Software
key
- the circuit keypublic int techLevel()
Technical
techLevel
in interface Technical
TechLibrary.getGlobalTechLevel()
,
Technical.setTechLevel(int)
public void setTechLevel(int lvl)
Technical
setTechLevel
in interface Technical
lvl
- the absolute tech level of this itemTechLibrary.getGlobalTechLevel()
,
Technical.techLevel()
public java.lang.String getParentMenu()
Software
getParentMenu
in interface Software
public void setParentMenu(java.lang.String name)
Software
setParentMenu
in interface Software
name
- parent menu that this software gets access frompublic java.lang.String getInternalName()
Software
getInternalName
in interface Software
public void setInternalName(java.lang.String name)
Software
setInternalName
in interface Software
name
- the internal name of this software.public boolean isActivationString(java.lang.String word)
Software
isActivationString
in interface Software
word
- the computer-entry command enteredpublic boolean isDeActivationString(java.lang.String word)
Software
isDeActivationString
in interface Software
word
- the computer-entry command enteredpublic boolean isCommandString(java.lang.String word, boolean isActive)
Software
isCommandString
in interface Software
word
- the computer-entry commandisActive
- true if the software is already activatedpublic Technical.TechType getTechType()
Technical
getTechType
in interface Technical
Technical.TechType
protected Software.SWServices[] getProvidedServices()
protected Software.SWServices[] getRequiredServices()
protected Software.SWServices[] getAppreciatedServices()
public java.lang.String getSettings()
Software
getSettings
in interface Software
Software.setSettings(String)
public void setSettings(java.lang.String var)
Software
setSettings
in interface Software
var
- the new settingsSoftware.getSettings()
public java.lang.String getActivationMenu()
Software
getActivationMenu
in interface Software
public java.lang.String getCurrentScreenDisplay()
Software
getCurrentScreenDisplay
in interface Software
Software.addScreenMessage(String)
,
Software.getScreenMessage()
public void setCurrentScreenDisplay(java.lang.String msg)
public java.lang.String getScreenMessage()
Software
getScreenMessage
in interface Software
Software.addScreenMessage(String)
,
Software.getCurrentScreenDisplay()
public void addScreenMessage(java.lang.String msg)
Software
addScreenMessage
in interface Software
msg
- the new message for the screenSoftware.getScreenMessage()
,
Software.getCurrentScreenDisplay()
protected void forceUpMenu()
protected void forceNewMessageScan()
protected void forceNewMenuRead()
protected boolean checkActivate(MOB mob, java.lang.String message)
protected boolean checkDeactivate(MOB mob, java.lang.String message)
protected boolean checkTyping(MOB mob, java.lang.String message)
protected boolean checkPowerCurrent(int value)
public boolean okMessage(Environmental host, CMMsg msg)
MsgListener
okMessage
in interface MsgListener
okMessage
in class StdItem
host
- either the initiator of the event, or the host of this objectmsg
- the CMMsg that wants to be executedCMMsg
,
CMMsg.source()
protected Computer getMyComputer()
protected java.util.Set<Computer> getPeerComputers()
protected java.util.List<Room> getPeerComputingRooms()
protected java.util.List<java.lang.String[]> doServiceTransaction(Software.SWServices service, java.lang.String[] parms)
protected void doServiceRequests(MOB mob)
protected void onActivate(MOB mob, java.lang.String message)
protected void onDeactivate(MOB mob, java.lang.String message)
protected void onTyping(MOB mob, java.lang.String message)
protected void onPowerCurrent(int value)
protected void provideService(Software.SWServices service, Software S, java.lang.String[] parms, CMMsg msg)
protected void handleServices(Environmental host, CMMsg msg)
public void executeMsg(Environmental host, CMMsg msg)
MsgListener
executeMsg
in interface MsgListener
executeMsg
in class StdItem
host
- either the initiator of the event, or the host of this objectmsg
- the CMMsg that needs to be executedCMMsg
public java.lang.String display(long d)
public java.lang.String display(long[] coords)
public java.lang.String display(double[] dir)
public java.lang.String displayPerSec(long speed)
public java.lang.String getManufacturerName()
Technical
getManufacturerName
in interface Technical
Technical.setManufacturerName(String)
,
Manufacturer
public void setManufacturerName(java.lang.String name)
Technical
setManufacturerName
in interface Technical
name
- the Manufacturer ID/Name that made thisTechnical.getManufacturerName()
,
Technical.getFinalManufacturer()
,
Manufacturer
public Manufacturer getFinalManufacturer()
Technical
getFinalManufacturer
in interface Technical
Technical.getManufacturerName()
,
Technical.setManufacturerName(String)
,
Manufacturer
protected java.lang.String trimColorsAndTrim(java.lang.String s)