Skip to content

Commit

Permalink
DIRECTOR: Lingo: Make 'if' statement functional. Added 'if-else' stat…
Browse files Browse the repository at this point in the history
…ement.
  • Loading branch information
sev- committed Aug 3, 2016
1 parent 34acb99 commit f292060
Show file tree
Hide file tree
Showing 6 changed files with 433 additions and 379 deletions.
8 changes: 7 additions & 1 deletion engines/director/director.cpp
Expand Up @@ -85,7 +85,13 @@ set x = 2 + 3 * (4 / 2)\n\
put x\n", kMovieScript, 2);

_lingo->addCode("set x = 5\n\
if 4 > 3 then x end if\n", kMovieScript, 3);
if x <= 5 then set x = 6 end if\n\
if (x = 5) then\n\
set x = 7\n\
else\n\
set x = 8\n\
end if\n\
put x", kMovieScript, 3);

_lingo->executeScript(kMovieScript, 3);

Expand Down

0 comments on commit f292060

Please sign in to comment.