Restoreobject
Perform the save, using the filename given in our fname_ parameter, trimmed of quotes.
Restore
:
SystemAction
Superclass Tree (in declaration order)
Restore
SystemAction
IAction
Action
ReplaceRedirector
Redirector
` object`
Summary of Properties
Inherited from SystemAction
:
isRepeatable
timeTaken
turnsTaken
Inherited from IAction
:
againRepeatsParse
Inherited from Action
:
actionFailed
advanceOnFailure
allowAll
extraMessageParams
failCheckMsg
failedActionCountsAsTurn
implicitTimeTaken
isConversational
isImplicit
oldRoom
parentAction
parentAllowAll
preCond
redirectParent
reportImplicitActions
scopeList
spellingPriority
synthParamID
unhides
verifyObj
wasIlluminated
Summary of Methods
askAndRestore
execAction
filePromptFailed
filePromptFailedMsg
performRestore
startupRestore
Inherited from SystemAction
:
afterAction
exec
execCycle
getInputFile
turnSequence
Inherited from IAction
:
execResolvedAction
resolvedObjectsInScope
scoreObjects
setResolvedObjects
Inherited from Action
:
acknowledgeNotifyStatus
addExtraScopeItems
addImplicitTime
advanceTime
announceObject
beforeAction
buildImplicitActionAnnouncement
buildScopeList
checkAction
checkActionPreconditions
commandNotPresent
execGroup
getAll
getAllUnhidden
getMessageParam
implicitAnnouncement
reportAction
setMessageParam
setMessageParams
spPrefix
spSuffix
synthMessageParam
verify
verifyObjRole
wrapObjectsNP
Inherited from ReplaceRedirector
:
redirect
Inherited from Redirector
:
doInstead
doNested
doOtherAction
Properties
includeInUndo
OVERRIDDEN
There’s no point in including this in undo. If the command succeeds, it’s not undoable itself, and there won’t be any undo information in the newly restored state. If the command fails, it won’t make any changes to the game state, so there won’t be anything to undo.
Methods
askAndRestore ( )
Ask for a file and try to restore it. Returns true on success, nil on failure. (Failure could indicate that the user chose to cancel out of the file selector, that we couldn’t find the file to restore, or that the file isn’t a valid saved state file. In any case, we show an appropriate message on failure.)
execAction (cmd)
OVERRIDDEN
no description available
filePromptFailed ( )
error showing the input file dialog (or character-mode equivalent)
filePromptFailedMsg (msg)
error showing the input file dialog, with a system error message
performRestore (fname, code)
Restore a file. ‘code’ is the restoreCode value for the PostRestoreObject notifications. Returns true on success, nil on failure.
startupRestore (fname)
Restore a game on startup. This can be called from mainRestore() to restore a saved game directly as part of loading the game. (Most interpreters provide a way of starting the interpreter directly with a saved game to be restored, skipping the intermediate step of running the game and using a RESTORE command.)
Returns true on success, nil on failure. On failure, the caller should simply exit the program. On success, the caller should start the game running, usually using runGame(), after showing any desired introductory messages.
Adv3Lite Library Reference Manual
Generated on 15/03/2023 from adv3Lite version 1.6.1