add some preload call aliases and FlxColor to interp

This commit is contained in:
2025-10-21 16:42:49 -05:00
parent ecb5f6346f
commit 7619e05aab
2 changed files with 10 additions and 0 deletions

View File

@@ -972,6 +972,12 @@
(dictSet interp.globals "Read" hollywoo.Movie.PlayMode.Read)
(dictSet interp.globals "Watch" hollywoo.Movie.PlayMode.Watch)
(localVar colorObj (object))
(doFor =>name color FlxColor.colorLookup
(Reflect.setField colorObj name color))
// TODO fromRGB etc
(dictSet interp.globals "FlxColor" colorObj)
(localFunction :Void handleNext [exp]
(case exp.def
((CallExp (object def (Symbol "commands")) commands)

View File

@@ -138,5 +138,9 @@ class HollywooInterp {
readTable["SETCAMERAZOOM "] = quickReaderMacro("(movie.setCameraZoom $$1 cc)");
readTable["SETCAMERASCROLL "] = quickReaderMacro("(movie.setCameraScroll $$1 cc)");
callAliases["newFlxSet"] = kiss.ReaderExp.ReaderExpDef.Symbol("movie._loadSet");
callAliases["newFlxProp"] = kiss.ReaderExp.ReaderExpDef.Symbol("movie._loadProp");
callAliases["newFlxTextProp"] = kiss.ReaderExp.ReaderExpDef.Symbol("movie.newFlxTextProp");
}
}