diff options
author | Eugene Sandulenko | 2014-10-10 14:29:11 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2014-10-10 14:29:11 +0200 |
commit | 44c90d31d74cc6954d7c2efc49f4e6492085e357 (patch) | |
tree | a29cafb68c3fd205142b7e558095f54ac4b37731 /engines | |
parent | a0bdea9286a0e9b97b92fb59537ee3a48903aeea (diff) | |
download | scummvm-rg350-44c90d31d74cc6954d7c2efc49f4e6492085e357.tar.gz scummvm-rg350-44c90d31d74cc6954d7c2efc49f4e6492085e357.tar.bz2 scummvm-rg350-44c90d31d74cc6954d7c2efc49f4e6492085e357.zip |
PRINCE: Fix warning
Diffstat (limited to 'engines')
-rw-r--r-- | engines/prince/prince.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/engines/prince/prince.cpp b/engines/prince/prince.cpp index ae45be6bef..ea4869e48b 100644 --- a/engines/prince/prince.cpp +++ b/engines/prince/prince.cpp @@ -1873,31 +1873,31 @@ void PrinceEngine::drawScreen() { void PrinceEngine::blackPalette() { byte *paletteBackup = (byte *)malloc(256 * 3); - byte *blackPalette = (byte *)malloc(256 * 3); + byte *blackPalette1 = (byte *)malloc(256 * 3); int fadeStep = kFadeStep - 1; for (int i = 0; i < kFadeStep; i++) { _system->getPaletteManager()->grabPalette(paletteBackup, 0, 256); for (int j = 0; j < 256; j++) { - blackPalette[3 * j] = paletteBackup[3 * j] * fadeStep / 4; - blackPalette[3 * j + 1] = paletteBackup[3 * j + 1] * fadeStep / 4; - blackPalette[3 * j + 2] = paletteBackup[3 * j + 2] * fadeStep / 4; + blackPalette1[3 * j] = paletteBackup[3 * j] * fadeStep / 4; + blackPalette1[3 * j + 1] = paletteBackup[3 * j + 1] * fadeStep / 4; + blackPalette1[3 * j + 2] = paletteBackup[3 * j + 2] * fadeStep / 4; } fadeStep--; - _graph->setPalette(blackPalette); + _graph->setPalette(blackPalette1); _system->updateScreen(); Common::Event event; Common::EventManager *eventMan = _system->getEventManager(); eventMan->pollEvent(event); if (shouldQuit()) { free(paletteBackup); - free(blackPalette); + free(blackPalette1); return; } pause(); } free(paletteBackup); - free(blackPalette); + free(blackPalette1); } void PrinceEngine::setPalette(const byte *palette) { |