GOB: Avoid hiding overloaded virtual methods
This commit is contained in:
parent
9bd5e8ff15
commit
765540a5fd
6 changed files with 16 additions and 16 deletions
|
@ -305,7 +305,7 @@ protected:
|
||||||
int getSlot(int32 offset) const;
|
int getSlot(int32 offset) const;
|
||||||
int getSlotRemainder(int32 offset) const;
|
int getSlotRemainder(int32 offset) const;
|
||||||
|
|
||||||
void buildIndex(byte *buffer) const;
|
void buildScreenshotIndex(byte *buffer) const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
uint32 _shotSize;
|
uint32 _shotSize;
|
||||||
|
@ -430,7 +430,7 @@ protected:
|
||||||
int getSlot(int32 offset) const;
|
int getSlot(int32 offset) const;
|
||||||
int getSlotRemainder(int32 offset) const;
|
int getSlotRemainder(int32 offset) const;
|
||||||
|
|
||||||
void buildIndex(byte *buffer) const;
|
void buildScreenshotIndex(byte *buffer) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
File *_file;
|
File *_file;
|
||||||
|
|
|
@ -260,7 +260,7 @@ int SaveLoad_Inca2::ScreenshotHandler::File::getSlotRemainder(int32 offset) cons
|
||||||
return (offset - 80) % 15168;
|
return (offset - 80) % 15168;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SaveLoad_Inca2::ScreenshotHandler::File::buildIndex(byte *buffer) const {
|
void SaveLoad_Inca2::ScreenshotHandler::File::buildScreenshotIndex(byte *buffer) const {
|
||||||
Common::SaveFileManager *saveMan = g_system->getSavefileManager();
|
Common::SaveFileManager *saveMan = g_system->getSavefileManager();
|
||||||
Common::InSaveFile *in;
|
Common::InSaveFile *in;
|
||||||
|
|
||||||
|
@ -306,7 +306,7 @@ bool SaveLoad_Inca2::ScreenshotHandler::load(int16 dataVar, int32 size, int32 of
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create/Fake the index
|
// Create/Fake the index
|
||||||
_file->buildIndex(_index + 40);
|
_file->buildScreenshotIndex(_index + 40);
|
||||||
|
|
||||||
_vm->_inter->_variables->copyFrom(dataVar, _index + offset, size);
|
_vm->_inter->_variables->copyFrom(dataVar, _index + offset, size);
|
||||||
|
|
||||||
|
|
|
@ -367,7 +367,7 @@ int SaveLoad_v3::ScreenshotHandler::File::getSlotRemainder(int32 offset) const {
|
||||||
return ((offset - _shotIndexSize) % _shotSize);
|
return ((offset - _shotIndexSize) % _shotSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SaveLoad_v3::ScreenshotHandler::File::buildIndex(byte *buffer) const {
|
void SaveLoad_v3::ScreenshotHandler::File::buildScreenshotIndex(byte *buffer) const {
|
||||||
Common::SaveFileManager *saveMan = g_system->getSavefileManager();
|
Common::SaveFileManager *saveMan = g_system->getSavefileManager();
|
||||||
Common::InSaveFile *in;
|
Common::InSaveFile *in;
|
||||||
|
|
||||||
|
@ -418,12 +418,12 @@ bool SaveLoad_v3::ScreenshotHandler::load(int16 dataVar, int32 size, int32 offse
|
||||||
|
|
||||||
if (_sShotType == kScreenshotTypeGob3) {
|
if (_sShotType == kScreenshotTypeGob3) {
|
||||||
// Create/Fake the index
|
// Create/Fake the index
|
||||||
_file->buildIndex(_index + 40);
|
_file->buildScreenshotIndex(_index + 40);
|
||||||
// The last 10 bytes are 0
|
// The last 10 bytes are 0
|
||||||
memset(_index + 70, 0, 10);
|
memset(_index + 70, 0, 10);
|
||||||
} else if (_sShotType == kScreenshotTypeLost) {
|
} else if (_sShotType == kScreenshotTypeLost) {
|
||||||
// Create/Fake the index
|
// Create/Fake the index
|
||||||
_file->buildIndex(_index);
|
_file->buildScreenshotIndex(_index);
|
||||||
// The last byte is 0
|
// The last byte is 0
|
||||||
_index[30] = 0;
|
_index[30] = 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,7 +47,7 @@ BackgroundAtmosphere::~BackgroundAtmosphere() {
|
||||||
queueClear();
|
queueClear();
|
||||||
}
|
}
|
||||||
|
|
||||||
void BackgroundAtmosphere::play() {
|
void BackgroundAtmosphere::playBA() {
|
||||||
Common::StackLock slock(_mutex);
|
Common::StackLock slock(_mutex);
|
||||||
|
|
||||||
_queuePos = -1;
|
_queuePos = -1;
|
||||||
|
@ -59,7 +59,7 @@ void BackgroundAtmosphere::play() {
|
||||||
SoundMixer::play(*_queue[_queuePos], 1, 0);
|
SoundMixer::play(*_queue[_queuePos], 1, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void BackgroundAtmosphere::stop() {
|
void BackgroundAtmosphere::stopBA() {
|
||||||
SoundMixer::stop(0);
|
SoundMixer::stop(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -46,8 +46,8 @@ public:
|
||||||
BackgroundAtmosphere(Audio::Mixer &mixer);
|
BackgroundAtmosphere(Audio::Mixer &mixer);
|
||||||
~BackgroundAtmosphere();
|
~BackgroundAtmosphere();
|
||||||
|
|
||||||
void play();
|
void playBA();
|
||||||
void stop();
|
void stopBA();
|
||||||
|
|
||||||
void setPlayMode(PlayMode mode);
|
void setPlayMode(PlayMode mode);
|
||||||
|
|
||||||
|
|
|
@ -648,7 +648,7 @@ void Sound::bgPlay(const char *file, SoundType type) {
|
||||||
|
|
||||||
debugC(1, kDebugSound, "BackgroundAtmosphere: Playing \"%s\"", file);
|
debugC(1, kDebugSound, "BackgroundAtmosphere: Playing \"%s\"", file);
|
||||||
|
|
||||||
_bgatmos->stop();
|
_bgatmos->stopBA();
|
||||||
_bgatmos->queueClear();
|
_bgatmos->queueClear();
|
||||||
|
|
||||||
SoundDesc *sndDesc = new SoundDesc;
|
SoundDesc *sndDesc = new SoundDesc;
|
||||||
|
@ -658,7 +658,7 @@ void Sound::bgPlay(const char *file, SoundType type) {
|
||||||
}
|
}
|
||||||
|
|
||||||
_bgatmos->queueSample(*sndDesc);
|
_bgatmos->queueSample(*sndDesc);
|
||||||
_bgatmos->play();
|
_bgatmos->playBA();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Sound::bgPlay(const char *base, const char *ext, SoundType type, int count) {
|
void Sound::bgPlay(const char *base, const char *ext, SoundType type, int count) {
|
||||||
|
@ -667,7 +667,7 @@ void Sound::bgPlay(const char *base, const char *ext, SoundType type, int count)
|
||||||
|
|
||||||
debugC(1, kDebugSound, "BackgroundAtmosphere: Playing \"%s\" (%d)", base, count);
|
debugC(1, kDebugSound, "BackgroundAtmosphere: Playing \"%s\" (%d)", base, count);
|
||||||
|
|
||||||
_bgatmos->stop();
|
_bgatmos->stopBA();
|
||||||
_bgatmos->queueClear();
|
_bgatmos->queueClear();
|
||||||
|
|
||||||
int length = strlen(base) + 7;
|
int length = strlen(base) + 7;
|
||||||
|
@ -684,7 +684,7 @@ void Sound::bgPlay(const char *base, const char *ext, SoundType type, int count)
|
||||||
delete sndDesc;
|
delete sndDesc;
|
||||||
}
|
}
|
||||||
|
|
||||||
_bgatmos->play();
|
_bgatmos->playBA();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Sound::bgStop() {
|
void Sound::bgStop() {
|
||||||
|
@ -693,7 +693,7 @@ void Sound::bgStop() {
|
||||||
|
|
||||||
debugC(1, kDebugSound, "BackgroundAtmosphere: Stopping playback");
|
debugC(1, kDebugSound, "BackgroundAtmosphere: Stopping playback");
|
||||||
|
|
||||||
_bgatmos->stop();
|
_bgatmos->stopBA();
|
||||||
_bgatmos->queueClear();
|
_bgatmos->queueClear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue