aboutsummaryrefslogtreecommitdiff
path: root/sword1/debug.cpp
blob: 3f55a83c89dfc58d1fd613d6f8e269ac9cfee937 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
#include "stdafx.h"
#include "debug.h"
#include "common/util.h"

void SwordDebug::interpretScript(uint32 id, uint32 level, uint32 script, uint32 pc) {
	debug(8, "\nInterpreting %d@%d: script %X from %X", id, level, script, pc);
}

void SwordDebug::callMCode(uint32 mcodeNum, uint32 paramCount, int32 a, int32 b, int32 c, int32 d, int32 e, int32 f) {
	debug(9, "mcode: %s(%d, %d, %d, %d, %d, %d) [%d]", _mCodeNames[mcodeNum], a, b, c, d, e, f, paramCount);
}

const char SwordDebug::_mCodeNames[100][35] = {
	"fnBackground",
	"fnForeground",
	"fnSort",
	"fnNoSprite",
	"fnMegaSet",
	"fnAnim",
	"fnSetFrame",
	"fnFullAnim",
	"fnFullSetFrame",
	"fnFadeDown",
	"fnFadeUp",
	"fnCheckFade",
	"fnSetSpritePalette",
	"fnSetWholePalette",
	"fnSetFadeTargetPalette",
	"fnSetPaletteToFade",
	"fnSetPaletteToCut",
	"fnPlaySequence",
	"fnIdle",
	"fnPause",
	"fnPauseSeconds",
	"fnQuit",
	"fnKillId",
	"fnSuicide",
	"fnNewScript",
	"fnSubScript",
	"fnRestartScript",
	"fnSetBookmark",
	"fnGotoBookmark",
	"fnSendSync",
	"fnWaitSync",
	"cfnClickInteract",
	"cfnSetScript",
	"cfnPresetScript",
	"fnInteract",
	"fnIssueEvent",
	"fnCheckForEvent",
	"fnWipeHands",
	"fnISpeak",
	"fnTheyDo",
	"fnTheyDoWeWait",
	"fnWeWait",
	"fnChangeSpeechText",
	"fnTalkError",
	"fnStartTalk",
	"fnCheckForTextLine",
	"fnAddTalkWaitStatusBit",
	"fnRemoveTalkWaitStatusBit",
	"fnNoHuman",
	"fnAddHuman",
	"fnBlankMouse",
	"fnNormalMouse",
	"fnLockMouse",
	"fnUnlockMouse",
	"fnSetMousePointer",
	"fnSetMouseLuggage",
	"fnMouseOn",
	"fnMouseOff",
	"fnChooser",
	"fnEndChooser",
	"fnStartMenu",
	"fnEndMenu",
	"cfnReleaseMenu",
	"fnAddSubject",
	"fnAddObject",
	"fnRemoveObject",
	"fnEnterSection",
	"fnLeaveSection",
	"fnChangeFloor",
	"fnWalk",
	"fnTurn",
	"fnStand",
	"fnStandAt",
	"fnFace",
	"fnFaceXy",
	"fnIsFacing",
	"fnGetTo",
	"fnGetToError",
	"fnGetPos",
	"fnGetGamepadXy",
	"fnPlayFx",
	"fnStopFx",
	"fnPlayMusic",
	"fnStopMusic",
	"fnInnerSpace",
	"fnRandom",
	"fnSetScreen",
	"fnPreload",
	"fnCheckCD",
	"fnRestartGame",
	"fnQuitGame",
	"fnDeathScreen",
	"fnSetParallax",
	"fnTdebug",
	"fnRedFlash",
	"fnBlueFlash",
	"fnYellow",
	"fnGreen",
	"fnPurple",
	"fnBlack"
};