mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
KINGDOM: Supporting returning back to launcher feature
Also adds a _mixer->stopAll() call in the engine's destructor
This commit is contained in:
parent
d2efce1c64
commit
21248eca74
@ -142,6 +142,8 @@ void KingdomGame::initVariables() {
|
||||
}
|
||||
|
||||
KingdomGame::~KingdomGame() {
|
||||
_mixer->stopAll();
|
||||
|
||||
unloadKingArt();
|
||||
|
||||
delete[] _asPtr;
|
||||
@ -149,6 +151,11 @@ KingdomGame::~KingdomGame() {
|
||||
delete _rnd;
|
||||
}
|
||||
|
||||
bool KingdomGame::hasFeature(EngineFeature f) const {
|
||||
return
|
||||
f == kSupportsReturnToLauncher;
|
||||
}
|
||||
|
||||
bool KingdomGame::isDemo() const {
|
||||
return (bool)(_gameDescription->flags & ADGF_DEMO);
|
||||
}
|
||||
|
@ -89,9 +89,10 @@ namespace Kingdom {
|
||||
class KingdomGame : public Engine {
|
||||
public:
|
||||
KingdomGame(OSystem *syst, const ADGameDescription *gameDesc);
|
||||
~KingdomGame();
|
||||
~KingdomGame() override;
|
||||
|
||||
virtual Common::Error run();
|
||||
bool hasFeature(EngineFeature f) const override;
|
||||
Common::Error run() override;
|
||||
|
||||
// Detection related functions
|
||||
const ADGameDescription *_gameDescription;
|
||||
@ -229,8 +230,8 @@ namespace Kingdom {
|
||||
void cursorTypeExit();
|
||||
void saveGame();
|
||||
void restoreGame();
|
||||
virtual Common::Error loadGameState(int slot);
|
||||
virtual Common::Error saveGameState(int slot, const Common::String &desc, bool isAutosave = false);
|
||||
Common::Error loadGameState(int slot) override;
|
||||
Common::Error saveGameState(int slot, const Common::String &desc, bool isAutosave = false) override;
|
||||
Common::String getSavegameFilename(int slot);
|
||||
void writeSavegameHeader(Common::OutSaveFile *out, KingdomSavegameHeader &header);
|
||||
void synchronize(Common::Serializer &s);
|
||||
|
Loading…
Reference in New Issue
Block a user