Log inGet started
Package

Film.module

README.md

Film

The one entry point of filmRig: Film.play(def) plays a whole film or trailer on this player's screen, built on the engine's cutscene (camera path, fades, skip on keyboard / gamepad / touch, cues that still fire when skipped, local playback per player). A film definition names camera moves, transitions, title cards, a frame shape, a real lens (focal length) and a photographic look, timed events and what happens after the film.

  • Film.play(def | "<film module>", { after?, quality? }) plays now and returns the cutscene playback.
  • Film.cutscene(def) turns a film into a cutscene definition; a film module returns this, so cutscene.play("<module>"), a CutsceneTrigger, the cutscene toolbox and FilmDirector all play it.
  • Film.on(name, fn) / Film.off / Film.emit run world code when the timeline reaches a named event (events = { { t = 32, event = "lanternsLight" } }). Also fired: filmStarted, filmEnded.
  • Film.stop(), Film.skip(), Film.replay(), Film.handBack(), Film.current(), Film.build(def) (dry build, nothing shown), Film.handleCallback(id) (forward UI clicks for the Replay button).
  • Lists: Film.MOVES, Film.TRANSITIONS, Film.TITLES, Film.FRAMES, Film.LENSES, Film.AFTER.

Called by world scripts, scene entrypoints and the FilmDirector component. The package README has the full definition format.