add stubs for openFile closeFile and deleteFile opcodes

svn-id: r6608
This commit is contained in:
Jonathan Gray 2003-02-15 09:39:52 +00:00
parent d054457496
commit abe76691bc
2 changed files with 28 additions and 3 deletions

View File

@ -366,6 +366,9 @@ protected:
void o6_bor();
void o6_band();
void o6_stopTalking();
void o6_openFile();
void o6_closeFile();
void o6_deleteFile();
};
class Scumm_v7 : public Scumm_v6

View File

@ -314,13 +314,13 @@ void Scumm_v6::setupOpcodes()
OPCODE(o6_bor),
/* D8 */
OPCODE(o6_isRoomScriptRunning),
OPCODE(o6_invalid),
OPCODE(o6_invalid),
OPCODE(o6_closeFile),
OPCODE(o6_openFile),
OPCODE(o6_invalid),
/* DC */
OPCODE(o6_invalid),
OPCODE(o6_invalid),
OPCODE(o6_invalid),
OPCODE(o6_deleteFile),
OPCODE(o6_invalid),
/* E0 */
OPCODE(o6_invalid),
@ -2904,6 +2904,28 @@ void Scumm_v6::o6_stopTalking() {
warning("o6_stopTalking: stub");
}
void Scumm_v6::o6_openFile() {
int a, b, len;
a = pop();
len = resStrLen(_scriptPointer);
warning("stub o6_openFile(\"%s\", %d)", _scriptPointer, a);
_scriptPointer += len + 1;
// -1 open failed, otherwise file handle?
push(0);
}
void Scumm_v6::o6_closeFile() {
// pop'd variable should be that pushed in o6_openFile()
warning("stub o6_closeFile(%d)", pop());
}
void Scumm_v6::o6_deleteFile() {
int len;
len = resStrLen(_scriptPointer);
warning("stub o6_deleteFile(\"%s\")", _scriptPointer);
_scriptPointer += len + 1;
}
void Scumm_v6::decodeParseString(int m, int n)
{
byte b;