ScummVM API documentation
Dragons::DragonsEngine Class Reference
Inheritance diagram for Dragons::DragonsEngine:
Engine

Public Member Functions

void loadCurrentSceneMsf ()
 
 DragonsEngine (OSystem *syst, const DragonsGameDescription *desc)
 
void updateEvents ()
 
Common::Error run () override
 
Common::String getSavegameFilename (int num)
 
Common::Error loadGameState (int slot) override
 
bool canLoadGameStateCurrently (Common::U32String *msg=nullptr) override
 
Common::Error saveGameState (int slot, const Common::String &desc, bool isAutosave) override
 
bool canSaveGameStateCurrently (Common::U32String *msg=nullptr) override
 
void syncSoundSettings () override
 
void updateActorSequences ()
 
void setFlags (uint32 flags)
 
void clearFlags (uint32 flags)
 
uint32 getMultipleFlags (uint32 flags)
 
uint32 getAllFlags ()
 
void setAllFlags (uint32 flags)
 
bool isFlagSet (uint32 flag)
 
bool isUnkFlagSet (uint32 flag)
 
void setUnkFlags (uint32 flags)
 
void clearUnkFlags (uint32 flags)
 
byte * getBackgroundPalette ()
 
DragonINIgetINI (uint32 index)
 
uint16 getVar (uint16 offset)
 
void setVar (uint16 offset, uint16 value)
 
uint16 getCurrentSceneId () const
 
void waitForFrames (uint16 numFrames)
 
void waitForFramesAllowSkip (uint16 numFrames)
 
void playOrStopSound (uint16 soundId)
 
void fadeFromBlack ()
 
void fadeFromBlackExcludingFont ()
 
void fadeFromBlack (uint32 flags)
 
void fadeToBlack ()
 
void fadeToBlackExcludingFont ()
 
void fadeToBlack (uint32 flags)
 
uint16 ipt_img_file_related ()
 
void performAction ()
 
void reset_screen_maybe ()
 
void init ()
 
void loadScene (uint16 sceneId)
 
void reset ()
 
void runSceneUpdaterFunction ()
 
void setSceneUpdateFunction (void(*newUpdateFunction)())
 
void clearSceneUpdateFunction ()
 
void setVsyncUpdateFunction (void(*newUpdateFunction)())
 
bool isVsyncUpdaterFunctionRunning ()
 
void runVsyncUpdaterFunction ()
 
bool isActionButtonPressed ()
 
bool isLeftKeyPressed ()
 
bool isRightKeyPressed ()
 
bool isUpKeyPressed ()
 
bool isDownKeyPressed ()
 
bool isSquareButtonPressed ()
 
bool isTriangleButtonPressed ()
 
bool isCircleButtonPressed ()
 
bool isCrossButtonPressed ()
 
bool isL1ButtonPressed ()
 
bool isR1ButtonPressed ()
 
bool checkForActionButtonRelease ()
 
bool checkForDownKeyRelease ()
 
bool checkForUpKeyRelease ()
 
bool checkForWheelUp ()
 
bool checkForWheelDown ()
 
bool isDebugMode ()
 
uint16 getRand (uint16 max)
 
void setupPalette1 ()
 
bool isInMenu ()
 
void loadingScreenUpdate ()
 
void clearAllText ()
 
uint16 getBigFileTotalRecords ()
 
uint32 getBigFileInfoTblFromDragonEXE ()
 
uint32 getFontOffsetFromDragonEXE ()
 
uint32 getSpeechTblOffsetFromDragonEXE ()
 
uint32 getCutscenePaletteOffsetFromDragonEXE ()
 
uint32 defaultResponseOffsetFromDragonEXE ()
 
uint16 getCursorHandPointerSequenceID ()
 
uint32 getMiniGame3StartingDialog ()
 
uint32 getMiniGame3PickAHatDialog ()
 
uint32 getMiniGame3DataOffset ()
 
uint32 getDialogTextId (uint32 textId)
 
- Public Member Functions inherited from Engine
MetaEnginegetMetaEngine () const
 
void setMetaEngine (MetaEngine *metaEngine)
 
PauseToken pauseEngine ()
 
bool isPaused () const
 
void openMainMenuDialog ()
 
uint32 getTotalPlayTime () const
 
void setTotalPlayTime (uint32 time=0)
 
Common::TimerManagergetTimerManager ()
 
Common::EventManagergetEventManager ()
 
Common::SaveFileManagergetSaveFileManager ()
 
bool existExtractedCDAudioFiles (uint track=1)
 
bool isDataAndCDAudioReadFromSameCD ()
 
void warnMissingExtractedCDAudio ()
 
void handleAutoSave ()
 
void saveAutosaveIfEnabled ()
 
virtual bool canSaveAutosaveCurrently ()
 
virtual int getAutosaveSlot () const
 
 Engine (OSystem *syst)
 
virtual ~Engine ()
 
virtual void initializePath (const Common::FSNode &gamePath)
 
virtual void errorString (const char *buf_input, char *buf_output, int buf_output_size)
 
virtual GUI::DebuggergetDebugger () final
 
void setDebugger (GUI::Debugger *debugger)
 
GUI::DebuggergetOrCreateDebugger ()
 
bool enhancementEnabled (int32 cls)
 
virtual void applyGameSettings ()
 
virtual void flipMute ()
 
virtual Common::String getSaveStateName (int slot) const
 
virtual Common::Error loadGameStream (Common::SeekableReadStream *stream)
 
void setGameToLoadSlot (int slot)
 
virtual Common::Error saveGameStream (Common::WriteStream *stream, bool isAutosave=false)
 
bool saveGameDialog ()
 
bool loadGameDialog ()
 

Static Public Member Functions

static Common::String getSavegameFilename (const Common::String &target, int num)
 
static kReadSaveHeaderError readSaveHeader (Common::SeekableReadStream *in, SaveHeader &header, bool skipThumbnail=true)
 
- Static Public Member Functions inherited from Engine
static void quitGame ()
 
static bool shouldQuit ()
 
static bool warnUserAboutUnsupportedGame (Common::String msg=Common::String())
 
static void errorUnsupportedGame (Common::String extraMsg)
 

Public Attributes

DragonOBD_dragonOBD
 
DragonImg_dragonImg
 
DragonRMS_dragonRMS
 
ActorManager_actorManager
 
DragonINIResource_dragonINIResource
 
FontManager_fontManager
 
ScriptOpcodes_scriptOpcodes
 
Scene_scene
 
uint16 _flickerInitialSceneDirection
 
Inventory_inventory
 
Cursor_cursor
 
Credits_credits
 
Talk_talk
 
SoundManager_sound
 
StrPlayer_strPlayer
 
PaletteCyclingInstruction _paletteCyclingTbl [8]
 
bool _isLoadingDialogAudio
 
uint16 _videoFlags
 
Screen_screen
 
uint16 _sceneId1
 
void(*)() getSceneUpdateFunction ()
 
- Public Attributes inherited from Engine
OSystem_system
 
Audio::Mixer_mixer
 

Protected Member Functions

bool hasFeature (EngineFeature f) const override
 
- Protected Member Functions inherited from Engine
virtual int runDialog (GUI::Dialog &dialog)
 
void defaultSyncSoundSettings ()
 
virtual void pauseEngineIntern (bool pause)
 

Additional Inherited Members

- Public Types inherited from Engine
enum  EngineFeature {
  kSupportsSubtitleOptions, kSupportsReturnToLauncher, kSupportsLoadingDuringRuntime, kSupportsSavingDuringRuntime,
  kSupportsChangingOptionsDuringRuntime, kSupportsArbitraryResolutions, kSupportsHelp, kSupportsQuitDialogOverride
}
 
- Protected Attributes inherited from Engine
Common::TimerManager_timer
 
Common::EventManager_eventMan
 
Common::SaveFileManager_saveFileMan
 
GUI::Dialog_mainMenuDialog
 
const Common::String _targetName
 
int32 _activeEnhancements = kEnhGameBreakingBugFixes
 

Member Function Documentation

◆ hasFeature()

bool Dragons::DragonsEngine::hasFeature ( EngineFeature  f) const
overrideprotectedvirtual

Determine whether the engine supports the specified feature.

Reimplemented from Engine.

◆ run()

Common::Error Dragons::DragonsEngine::run ( )
overridevirtual

Initialize the engine and start its main loop.

Returns
kNoError on success, otherwise an error code.

Implements Engine.

◆ loadGameState()

Common::Error Dragons::DragonsEngine::loadGameState ( int  slot)
overridevirtual

Load a game state.

Parameters
slotThe slot from which a save state should be loaded.
Returns
kNoError on success, otherwise an error code.

Reimplemented from Engine.

◆ canLoadGameStateCurrently()

bool Dragons::DragonsEngine::canLoadGameStateCurrently ( Common::U32String msg = nullptr)
overridevirtual

Indicate whether a game state can be loaded.

Parameters
msgOptional pointer to message explaining why it is disabled

Reimplemented from Engine.

◆ saveGameState()

Common::Error Dragons::DragonsEngine::saveGameState ( int  slot,
const Common::String desc,
bool  isAutosave 
)
overridevirtual

Save a game state.

Parameters
slotThe slot into which the save state should be stored.
descDescription for the save state, entered by the user.
isAutosaveExpected to be true if an autosave is being created.
Returns
kNoError on success, otherwise an error code.

Reimplemented from Engine.

◆ canSaveGameStateCurrently()

bool Dragons::DragonsEngine::canSaveGameStateCurrently ( Common::U32String msg = nullptr)
overridevirtual

Indicate whether a game state can be saved.

Parameters
msgOptional pointer to message explaining why it is disabled

Reimplemented from Engine.

◆ syncSoundSettings()

void Dragons::DragonsEngine::syncSoundSettings ( )
overridevirtual

Notify the engine that the sound settings in the config manager might have changed and that it should adjust any internal volume (and other) values accordingly.

The default implementation sets the volume levels of all mixer sound types according to the config entries of the active domain. When overwriting, call the default implementation first, then adjust the volumes further (if required).

Note
When setting volume levels, respect the "mute" config entry.
The volume for the plain sound type is reset to the maximum volume. If the engine can associate its own value for this type, it needs to overwrite this member and set it accordingly.

Reimplemented from Engine.


The documentation for this class was generated from the following file: