Commit Graph

1163 Commits

Author SHA1 Message Date
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
Martin Kiewitz
8115145e4b AGI: hardcoded value replaced with VM_VAR_SECONDS 2016-01-31 13:50:37 +01:00
Martin Kiewitz
6baadff8d3 AGI: font cleanup
We now only offer the original VGA font (a few characters
were modified) and overwrite the extended set range with a
Russian set, when needed.
2016-01-31 13:49:42 +01:00
Martin Kiewitz
83495eab28 AGI: change key -> direction handling
After the VM Var 6 <-> ego direction change, this is required
Also our original behavior was inaccurate in that part as well.
2016-01-31 01:52:00 +01:00
Martin Kiewitz
4afda5bbea AGI: motion type check in objectstop was AGI3 only
verified via disassembly
2016-01-31 01:24:09 +01:00
Martin Kiewitz
428df3e6cb AGI: copying between var + ego screen obj fixed
We copied the wrong way see cycle.cpp
This fixes the fan game 13th disciple. bug #3563
Also cleanup
playercontrol variable is now a boolean
2016-01-31 01:04:53 +01:00
Martin Kiewitz
26cb39beee AGI: Ego motion type change on newroom only agi3
Ego motion type change on newRoom() was only done for AGI3
2016-01-30 23:54:41 +01:00
Martin Kiewitz
cb3b5d5e31 AGI: fix agi256 view decompression
+ add extra security checks
2016-01-30 23:08:19 +01:00
Martin Kiewitz
98730cb962 AGI: Fix some word parsing issues
- Keep a non-lowercased user input copy for copying out words
- Check for user input word end after matching a dictionary word
- Fix detection of "a" and "i" words
2016-01-30 03:13:17 +01:00
Martin Kiewitz
72f0d012c6 AGI: fix keyboard input code for keycodes
Reset key, when no valid .ascii was received.
2016-01-30 02:43:08 +01:00
Martin Kiewitz
125cec693f AGI: do not allow load/save while in inner loop
load/saving via ScummVM menu

Mixed up mother goose has an endless script loop, when no user name
was entered, which means restoring while in there would result
in us staying in the inner loop until the user entered something
2016-01-30 02:29:52 +01:00
Martin Kiewitz
243c861264 AGI: fix F7-F10 keys 2016-01-30 01:56:25 +01:00
Martin Kiewitz
bd59851300 AGI: fix amiga mouse cursor comment 2016-01-30 00:14:29 +01:00
Martin Kiewitz
e8791ac979 AGI: add hack to make numpad cursor keys work
should probably get fixed at some point in backend
2016-01-29 22:49:24 +01:00
Martin Kiewitz
855059ca05 AGI: font loader support for Atari ST font 2016-01-29 21:13:33 +01:00
Martin Kiewitz
72161adf1c AGI: overwrite save restore dialog font character
Overwrite it, to make sure that original save/restore dialogs
look properly.
2016-01-29 17:14:49 +01:00
Martin Kiewitz
614884ed39 AGI: support for user-supplied font-file
agi-font-atarist.bin -> used for platform Atari ST
agi-font-amiga.bin -> used for platform Amiga
agi-font-dos.bin -> used for platform DOS
agi-font-fanmade.bin -> used for fan-made games

That way users can get a more accurate font.
2016-01-29 16:43:15 +01:00
Martin Kiewitz
0c2de08155 AGI: new font class created
moved font stuff into GfxFont class
removed Mickey Mouse font data (is loaded from mickey.exe)
2016-01-29 16:18:31 +01:00
Martin Kiewitz
0f15ec2ce8 AGI: use Common::RenderMode instead of its own
AppleIIgs + Atari ST weren't available back then in the enum.
They now are, so I can use the Common one.
2016-01-29 15:43:45 +01:00
Martin Kiewitz
41620c95cc AGI: remove commented out code from CmdSetSimple()
should have been removed already.
2016-01-29 15:28:17 +01:00
Martin Kiewitz
5f43f07947 AGI: font.h / change comment to use unix slashes 2016-01-29 15:15:18 +01:00
Martin Kiewitz
a560f7ad01 AGI: improve checkPosition() code, remove while(0) 2016-01-29 15:11:07 +01:00
Martin Kiewitz
1987b4b4e5 AGI: remove commented out code in console.cpp 2016-01-29 15:10:17 +01:00
Martin Kiewitz
1a5bef2302 AGI: remove initGraphics comment 2016-01-29 14:23:33 +01:00
Martin Kiewitz
df845be116 AGI: added/changed font warnings 2016-01-29 14:07:48 +01:00
Martin Kiewitz
ccfd870c81 AGI: adjust mouse pos using render start Y
instead of having it hardcoded.
2016-01-29 14:03:47 +01:00
Martin Kiewitz
8a595e7771 AGI: graphics rewrite + cleanup
- graphics code fully rewritten
- Apple IIgs font support
- Amiga Topaz support
- Word parser rewritten
- menu code rewritten
- removed forced 2 second delay on all room changes
  replaced with heuristic to detect situations, where it's required
- lots of naming cleanup
- new console commands show_map, screenobj, vmvars and vmflags
- all sorts of hacks/workarounds removed
- added SCI wait mouse cursor
- added Apple IIgs mouse cursor
- added Atari ST mouse cursor
- added Amiga/Apple IIgs transition
- added Atari ST transition
- user can select another render mode and
  use Apple IIgs palette + transition for PC versions
- inventory screen rewritten
- SetSimple command now properly implemented
- PreAGI Mickey: Sierra logo now shown
- saved games: now saving controller key mapping
  also saving automatic save data (SetSimple command)
- fixed invalid memory access when saving games (31 bytes were saved
  using Common::String c_ptr()

Special Thanks to:
- fuzzie for helping out with the Apple IIgs font + valgrind
- eriktorbjorn for helping out with valgrind
- LordHoto for figuring out the code, that caused invalid memory
  access in the original code, when saving a game
- sev for help out with reversing the Amiga transition

currently missing:
- mouse support for menu
- mouse support for system dialogs
- predictive dialog support
2016-01-29 13:22:22 +01:00
Martin Kiewitz
2eecbe68fa AGI: Apple IIgs: remove warning about bad sample size 2016-01-27 21:18:45 +01:00
Martin Kiewitz
a85350aa3f AGI: fix invalid memory access in Apple IIgs sound
fixes crash in Manhunter 1, when looking at corpse right at the
start. Sound resource is actually corrupt (missing bytes).
2016-01-27 21:04:02 +01:00
Johannes Schickel
dcc811be20 AGI: Only request actual save slots in listSaves. 2016-01-26 16:35:30 +01:00
Johannes Schickel
29ade784e4 AGI: Give a nicer error message on invalid render mode. 2016-01-21 23:41:30 +01:00
Martin Kiewitz
19a5265647 AGI: fix Apple IIgs sound invalid memory access
check curInstrument pointer inside midiNoteOff
also improving readability a bit by cleanup
2016-01-19 21:02:56 +01:00
Martin Kiewitz
50f3085c99 AGI: reverse Apple IIgs stereo cleanup 2016-01-19 03:46:29 +01:00
Martin Kiewitz
05fb12eb63 AGI: reverse stereo for Apple IIgs + cleanup
According to Apple IIgs emulator and recorded music on Apple IIgs,
it seems that stereo was reversed. Melody in games seems to be
playing on left channel and not on the right one.
2016-01-19 03:19:13 +01:00
Martin Kiewitz
1084c22a78 AGI: fix Apple IIgs sound code + cleanup
fixes several crash possibilities
including uninitialized .chn
2016-01-18 21:52:48 +01:00
Johannes Schickel
c1cfcea39a AGI: Remove superflous default value registration for extra GUI options. 2015-12-28 00:14:11 +01:00