[Scummvm-cvs-logs] SF.net SVN: scummvm:[51812] tools/branches/gsoc2010-decompiler/decompiler/ kyra/disassembler.cpp
pidgeot at users.sourceforge.net
pidgeot at users.sourceforge.net
Sat Aug 7 01:00:15 CEST 2010
Revision: 51812
http://scummvm.svn.sourceforge.net/scummvm/?rev=51812&view=rev
Author: pidgeot
Date: 2010-08-06 23:00:15 +0000 (Fri, 06 Aug 2010)
Log Message:
-----------
DECOMPILER: Add prefix to Kyra functions
Modified Paths:
--------------
tools/branches/gsoc2010-decompiler/decompiler/kyra/disassembler.cpp
Modified: tools/branches/gsoc2010-decompiler/decompiler/kyra/disassembler.cpp
===================================================================
--- tools/branches/gsoc2010-decompiler/decompiler/kyra/disassembler.cpp 2010-08-06 22:51:25 UTC (rev 51811)
+++ tools/branches/gsoc2010-decompiler/decompiler/kyra/disassembler.cpp 2010-08-06 23:00:15 UTC (rev 51812)
@@ -33,225 +33,225 @@
static FunctionData kyra2FuncDesc[] = {
// 0x00
- { "setCharacterFacingRefresh", "" },
- { "setCharacterPos", "" },
- { "defineObject", "" },
- { "refreshCharacter", "" },
+ { "o2_setCharacterFacingRefresh", "" },
+ { "o2_setCharacterPos", "" },
+ { "o2_defineObject", "" },
+ { "o2_refreshCharacter", "" },
// 0x04
- { "getCharacterX", "" },
- { "getCharacterY", "" },
- { "getCharacterFacing", "" },
- { "getCharacterScene", "" },
+ { "o2_getCharacterX", "" },
+ { "o2_getCharacterY", "" },
+ { "o2_getCharacterFacing", "" },
+ { "o2_getCharacterScene", "" },
// 0x08
- { "setSceneComment", "" },
+ { "o2_setSceneComment", "" },
{ "unk09", "" },
{ "unk0A", "" },
- { "setCharacterAnimFrame", "" },
+ { "o2_setCharacterAnimFrame", "" },
// 0x0c
- { "setCharacterFacingOverwrite", "" },
- { "trySceneChange", "" },
- { "moveCharacter", "" },
- { "customCharacterChat", "" },
+ { "o2_setCharacterFacingOverwrite", "" },
+ { "o2_trySceneChange", "" },
+ { "o2_moveCharacter", "" },
+ { "o2_customCharacterChat", "" },
// 0x10
- { "soundFadeOut", "" },
- { "showChapterMessage", "" },
- { "restoreTalkTextMessageBkgd", "" },
+ { "o2_soundFadeOut", "" },
+ { "o2_showChapterMessage", "" },
+ { "o2_restoreTalkTextMessageBkgd", "" },
{ "unk13", "" },
// 0x14
- { "wsaClose", "" },
- { "backUpScreen", "" },
- { "restoreScreen", "" },
- { "displayWsaFrame", "" },
+ { "o2_wsaClose", "" },
+ { "o2_backUpScreen", "" },
+ { "o2_restoreScreen", "" },
+ { "o2_displayWsaFrame", "" },
// 0x18
- { "displayWsaSequentialFramesLooping", "" },
- { "wsaOpen", "" },
- { "displayWsaSequentialFrames", "" },
- { "displayWsaSequence", "" },
+ { "o2_displayWsaSequentialFramesLooping", "" },
+ { "o2_wsaOpen", "" },
+ { "o2_displayWsaSequentialFrames", "" },
+ { "o2_displayWsaSequence", "" },
// 0x1c
- { "addItemToInventory", "" },
- { "drawShape", "" },
- { "addItemToCurScene", "" },
- { "limitMouseRange", "" },
+ { "o2_addItemToInventory", "" },
+ { "o2_drawShape", "" },
+ { "o2_addItemToCurScene", "" },
+ { "o2_limitMouseRange", "" },
// 0x20
- { "checkForItem", "" },
- { "loadSoundFile", "" },
- { "removeSlotFromInventory", "" },
- { "defineItem", "" },
+ { "o2_checkForItem", "" },
+ { "o2_loadSoundFile", "" },
+ { "o2_removeSlotFromInventory", "" },
+ { "o2_defineItem", "" },
// 0x24
- { "removeItemFromInventory", "" },
- { "countItemInInventory", "" },
- { "countItemsInScene", "" },
- { "queryGameFlag", "" },
+ { "o2_removeItemFromInventory", "" },
+ { "o2_countItemInInventory", "" },
+ { "o2_countItemsInScene", "" },
+ { "o1_queryGameFlag", "" },
// 0x28
- { "resetGameFlag", "" },
- { "setGameFlag", "" },
- { "setHandItem", "" },
- { "removeHandItem", "" },
+ { "o1_resetGameFlag", "" },
+ { "o1_setGameFlag", "" },
+ { "o1_setHandItem", "" },
+ { "o1_removeHandItem", "" },
// 0x2c
- { "getMouseState", "" },
- { "hideMouse", "" },
- { "addSpecialExit", "" },
- { "setMousePos", "" },
+ { "o1_getMouseState", "" },
+ { "o1_hideMouse", "" },
+ { "o2_addSpecialExit", "" },
+ { "o1_setMousePos", "" },
// 0x30
- { "showMouse", "" },
+ { "o1_showMouse", "" },
{ "unk31", "" },
- { "wipeDownMouseItem", "" },
- { "getElapsedSecs", "" },
+ { "o2_wipeDownMouseItem", "" },
+ { "o2_getElapsedSecs", "" },
// 0x34
- { "getTimerDelay", "" },
- { "playSoundEffect", "" },
- { "delaySecs", "" },
- { "delay", "" },
+ { "o2_getTimerDelay", "" },
+ { "o1_playSoundEffect", "" },
+ { "o2_delaySecs", "" },
+ { "o2_delay", "" },
// 0x38
- { "dummy38", "" },
- { "setTimerDelay", "" },
- { "setScaleTableItem", "" },
- { "setDrawLayerTableItem", "" },
+ { "o2_dummy38", "" },
+ { "o2_setTimerDelay", "" },
+ { "o2_setScaleTableItem", "" },
+ { "o2_setDrawLayerTableItem", "" },
// 0x3c
- { "setCharPalEntry", "" },
- { "loadZShapes", "" },
- { "drawSceneShape", "" },
- { "drawSceneShapeOnPage", "" },
+ { "o2_setCharPalEntry", "" },
+ { "o2_loadZShapes", "" },
+ { "o2_drawSceneShape", "" },
+ { "o2_drawSceneShapeOnPage", "" },
// 0x40
- { "disableAnimObject", "" },
- { "enableAnimObject", "" },
- { "dummy42", "" },
- { "loadPalette384", "" },
+ { "o2_disableAnimObject", "" },
+ { "o2_enableAnimObject", "" },
+ { "o2_dummy42", "" },
+ { "o2_loadPalette384", "" },
// 0x44
- { "setPalette384", "" },
- { "restoreBackBuffer", "" },
- { "backUpInventoryGfx", "" },
- { "disableSceneAnim", "" },
+ { "o2_setPalette384", "" },
+ { "o2_restoreBackBuffer", "" },
+ { "o2_backUpInventoryGfx", "" },
+ { "o2_disableSceneAnim", "" },
// 0x48
- { "enableSceneAnim", "" },
- { "restoreInventoryGfx", "" },
- { "setSceneAnimPos2", "" },
- { "update", "" },
+ { "o2_enableSceneAnim", "" },
+ { "o2_restoreInventoryGfx", "" },
+ { "o2_setSceneAnimPos2", "" },
+ { "o2_update", "" },
// 0x4c
{ "unk4C", "" },
- { "fadeScenePal", "" },
- { "dummy4E", "" },
- { "dummy4F", "" },
+ { "o2_fadeScenePal", "" },
+ { "o2_dummy4E", "" },
+ { "o2_dummy4F", "" },
// 0x50
- { "enterNewScene", "" },
- { "switchScene", "" },
- { "getShapeFlag1", "" },
- { "setPathfinderFlag", "" },
+ { "o2_enterNewScene", "" },
+ { "o2_switchScene", "" },
+ { "o2_getShapeFlag1", "" },
+ { "o2_setPathfinderFlag", "" },
// 0x54
- { "getSceneExitToFacing", "" },
- { "setLayerFlag", "" },
- { "setZanthiaPos", "" },
- { "loadMusicTrack", "" },
+ { "o2_getSceneExitToFacing", "" },
+ { "o2_setLayerFlag", "" },
+ { "o2_setZanthiaPos", "" },
+ { "o2_loadMusicTrack", "" },
// 0x58
- { "playWanderScoreViaMap", "" },
- { "playSoundEffect", "" },
- { "setSceneAnimPos", "" },
- { "blockInWalkableRegion", "" },
+ { "o1_playWanderScoreViaMap", "" },
+ { "o1_playSoundEffect", "" },
+ { "o2_setSceneAnimPos", "" },
+ { "o1_blockInWalkableRegion", "" },
// 0x5c
- { "blockOutWalkableRegion", "" },
+ { "o1_blockOutWalkableRegion", "" },
{ "unk5D", "" },
- { "setCauldronState", "" },
- { "showItemString", "" },
+ { "o2_setCauldronState", "" },
+ { "o2_showItemString", "" },
// 0x60
- { "getRand", "" },
- { "isAnySoundPlaying", "" },
- { "setDeathHandler", "" },
- { "setDrawNoShapeFlag", "" },
+ { "o1_getRand", "" },
+ { "o2_isAnySoundPlaying", "" },
+ { "o1_setDeathHandler", "" },
+ { "o2_setDrawNoShapeFlag", "" },
// 0x64
- { "setRunFlag", "" },
- { "showLetter", "" },
+ { "o2_setRunFlag", "" },
+ { "o2_showLetter", "" },
{ "unk66", "" },
- { "fillRect", "" },
+ { "o1_fillRect", "" },
// 0x68
{ "unk68", "" },
{ "unk69", "" },
- { "playFireflyScore", "" },
- { "waitForConfirmationClick", "" },
+ { "o2_playFireflyScore", "" },
+ { "o2_waitForConfirmationClick", "" },
// 0x6c
- { "encodeShape", "" },
- { "defineRoomEntrance", "" },
- { "runAnimationScript", "" },
- { "setSpecialSceneScriptRunTime", "" },
+ { "o2_encodeShape", "" },
+ { "o2_defineRoomEntrance", "" },
+ { "o2_runAnimationScript", "" },
+ { "o2_setSpecialSceneScriptRunTime", "" },
// 0x70
- { "defineSceneAnim", "" },
- { "updateSceneAnim", "" },
- { "updateSceneAnim", "" },
- { "addToSceneAnimPosAndUpdate", "" },
+ { "o2_defineSceneAnim", "" },
+ { "o2_updateSceneAnim", "" },
+ { "o2_updateSceneAnim", "" },
+ { "o2_addToSceneAnimPosAndUpdate", "" },
// 0x74
- { "useItemOnMainChar", "" },
- { "startDialogue", "" },
- { "randomSceneChat", "" },
- { "setDlgIndex", "" },
+ { "o2_useItemOnMainChar", "" },
+ { "o2_startDialogue", "" },
+ { "o2_randomSceneChat", "" },
+ { "o2_setDlgIndex", "" },
// 0x78
- { "getDlgIndex", "" },
- { "defineScene", "" },
- { "addCauldronStateTableEntry", "" },
- { "setCountDown", "" },
+ { "o2_getDlgIndex", "" },
+ { "o2_defineScene", "" },
+ { "o2_addCauldronStateTableEntry", "" },
+ { "o2_setCountDown", "" },
// 0x7c
- { "getCountDown", "" },
- { "dummy7D", "" },
- { "dummy7E", "" },
- { "pressColorKey", "" },
+ { "o2_getCountDown", "" },
+ { "o2_dummy7D", "" },
+ { "o2_dummy7E", "" },
+ { "o2_pressColorKey", "" },
// 0x80
- { "objectChat", "" },
- { "changeChapter", "" },
- { "getColorCodeFlag1", "" },
- { "setColorCodeFlag1", "" },
+ { "o2_objectChat", "" },
+ { "o2_changeChapter", "" },
+ { "o2_getColorCodeFlag1", "" },
+ { "o2_setColorCodeFlag1", "" },
// 0x84
- { "getColorCodeFlag2", "" },
- { "setColorCodeFlag2", "" },
- { "getColorCodeValue", "" },
- { "setColorCodeValue", "" },
+ { "o2_getColorCodeFlag2", "" },
+ { "o2_setColorCodeFlag2", "" },
+ { "o2_getColorCodeValue", "" },
+ { "o2_setColorCodeValue", "" },
// 0x88
- { "countItemInstances", "" },
- { "removeItemFromScene", "" },
- { "initObject", "" },
- { "npcChat", "" },
+ { "o2_countItemInstances", "" },
+ { "o2_removeItemFromScene", "" },
+ { "o2_initObject", "" },
+ { "o2_npcChat", "" },
// 0x8c
- { "deinitObject", "" },
- { "playTimSequence", "" },
- { "makeBookOrCauldronAppear", "" },
- { "setSpecialSceneScriptState", "" },
+ { "o2_deinitObject", "" },
+ { "o2_playTimSequence", "" },
+ { "o2_makeBookOrCauldronAppear", "" },
+ { "o2_setSpecialSceneScriptState", "" },
// 0x90
- { "clearSpecialSceneScriptState", "" },
- { "querySpecialSceneScriptState", "" },
- { "resetInputColorCode", "" },
- { "setHiddenItemsEntry", "" },
+ { "o2_clearSpecialSceneScriptState", "" },
+ { "o2_querySpecialSceneScriptState", "" },
+ { "o2_resetInputColorCode", "" },
+ { "o2_setHiddenItemsEntry", "" },
// 0x94
- { "getHiddenItemsEntry", "" },
- { "mushroomEffect", "" },
- { "wsaClose", "" },
- { "meanWhileScene", "" },
+ { "o2_getHiddenItemsEntry", "" },
+ { "o2_mushroomEffect", "" },
+ { "o2_wsaClose", "" },
+ { "o2_meanWhileScene", "" },
// 0x98
- { "customChat", "" },
- { "customChatFinish", "" },
- { "setupSceneAnimation", "" },
- { "stopSceneAnimation", "" },
+ { "o2_customChat", "" },
+ { "o2_customChatFinish", "" },
+ { "o2_setupSceneAnimation", "" },
+ { "o2_stopSceneAnimation", "" },
// 0x9c
- { "disableTimer", "" },
- { "enableTimer", "" },
- { "setTimerCountdown", "" },
- { "processPaletteIndex", "" },
+ { "o2_disableTimer", "" },
+ { "o2_enableTimer", "" },
+ { "o2_setTimerCountdown", "" },
+ { "o2_processPaletteIndex", "" },
// 0xa0
- { "updateTwoSceneAnims", "" },
- { "getRainbowRoomData", "" },
- { "drawSceneShapeEx", "" },
- { "midiSoundFadeout", "" },
+ { "o2_updateTwoSceneAnims", "" },
+ { "o2_getRainbowRoomData", "" },
+ { "o2_drawSceneShapeEx", "" },
+ { "o2_midiSoundFadeout", "" },
// 0xa4
- { "getSfxDriver", "" },
- { "getVocSupport", "" },
- { "getMusicDriver", "" },
- { "setVocHigh", "" },
+ { "o2_getSfxDriver", "" },
+ { "o2_getVocSupport", "" },
+ { "o2_getMusicDriver", "" },
+ { "o2_setVocHigh", "" },
// 0xa8
- { "getVocHigh", "" },
- { "zanthiaChat", "" },
- { "isVoiceEnabled", "" },
- { "isVoicePlaying", "" },
+ { "o2_getVocHigh", "" },
+ { "o2_zanthiaChat", "" },
+ { "o2_isVoiceEnabled", "" },
+ { "o2_isVoicePlaying", "" },
// 0xac
- { "stopVoicePlaying", "" },
- { "getGameLanguage", "" },
- { "demoFinale", "" },
- { "dummyAF", "" }
+ { "o2_stopVoicePlaying", "" },
+ { "o2_getGameLanguage", "" },
+ { "o2_demoFinale", "" },
+ { "o2_dummyAF", "" }
};
IFFChunk::IFFChunk() {
@@ -407,9 +407,9 @@
break;
case 2:
if (parameter == 0) {
- OPCODE("pushRet", kLoad, 1, false, false);
+ OPCODE("pushRet", kLoad, 1, true, false);
} else if (parameter == 1) {
- OPCODE("pushPos", kSpecial, 0, false, false); // Sets up function call
+ OPCODE_MD("pushPos", kSpecial, 0, true, false, "\xC0"); // Sets up function call
} else {
// Error: invalid parameter halts execution
}
@@ -429,9 +429,9 @@
break;
case 8:
if (parameter == 0) {
- OPCODE("popRet", kStore, -1, false, false);
+ OPCODE("popRet", kStore, -1, true, false);
} else if (parameter == 1) {
- OPCODE("popPos", kReturn, 0, false, false); // Returns from function call
+ OPCODE("popPos", kReturn, 0, true, false); // Returns from function call
} else {
// Error: invalid parameter halts execution
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list