Commit Graph

1198 Commits

Author SHA1 Message Date
Martin Kiewitz
dbdf77660e AGI: Fix disabled look to work properly in menus 2016-02-04 00:55:53 +01:00
Martin Kiewitz
f6c9cffa26 AGI: Add different window frames for Macintosh
Also work on drawCharacter code for SystemUI usage
2016-02-03 22:47:58 +01:00
Martin Kiewitz
0f026c7766 AGI: Add different window frames for Apple IIgs
Only slightly different than on PC
2016-02-03 22:25:52 +01:00
Martin Kiewitz
a9bb8c3a50 AGI: Message box mouse support 2016-02-03 08:27:44 +01:00
Martin Kiewitz
d23871fdd8 AGI: Rename WINDOWRESET to WINDOW_AUTO_CLOSE_TIMER 2016-02-03 04:17:15 +01:00
Martin Kiewitz
3eebf2eb41 AGI: Increase time delay for Apple IIgs
It seems that either Apple IIgs ran very slowly or that its
AGI interpreter didn't do the delays as on all the other platforms.
Further investigation needed
Fixes all sorts of games running now way too fast.
2016-02-03 03:49:37 +01:00
Martin Kiewitz
9a3454393b AGI: Remove unused initialized variable 2016-02-03 03:13:25 +01:00
Martin Kiewitz
cc55cb13d3 AGI: Remove _game.state, not needed anymore 2016-02-03 03:07:50 +01:00
Martin Kiewitz
34117170f2 AGI: Change cycle delay handling, seems to fix GR
Removed pollTimer()
Renamed pause() to wait()
Doing 10 msec delays instead of at least 50 msec per EventProcess
Seems to fix weird Gold Rush ingame timer issue?! bug #4147
2016-02-03 02:40:01 +01:00
Martin Kiewitz
778c1ddb69 AGI: Cycle event processing changed
processEvents() renamed to processScummVMEvents()
mainCycle() renamed to processAGIEvents()
have.key now sets up an inner loop and calls processAGIEvents()
to avoid any further cycle work processing
2016-02-03 02:21:07 +01:00
Martin Kiewitz
c2038e00d0 AGI: Call update screen in have.key for now
Some games call it in an endless loop until a key is returned
2016-02-03 01:47:26 +01:00
Martin Kiewitz
702b66a49d AGI: Make inner loop handlers consistent 2016-02-03 01:41:32 +01:00
Martin Kiewitz
8271058a45 AGI: Implement messageBox() as inner loop
Also remove _game.keypress, _game.msgBoxTicks
2016-02-03 01:32:57 +01:00
Martin Kiewitz
9fecbe58a1 AGI: Remove Gold Rush workaround, no longer needed 2016-02-03 01:03:40 +01:00
Martin Kiewitz
563d890991 AGI: Fix regression of have.key changes
original commit 8269a94bcd
Now hopefully properly implemented.
Adjusted a few more inaccuracies
(we set v19 to 0, where we shouldn't have)
2016-02-03 00:26:35 +01:00
Martin Kiewitz
920bea0fd9 AGI: add drawCharacterOnDisplay() 2016-02-02 23:27:13 +01:00
Martin Kiewitz
5f41a09701 AGI: Remove inputMode, not needed anyore 2016-02-02 23:02:50 +01:00
Martin Kiewitz
cdc6a2f3c3 AGI: test commands cleanup 2016-02-02 22:41:01 +01:00
Martin Kiewitz
8269a94bcd AGI: Use inner loop functionality for have.key
Also do it like the original interpreter did it
2016-02-02 22:26:39 +01:00
Martin Kiewitz
8a29f98c9c AGI: Don't pause in game timer while in menus
Original interpreter did not do it and we paused music/sfx,
which the original interpreter also didn't do.
Shouldn't cause issues.
2016-02-02 21:28:47 +01:00
Martin Kiewitz
5cd7ad8622 AGI: code formatting 2016-02-02 20:41:11 +01:00
Johannes Schickel
6778175f6d AGI: Fix formatting.
This mostly enforces tabs for indentation and spaces for formatting. But also
fixes spaces on empty lines, some extra/missing spaces.

astyle + manual fixup
2016-02-02 20:15:18 +01:00
Martin Kiewitz
9ad3712aa3 AGI: Add WORKAROUND comment to "render after menu"
see commit 0b75bf3721
Original AGI did not do, what we are doing now
2016-02-02 19:58:55 +01:00
Martin Kiewitz
223ce70eab AGI: Don't use status row for menu mouse trigger
Use hardcoded first line instead
In Donald Duck the status line is at line 24, but also hidden
2016-02-02 17:47:17 +01:00
Martin Kiewitz
0b75bf3721 AGI: Render after menu, when playarea starts at 0
Fixes graphics glitch for Donald Duck
2016-02-02 17:44:53 +01:00
Martin Kiewitz
05a5fc1b65 AGI: mouse support for menu 2016-02-02 17:28:58 +01:00
Martin Kiewitz
5acce8276e AGI: changed debug msg VGA font -> PC BIOS font 2016-02-02 11:04:08 +01:00
Martin Kiewitz
2a4a290d31 AGI: change how menus are triggered on Non-PC 2016-02-01 19:08:22 +01:00
Martin Kiewitz
9fff1686fc AGI: Pass vm pointer directly to commands
No functional change
2016-02-01 16:37:28 +01:00
Martin Kiewitz
839ac0a6a4 AGI: Rename _game.lognum to _game.curLogicNr
Also a bit of cleanup
2016-02-01 16:21:13 +01:00
Martin Kiewitz
264222ec29 AGI: Change _game.exitAllLogics to boolean 2016-02-01 16:15:07 +01:00
Martin Kiewitz
6749f22981 AGI: Remove _game.hasPrompt, no longer needed 2016-02-01 16:13:19 +01:00
Martin Kiewitz
f86d68d214 AGI: Remove old clockEnabled boolean
No longer needed
We use ScummVM system total play time functionality instead
2016-02-01 15:54:32 +01:00
Martin Kiewitz
896bf83ddc AGI: Fix pause command effectively freezing game
In game timer wasn't resumed, which caused no more cycles to
get executed.
2016-02-01 15:52:18 +01:00
Martin Kiewitz
14f338e2dd AGI: Revert revert the keyboard handling changes
It seems the issues on AmigaOS aren't actually caused by the new
code. Reverting the revert.
2016-02-01 15:02:52 +01:00
Martin Kiewitz
cf5133742c AGI: Improve original save/load menus
Description is trimmed for the verify window, width is now accurate
Actual save filename is now also shown, just like in the original
Cleanup
2016-02-01 14:51:03 +01:00
Martin Kiewitz
83ad64f947 AGI: Keyboard handling change
It seems the current code causes issues on at least AmigaOS.
Changed current code to the way SCI handled it.
Needs to get investigated in detail.
Added FIXME. Also see engines/sci/event.cpp
2016-02-01 02:17:47 +01:00
Martin Kiewitz
c28e101cdb AGI: implement predictive dialog 2016-02-01 01:34:36 +01:00
Martin Kiewitz
60cd621b74 AGI: fix warnings 2016-01-31 23:13:19 +01:00
Eugene Sandulenko
bd27eeb04b AGI: Remove unused variable 2016-01-31 22:46:53 +01:00
Willem Jan Palenstijn
38f5988390 AGI: Fix warning 2016-01-31 22:42:09 +01:00
Martin Kiewitz
f2fb921f84 AGI: vol system setting gets sent to scripts
Volume changes in ScummVM system menu now gets sent to scripts
as well.
2016-01-31 22:25:35 +01:00
Martin Kiewitz
a9b25b53d7 AGI: properly implement volume control + sync
Original code did assume that AGI volume level is 0-15
(0 for silence, 15 for maximum volume). It actually is the
other way. 0 is maximum, 15 is silence.
Fixed that. Also implemented sync with ScummVM settings dialog.
In case "mute" is enabled by the user, any volume changes done by
scripts are ignored.
Fixes Manhunter 1 Apple IIgs not getting sound anymore since the
VM Var cleanup (the script volume change by the scripts didn't
reach us before)
2016-01-31 22:14:35 +01:00
Martin Kiewitz
fd9c46831d AGI: remove timer hack, implement in game timer
in game timer is now updated, when scripts read in game timer
VM variables and during main loop. ScummVM total play time feature
is used for it. Game cycle syncing is done at the same time.
2016-01-31 20:53:36 +01:00
Martin Kiewitz
9acbe6f3f4 AGI: adjust getFlag(), setVar() and getVar() 2016-01-31 19:00:32 +01:00
Martin Kiewitz
4bc01ab7d5 AGI: getflag/setflag/etc. cleanup
renamed getflag() to getFlag()
renamed setflag() to setFlag()
renamed flipflag() to flipFlag()
preagi: renamed setFlag for this engine to setWinnieFlag
2016-01-31 17:56:53 +01:00
Martin Kiewitz
82b958f274 AGI: VM Var code cleanup
Don't access variables directly, but through method
Shouldn't include any functional differences
Also changed several hardcoded values to the corresponding enums.
2016-01-31 17:35:13 +01:00
Martin Kiewitz
1548f2cebf AGI: revert "motion type check in objectstop AGI3"
Caused issues with mouse support (that AGI on DOS never had).
e.g. KQ1/KQ2 on end of mouse click move Graham automatically falls
into water.

The check was added in AGI3 only, but maybe non-DOS interpreters
had it before. Or maybe mouse support was actually implemented
differently. Needs more investigating.
2016-01-31 14:49:52 +01:00
Martin Kiewitz
121415ef1f AGI: rename VGA font to PC BIOS font
probably more accurate
2016-01-31 14:14:33 +01:00
Martin Kiewitz
143fb9458f AGI: added/improved font debug output 2016-01-31 13:58:10 +01:00