diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/zvision/zvision.cpp | 10 | ||||
-rw-r--r-- | engines/zvision/zvision.h | 5 |
2 files changed, 14 insertions, 1 deletions
diff --git a/engines/zvision/zvision.cpp b/engines/zvision/zvision.cpp index 8be85d39d4..9a93259ff4 100644 --- a/engines/zvision/zvision.cpp +++ b/engines/zvision/zvision.cpp @@ -61,7 +61,8 @@ ZVision::ZVision(OSystem *syst, const ZVisionGameDescription *gameDesc) _renderManager(nullptr), _saveManager(nullptr), _stringManager(nullptr), - _cursorManager(nullptr) { + _cursorManager(nullptr), + _aud_id(0) { debug(1, "ZVision::ZVision"); } @@ -182,4 +183,11 @@ Common::String ZVision::generateAutoSaveFileName() { return Common::String::format("%s.auto", _targetName.c_str()); } +int ZVision::getAudioId() { + _aud_id++; + if (_aud_id < 0) + _aud_id = 0; + return _aud_id; +} + } // End of namespace ZVision diff --git a/engines/zvision/zvision.h b/engines/zvision/zvision.h index 10711b1605..e7709283ae 100644 --- a/engines/zvision/zvision.h +++ b/engines/zvision/zvision.h @@ -101,6 +101,9 @@ private: // Clock Clock _clock; + // Audio ID + int _aud_id; + // To prevent allocation every time we process events Common::Event _event; @@ -145,6 +148,8 @@ public: */ void playVideo(Video::VideoDecoder &videoDecoder, const Common::Rect &destRect = Common::Rect(0, 0, 0, 0), bool skippable = true); + int getAudioId(); + Common::String generateSaveFileName(uint slot); Common::String generateAutoSaveFileName(); |