diff options
author | Johannes Schickel | 2005-12-22 18:14:52 +0000 |
---|---|---|
committer | Johannes Schickel | 2005-12-22 18:14:52 +0000 |
commit | c36104ac0ca2f350decd4622a70690f651ce7446 (patch) | |
tree | 403115fbfe7c9c5a13304f2f007882989e3c4c8d /kyra/script_v1.cpp | |
parent | d468c48bdaafcd15cc808115ecc9991d11f44c76 (diff) | |
download | scummvm-rg350-c36104ac0ca2f350decd4622a70690f651ce7446.tar.gz scummvm-rg350-c36104ac0ca2f350decd4622a70690f651ce7446.tar.bz2 scummvm-rg350-c36104ac0ca2f350decd4622a70690f651ce7446.zip |
Completed implementation of processItemDrop
also changed implementation of itemDropDown a bit.
Implemented new opcodes:
- cmd_fadeSpecialPalette
- cmd_setCustomPaletteRange
svn-id: r19828
Diffstat (limited to 'kyra/script_v1.cpp')
-rw-r--r-- | kyra/script_v1.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/kyra/script_v1.cpp b/kyra/script_v1.cpp index 0a8b897ea9..7dbc143b08 100644 --- a/kyra/script_v1.cpp +++ b/kyra/script_v1.cpp @@ -509,7 +509,8 @@ int KyraEngine::cmd_runSceneAnimUntilDone(ScriptState *script) { } int KyraEngine::cmd_fadeSpecialPalette(ScriptState *script) { - warning("STUB: cmd_fadeSpecialPalette"); + debug(3, "cmd_fadeSpecialPalette(0x%X) (%d, %d, %d, %d)", script, stackPos(0), stackPos(1), stackPos(2), stackPos(3)); + _screen->fadeSpecialPalette(stackPos(0), stackPos(1), stackPos(2), stackPos(3)); return 0; } @@ -791,7 +792,10 @@ int KyraEngine::cmd_restoreAllObjectBackgrounds(ScriptState *script) { } int KyraEngine::cmd_setCustomPaletteRange(ScriptState *script) { - warning("STUB: cmd_setCustomPaletteRange"); + debug(3, "cmd_setCustomPaletteRange(0x%X) (%d, %d, %d)", script, stackPos(0), stackPos(1), stackPos(2)); + uint8 *screenPal = _screen->_currentPalette; + memcpy(&screenPal[stackPos(1)*3], _specialPalettes[stackPos(0)], stackPos(2)*3); + _screen->setScreenPalette(screenPal); return 0; } @@ -802,7 +806,7 @@ int KyraEngine::cmd_loadPageFromDisk(ScriptState *script) { int KyraEngine::cmd_customPrintTalkString(ScriptState *script) { if (_features & GF_TALKIE) { - debug(3, "cmd_customPrintTalkString(0x%X) ('%s', %d, %d, %d)", script, stackPosString(1), stackPos(2), stackPos(3), stackPos(4) & 0xFF); + debug(3, "cmd_customPrintTalkString(0x%X) (%d, '%s', %d, %d, %d)", script, stackPos(0), stackPosString(1), stackPos(2), stackPos(3), stackPos(4) & 0xFF); while (snd_voicePlaying() && !_fastMode) { delay(10); } |