Commit graph

115 commits

Author SHA1 Message Date
athrxx
047f3fbfea SCI: cleanup and reorganize gfx drivers
gfxdrivers.cpp has become quite large. So I've now made a
separate file for each driver. I also separated the mode
validation and driver init code from the enigine and put
it into an extra file.
2024-12-24 13:15:37 +02:00
athrxx
b7147fda30 SCI: fix bug no. 15242
(regression from PR 5877)
2024-07-02 22:14:06 +02:00
athrxx
478cd8925a SCI: (SCI0) - add support for CGA and Hercules render modes
(as per usual, each target has to be run once to upgrade the launcher
options, so that the new render modes can actually be selected)
2024-06-30 13:05:01 +03:00
Иван Марчуков
3f1c050cbe SCI: More information. Moved vocab parse into separate function 2024-01-22 08:50:52 +02:00
Иван Марчуков
073469293f SCI: Add cyrillic input support for text-based games 2024-01-22 08:50:52 +02:00
sluicebox
b0e47dc7ee SCI: Initialize EventManager fields. PVS-Studio V730 2023-10-29 15:42:12 -07:00
sluicebox
2801803b5f SCI: Remove redundant checks. PVS-Studio V547, V560, V654 2023-10-29 15:42:12 -07:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Zvika Haramaty
6ab0cb78e0 SCI: Improve vm_hooks ; Support Hebrew SQ3
- vm_hooks: fully support 'call*'
- make required changes to support Hebrew SQ3 (which is still a WIP
project)
2020-05-25 03:21:59 +03:00
mataniko
321a02aff2 JANITORIAL: Rename shouldRTL, resetRTL and FORCE_RTL 2020-05-12 10:36:38 +02:00
mataniko
06242a712b JANITORIAL: Rename EVENT_RTL
Now that ScummVM is adding RTL support, the EVENT_RTL should be disambigious that it is for returning to launcher
2020-05-12 10:36:38 +02:00
Paul Gilbert
ba147f5ad5 SCI: Refactor to use Engine debugger 2020-02-16 13:07:19 +02:00
Eugene Sandulenko
77adfd762e SCI: Removed unneeded debug output. The bug has been confirmed fixed 2019-12-27 19:49:37 +01:00
Eugene Sandulenko
df5a4fb027 SCI: Swap lowercase Alt+'a'/'s' for Polish, in order to avoid conflicting keybingings 2019-12-26 15:51:22 +01:00
Eugene Sandulenko
a2cbc18d61 SCI: Fix lowercase Alt+'n' for Polish 2019-12-26 15:40:54 +01:00
Eugene Sandulenko
c88da94585 SCI: Added support for typing Polish characters with 'Alt' 2019-12-26 15:10:07 +01:00
Eugene Sandulenko
ac2b6af639 SCI: Added temporary debug ouput for Polish input 2019-12-25 23:38:23 +01:00
Eugene Sandulenko
3e296bc31b SCI: Reformatted the conversion table 2019-12-25 14:05:02 +01:00
Eugene Sandulenko
f491a2562c SCI: Added detection and support for Polish LSL7
Fixes bug #11274
2019-12-25 13:24:36 +01:00
Eugene Sandulenko
c38600410e SCI: Support for Cyrillic input 2019-09-21 17:07:15 +02:00
sluicebox
a2cc90bf9b SCI: Fix backend events treated as keyboard events
Prevents backend events such as EVENT_SCREEN_CHANGED
from being misinterpreted as SCI keyboard events
2019-06-06 07:08:49 +03:00
Adrian Frühwirth
a20f90cbb7 JANITORIAL: Fix formatting 2018-04-22 00:56:21 +02:00
Colin Snover
c7c5f28bdb SCI32: Clean up scriptWidth/scriptHeight/screenWidth/screenHeight
This removes the unnecessary Buffer subclass and stops most places
where the output buffer was being interrogated about dimensions
instead of GfxFrameout.
2017-10-06 22:56:26 -05:00
Colin Snover
7a41b6f023 SCI: Add support for keyup events
Basic keyup event support appears to have been added in the SCI1.1
IBM keyboard driver, and more robust support was provided in SCI32
which actually gets used by at least Lighthouse. This patch adds
support for keyup events in SCI1.1+.

Fixes Trac#10242.
2017-09-27 20:27:34 -05:00
Colin Snover
9a8070da3c SCI: Do some clean-up of event handling system
Convert macros and vars to enums, rename keyboard events in
preparation for adding key up events, clean up unnecessary nested
conditionals, add TODOs for potential future work.
2017-09-27 20:27:33 -05:00
Colin Snover
0beb259278 SCI32: Improve performance when flushing events during video playback
Calling through EventManager::getSciEvent to flush events is
pretty inefficient and created stalls that lead to dropped
frames during the chapter 7 chase in Phantasmagoria 1.

If necessary, performance could be improved further by extending
Common::EventManager to expose SDL_FlushEvents, but this seems to
finish in 0-1ms so should be OK for now.

Refs Trac#9974, Trac#9975.
2017-07-23 10:35:13 -05:00
Colin Snover
b4c0be8b42 SCI: Fix control character keyboard events
Used by:

* All games with text inputs (Ctrl+C clears text boxes)
* QFG1VGA (Ctrl+S shows stats)
* Torin (Ctrl+N, Ctrl+O, Ctrl+S, etc. activate menu commands)

The branch that used to shift control keys for SCI versions <=
SCI_VERSION_1_MIDDLE was bogus; history indicates it was intended
to be used to fix backends that sent control characters when
Ctrl+Alt were used together, but that case is already handled by
the Alt-checking code just prior to that code. Games expect to
receive control characters only when Ctrl is the only active
modifier, and this seems to be consistent across all versions of
SCI engine from SCI0 all the way through at least SCI2.1.

Fixes Trac#6703, Trac#9837.
2017-07-16 01:33:57 -05:00
Colin Snover
6303468555 SCI32: Fix mouse position clamping 2016-10-14 19:52:21 -05:00
Colin Snover
c118e2fe12 SCI32: Reset active hot rect index when changing hot rects 2016-10-10 19:35:28 -05:00
Colin Snover
1c5a5d09f9 SCI32: Fix Return to Launcher in F5 menu
Closes #837.
2016-10-05 15:30:31 -05:00
Colin Snover
44dd029cb1 SCI32: Implement kSetHotRectangles
Used only by chapter 7 of Phant1.
2016-09-29 19:39:16 -05:00
Colin Snover
560af83300 SCI: Move SciEngine::sleep to correct source file 2016-09-29 19:39:16 -05:00
Colin Snover
d0517f515e SCI32: Update screen on frameout, instead of in the event loop 2016-09-29 19:39:16 -05:00
Colin Snover
80d9182554 SCI32: Implement SCI32 cursor support 2016-08-19 13:57:40 -05:00
Colin Snover
77991b7eac SCI32: Add const to getCurrentBuffer 2016-07-02 22:28:41 -05:00
Colin Snover
1337cd3dec SCI32: Implement kEditText 2016-03-06 21:34:43 -06:00
Filippos Karapetis
cdbd7c8add SCI: Use uint32 instead of unsigned int 2016-03-01 01:12:58 +02:00
Johannes Schickel
60d4367f3c SCI: Formatting fix. 2016-02-13 00:36:06 +01:00
Johannes Schickel
98edaa799e SCI: Make variable name in line with our guidelines.
(cherry picked from commit 7d7c36b593)
2016-02-13 00:06:27 +01:00
Johannes Schickel
82b5ed65cc SCI: Small variable renaming to match our naming guidelines. 2016-02-09 19:52:09 +01:00
Johannes Schickel
b911976a66 SCI: Take advantage of operator-> of Common::List::iterator. 2016-02-09 16:42:45 +01:00
Martin Kiewitz
e91bdf0262 SCI: Remove hardcoded value in getScummVMEvent() 2016-02-03 20:45:08 +01:00
Martin Kiewitz
7635f3c73e SCI: Make event handling helper tables static 2016-02-02 15:03:54 +01:00
Martin Kiewitz
b052ff2762 SCI: Fix comment about debugger keys
Was changed to Ctrl-Shift-D at some point, because a SCI game
uses Ctrl-D. Comment wasn't changed accordingly back then.
2016-02-02 12:51:25 +01:00
Martin Kiewitz
42cb01f57c SCI: Keyboard event handling cleanup
Renamed "ourModifiers" to "scummVMKeyFlags"
Now also using the flags directly from the ScummVM event in case
it actually was a Keyboard event.
2016-02-02 12:47:47 +01:00
Martin Kiewitz
bc0dd6f821 SCI: Fix regression of previous keycode commit
7aeadba863
Thanks LordHoto for spotting it
2016-02-02 11:43:58 +01:00
Martin Kiewitz
7aeadba863 SCI: Removed ".data" from SciEvent
Was the ScummVM-system-Keycode, sometimes modified.
Changed Menu/Portrait/Controls32-code to use .character instead.
Cleaned up a bit of code in getScummVMEvent()
2016-02-02 11:33:40 +01:00
Martin Kiewitz
82a27a33da SCI: fix typo in comment 2016-02-02 10:46:16 +01:00
Martin Kiewitz
59d2c4b27e SCI: Do not pass/use .data for mouse button type
Also added comment about .data field. Should be renamed.
2016-02-02 02:10:43 +01:00
Martin Kiewitz
c0bdbe1ca8 SCI: Fix control/Fx keys not working anymore
Was effectively caused by commit adding the keyboard driver bug
for SCI0/SCI01, although the bug is actually real and happens.

It seems Sierra did not check the key-modifier in kMenuSelect.
We do and that's why the code didn't recognize all sorts of
menu keys anymore.
We now isolate the lower byte before comparing.

I also noticed, that Sierra passed keyboard modifiers in mouse
events. This was probably done, so that owners of a 1-button
mouse were able to right-click. We do this now too.

Also added information about mouse modifiers in kGetEvent.

Moved the mouse modifier code into getScummVMEvent().

This should fix bug #7009.
2016-02-02 01:56:08 +01:00