Skip to content

Commit

Permalink
DIRECTOR: Lingo: Stub for 'menu' command. This completes all D2 commands
Browse files Browse the repository at this point in the history
  • Loading branch information
sev- committed Aug 20, 2016
1 parent 80b8fcf commit 223b7f1
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
11 changes: 11 additions & 0 deletions engines/director/lingo/lingo.cpp
Expand Up @@ -160,6 +160,13 @@ void Lingo::addCode(const char *code, ScriptType type, uint16 id) {

const char *begin, *end;

if (!strncmp(code, "menu:", 5)) {
debugC(2, kDebugLingoCompile, "Parsing menu");
parseMenu(code);

return;
}

// macros and factories have conflicting grammar. Thus we ease life for the parser.
if ((begin = findNextDefinition(code))) {
bool first = true;
Expand Down Expand Up @@ -392,6 +399,10 @@ Common::String *Lingo::toLowercaseMac(Common::String *s) {
return res;
}

void Lingo::parseMenu(const char *code) {
warning("STUB: parseMenu");
}

void Lingo::runTests() {
Common::File inFile;
Common::ArchiveMemberList fsList;
Expand Down
2 changes: 2 additions & 0 deletions engines/director/lingo/lingo.h
Expand Up @@ -431,6 +431,8 @@ class Lingo {

private:
int parse(const char *code);
void parseMenu(const char *code);

void push(Datum d);
Datum pop(void);

Expand Down

0 comments on commit 223b7f1

Please sign in to comment.