[Scummvm-git-logs] scummvm master -> 154d83dbaaa072564cb5c3c30f1f9e3286c17b0f
rvanlaar
roland at rolandvanlaar.nl
Tue Aug 10 22:58:35 UTC 2021
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
154d83dbaa DIRECTOR: LINGO: marker("str") behaves like label
Commit: 154d83dbaaa072564cb5c3c30f1f9e3286c17b0f
https://github.com/scummvm/scummvm/commit/154d83dbaaa072564cb5c3c30f1f9e3286c17b0f
Author: Roland van Laar (roland at rolandvanlaar.nl)
Date: 2021-08-11T00:56:31+02:00
Commit Message:
DIRECTOR: LINGO: marker("str") behaves like label
When `marker` has a string as input it behaves like `label`.
This is an undocumented lingo features.
It is extensively used in the game the Journeyman Project.
Changed paths:
engines/director/lingo/lingo-builtins.cpp
diff --git a/engines/director/lingo/lingo-builtins.cpp b/engines/director/lingo/lingo-builtins.cpp
index db9aeb8fe2..6a168b14b1 100644
--- a/engines/director/lingo/lingo-builtins.cpp
+++ b/engines/director/lingo/lingo-builtins.cpp
@@ -1891,8 +1891,14 @@ void LB::b_label(int nargs) {
}
void LB::b_marker(int nargs) {
+ // marker functions as label when the input is a string
Datum d = g_lingo->pop();
- int marker = g_lingo->func_marker(d.asInt());
+ int marker;
+ if (d.type == STRING) {
+ marker = g_lingo->func_label(d);
+ } else {
+ marker = g_lingo->func_marker(d.asInt());
+ }
g_lingo->push(marker);
}
More information about the Scummvm-git-logs
mailing list