Commit Graph
121 Commits
Author SHA1 Message Date
Scott Percival 7a8d4bfeb9 DIRECTOR: LINGO: Add func_goto* logs to kDebugLingoExec 2022-12-09 01:10:57 +01:00
Scott Percival 7c975eff43 DIRECTOR: LINGO: Adjust freezing/thawing behaviour 2022-12-09 01:10:57 +01:00
Scott Percival 3ea7f10467 DIRECTOR: Freeze LingoState instead of using callstack
Previously, the Lingo state would be frozen by persisting the frames on
the bottom of the callstack with a special flag. This required extra
logic to determine whether or not the callstack was intended to be empty
after execution finished, with some complex edge cases.

The new approach is to swap out the LingoState object on the window,
meaning that an empty callstack always signifies execution has completed.
It remains to be seen if we'll need to track more than one frozen
context; for now it seems to be okay.

Fixes driving to locations in DEVO Presents: Adventures of the Smart Patrol.
2022-12-09 01:10:57 +01:00
Roland van Laar bab6f4bcd5 DIRECTOR: LINGO: improve saveMovie
The property saveMovieEnabled is set when a movie needs to be saved when
branching out from said movie.

Changes:
- saveMovie can have an optional filepath: set minArgs to 0
- call saveMovie when updateMovieEnabled is set and another movie is
  opened
2022-03-14 21:42:26 +01:00
Eugene Sandulenko abea37c9bb ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Orgad Shaneh 02cfffcb67 DIRECTOR: Use nullptr
Using clang-tidy modernize-use-nullptr
2021-11-14 15:51:59 +02:00
Roland van Laar 5d45afb18b DIRECTOR: Convert cursor setting into Datum
This fixes two bugs in one go:
- setting a cursor to 0 wasn't possible when a cast+mask cursor was used
- querying a sprite for cast+mask cursor returned 0 instead of the cast
  ids.

Cursors can be set in two ways:
    1) set cursor of sprite X to INT
    2) set cursor of sprite X to [INT, INT]

A `cursor of sprite X` should return the same values that as were used
when setting the cursor.
2021-08-26 12:23:07 +02:00
djsrv 57afb36f24 DIRECTOR: Set cursor to watch when switching movie 2021-08-11 16:31:50 -04:00
djsrv 02aace0598 DIRECTOR: Use ':' as directory separator 2021-08-07 10:44:37 +02:00
djsrv 19dab8f130 DIRECTOR: Set cursors per-movie, not globally 2021-08-06 01:11:49 -04:00
djsrv 8a9b1cd09c DIRECTOR: Give each window its own sound manager
This Should prevent conflicts between the sound channels of movies
running in parallel.
2021-07-27 22:42:09 -04:00
djsrv fc1831a462 DIRECTOR: LINGO: Replace _hasFrozenContext
This fixes https://trello.com/c/bucHPI2F/429-majestic-regression
hasFrozenContext is now a function which checks the call stack for
frozen contexts. Not updating this variable manually leaves less room
for error.
2021-07-26 12:59:06 -04:00
djsrv 44ad31a043 DIRECTOR: LINGO: Only freeze one context at a time 2021-07-21 20:41:36 -04:00
djsrv e2a34fccc1 DIRECTOR: LINGO: Temporarily freeze script context in func_goto 2021-07-21 18:27:05 -04:00
djsrv dd58b445f2 DIRECTOR: LINGO: Clean up func_goto
All those returns made things confusing, and _skipFrameAdvance wasn't
getting set when the movie was non-VOID.
2021-07-21 18:27:05 -04:00
djsrv 3db07c71ab DIRECTOR: LINGO: Fix play movie
play(0, "movie name") was being interpreted as play done.
We also didn't store the current movie's name if we're switching movies.
2021-07-16 12:53:54 -04:00
ysj1173886760 6de9ff5e42 DIRECTOR: amend function play 2021-07-08 11:05:17 +08:00
ysj1173886760 bb456a64d2 DIRECTOR: switch to next frame when we are calling play done at script channel scripts. 2021-07-08 02:25:11 +02:00
djsrv 615995fdc1 DIRECTOR: Change member refs to use CastMemberID 2021-06-30 22:32:19 -04:00
djsrv 34d8aabc4b DIRECTOR: LINGO: Add DatumType enum 2021-06-22 18:16:53 -04:00
Eugene Sandulenko e27d5ac7fc DIRECTOR: JANITORIAL: Code formatting and unified the namespace end comments 2020-08-21 00:36:19 +02:00
Eugene Sandulenko 5d41772b5e DIRECTOR: Added more comments 2020-08-21 00:36:19 +02:00
djsrv 9c537a8744 DIRECTOR: Rename Stage to more general Window
The stage and windows are the same type of thing, but the stage only
refers to one particular window.
2020-08-04 23:54:09 -04:00
Eugene Sandulenko 234f99395e DIRECTOR: LINGO: Implement b_label() 2020-07-21 23:35:45 +02:00
Nathanael Gentry 4f15cb4af4 DIRECTOR: Introduce Cursor class 2020-07-18 00:37:57 -04:00
djsrv 04f457c46b DIRECTOR: Add _playState to Score 2020-07-09 12:20:39 -04:00
djsrv 57bb4359ef DIRECTOR: LINGO: Implement the visible of window 2020-07-09 00:54:31 -04:00
djsrv a56f400e32 DIRECTOR: Add main stage 2020-07-08 15:19:04 -04:00
djsrv 2c41b3f291 DIRECTOR: Give Stage ownership of movies 2020-07-03 15:55:14 -04:00
djsrv fb39572fd5 DIRECTOR: Move _sharedCast to Movie 2020-07-01 13:24:37 -04:00
Eugene Sandulenko 888e80c9b0 DIRECTOR: LINGO: Reduce header dependency 2020-07-01 18:05:05 +02:00
djsrv 5ae6c34074 DIRECTOR: Separate Movie and Cast from Score 2020-07-01 10:50:31 -04:00
djsrv 3303ab985e DIRECTOR: Rename cast.cpp -> castmember.cpp 2020-07-01 10:50:31 -04:00
Nathanael Gentry c3bfd99d50 DIRECTOR: Render bitmaps with widgets 2020-06-10 15:42:49 +02:00
Scott Percival 2b40cedad7 DIRECTOR: Add builtin b_play 2020-05-25 23:46:01 +08:00
Scott Percival 6bdfc4cfbd DIRECTOR: Replace ad-hoc cast lookups with _vm->getCastMember 2020-05-14 18:09:32 +08:00
Scott Percival 8e0c72291f DIRECTOR: LINGO: Add reference counter to Symbol and Datum 2020-05-14 18:09:32 +08:00
Eugene Sandulenko 08d0eebc54 DIRECTOR: LINGO: Simplified func_cursor(), so MSVC is less confused 2020-05-10 13:38:20 +02:00
Eugene Sandulenko 5f83a7967d DIRECTOR: Rename Datum::toType() to Datum::makeType() as less confusing 2020-04-06 00:45:14 +02:00
Eugene Sandulenko 52a467546b DIRECTOR: Drop '#' from SYMBOL value 2020-04-04 01:29:46 +02:00
Eugene Sandulenko edb2edf3f4 DIRECTOR: Fix memory leaks 2020-04-03 23:33:26 +02:00
Eugene Sandulenko 8a5396e6f5 DIRECTOR: LINGO: Preprocess 'play done' to 'play #done' 2020-03-28 21:51:49 +01:00
Eugene Sandulenko 40d9ed41e2 DIRECTOR: LINGO: preprocess "play done" and remove c_playdone code 2020-03-28 21:33:41 +01:00
Eugene Sandulenko eb7fdaa007 DIRECTOR: LINGO: Fix 'play done' behavior 2020-03-28 21:33:41 +01:00
Eugene Sandulenko 251886124e GRAPHICS: MACGUI: Specify hotspot for custom cursor and fix cursor popping 2020-03-27 02:00:56 +01:00
Eugene Sandulenko 92d207ba0f DIRECTOR: Added sanity checks to func_cursor() 2020-02-26 20:35:02 +01:00
Eugene Sandulenko b505afe041 DIRECTOR: Plug Win->Mac path translator. Warlock-win works! 2020-02-25 10:13:24 +01:00
Eugene Sandulenko edfd14f805 DIRECTOR: Generalized path conversion 2020-02-20 22:56:21 +01:00
Eugene Sandulenko 28d79f7f4e DIRECTOR: LINGO: Fix custom cursor rendering 2020-02-10 15:05:38 +01:00
Eugene Sandulenko 9582cecb22 DIRECTOR: LINGO: Implemented custom cursor setting up 2020-02-10 15:05:38 +01:00