diff options
author | Strangerke | 2019-09-06 21:46:21 +0200 |
---|---|---|
committer | Strangerke | 2019-09-06 21:46:21 +0200 |
commit | caa870bc25e491a18e7338ad22e8f75804b3956f (patch) | |
tree | 21b6300ca2201156727bfb8c82568c6c64c26d50 | |
parent | e1878a372cc7c7a23526cac9baf55b2ff9395f7d (diff) | |
download | scummvm-rg350-caa870bc25e491a18e7338ad22e8f75804b3956f.tar.gz scummvm-rg350-caa870bc25e491a18e7338ad22e8f75804b3956f.tar.bz2 scummvm-rg350-caa870bc25e491a18e7338ad22e8f75804b3956f.zip |
HDB: Fix uninitialized variables in ai_init and menu
-rw-r--r-- | engines/hdb/ai-init.cpp | 32 | ||||
-rw-r--r-- | engines/hdb/menu.cpp | 23 |
2 files changed, 55 insertions, 0 deletions
diff --git a/engines/hdb/ai-init.cpp b/engines/hdb/ai-init.cpp index 0a03d579c7..c8fe629883 100644 --- a/engines/hdb/ai-init.cpp +++ b/engines/hdb/ai-init.cpp @@ -960,6 +960,38 @@ AI::AI() { _youGotY = 306; else _youGotY = g_hdb->_screenHeight - 16; + + _icepSnowballGfxDown = nullptr; + _icepSnowballGfxLeft = nullptr; + _icepSnowballGfxRight = nullptr; + _tileFroglickMiddleUD = nullptr; + for (int i = 0; i < 3; ++i) { + _tileFroglickWiggleUD[i] = nullptr; + _tileFroglickWiggleLeft[i] = nullptr; + _tileFroglickWiggleRight[i] = nullptr; + _gfxDragonBreathe[i] = nullptr; + } + _tileFroglickMiddleLR = nullptr; + _gfxDragonAsleep = nullptr; + for (int i = 0; i < 2; ++i) + _gfxDragonFlap[i] = nullptr; + for (int i = 0; i < 4; ++i) { + _gfxLaserbeamUD[i] = nullptr; + _gfxLaserbeamUDTop[i] = nullptr; + _gfxLaserbeamUDBottom[i] = nullptr; + _gfxLaserbeamLR[i] = nullptr; + _gfxLaserbeamLRLeft[i] = nullptr; + _gfxLaserbeamLRRight[i] = nullptr; + } + _player = nullptr; + _cineAbortable = false; + _cineAborted = false; + _cineAbortFunc = nullptr; + _cineActive = false; + _playerLock = false; + _cameraLock = false; + _cameraX = 0; + _cameraY = 0; } AI::~AI() { diff --git a/engines/hdb/menu.cpp b/engines/hdb/menu.cpp index 4a4bea7d49..c3df5b1f7c 100644 --- a/engines/hdb/menu.cpp +++ b/engines/hdb/menu.cpp @@ -258,6 +258,29 @@ Menu::Menu() { _versionGfx = NULL; _warpGfx = NULL; + + _warpBackoutX = 0; + _warpBackoutY = 0; + _titleCycle = 0; + _titleDelay = 0; + _resumeSong = SONG_NONE; + _rocketY = 0; + _rocketYVel = 0; + _nebulaX = 0; + _nebulaYVel = 0; + _nebulaWhich = 0; + _quitScreen = nullptr; + _quitTimer = 0; + _handangoGfx = nullptr; + _clickDelay = 0; + _saveSlot = 0; + _quitActive = 0; + _optionsXV = 0; + _oBannerY = 0; + _loadOrSave = 0; + _whichKey = 0; + _introSong = SONG_NONE; + _titleSong = SONG_NONE; } Menu::~Menu() { |