Commit graph

28 commits

Author SHA1 Message Date
JetSetIlly 8f2eb8753f rewinding by mouse wheel works in debugger
rewinds/FF by 10 frames or by a single frame if shift key is held
2024-04-12 21:01:59 +01:00
JetSetIlly 26bb7ae69d reversed paddle direction for stelladaptor input
fixed overflow of paddle resistance for stelladaptor
2024-02-08 21:17:46 +00:00
JetSetIlly d1224bd0dc mouse y-axis mixed with x-axis for paddle input 2024-01-10 17:42:11 +00:00
JetSetIlly 5524be92fe peripheral swapping with the -swap argument
the PERIPHERAL SWAP command also added

no corresponding setup entry yet. the setup package needs rewriting to
be more flexible before we do that
2024-01-10 17:42:11 +00:00
JetSetIlly 3a6b1f3a3e changed EventDataPaddle to use integer based (int16) values
EventDataPaddle can now specify whether the values are relative or
absolute values. previously all values were absolute

hardware mice use relative values whereas devices like the stelladaptor
use absolute values

removed gamepad trigger operation of paddles. it was a poor solution to
the problem
2024-01-10 17:42:11 +00:00
JetSetIlly 11fb367ff5 periperhal event PaddleSet now takes a pair of float32 values
float32 pair defined as ports.EventDataPaddle

added functions to convert the float32 to and from a playback entry.
conversion from the playback entry tolerates a single float32 value
meaning that old recording files will work

rename plugging.PortLeftPlayer and plugging.PortRightPlayer to just
plugging.PortLeft and plugging.PortRight
2023-02-27 21:27:21 +00:00
JetSetIlly adabc65246 fix for stelladaptor joysticks broken in 7381374b85 2023-02-26 17:00:32 +00:00
JetSetIlly 7381374b85 added stelladaptor event
first attempt at paddle for left player
2023-02-26 07:43:48 +00:00
JetSetIlly 6895b373a3 mouse cursor will be hidden in playmode window if mouse if not being used
cursor will reappear when mouse is moved, unless the window has been
"captured"
2022-09-07 14:59:26 +01:00
JetSetIlly 962d199330 second stick button works with keyboard. right-player also added 2022-01-23 10:08:51 +00:00
JetSetIlly be9011493d quick addition of two button joystick support
regular joystick replaced with "gamepad" option. more sophisticated
selection process and new icon will be added at a later time
2022-01-22 22:49:48 +00:00
JetSetIlly 58848acdf9 input system and ports system separated
playback/recorder and driven input systems moved out of the the ports
package and into a new input package. how the input systems interact has
been clarified and improved - for example, it is now posssible for a
playback file to be used to drive two emulations for comparison purposes

the debugger startup procedure has been clarified with two distinct
startup functions for playmode and debugger - each of which take
different arguments. the clarity has allowed the reintroduction of
recording and playback to the main play mode
2021-12-11 08:19:46 +00:00
JetSetIlly 2942d35320 added ports.TimedInputEvent to accompany ports.InputEvent
the Time field was in ports.InputEvent but it didn't make sense to
specify a time value in all contexts
2021-12-05 22:05:35 +00:00
JetSetIlly 4df1eb071e added the ports.InputEvent type
this is now used when passing events and event data around. it also
records the port and time (in TV coordinates) which are required by
driver/passenger synchronisation and playback recording

removed television interfaces from signal package and moved the
interfaces to where they are needed
2021-12-05 20:17:43 +00:00
JetSetIlly 0e3ec6a5d5 add visual comparison tool. command line option and gui
userinput for two emulations synced by RIOT ports. RIOT port
driver/passenger synchronisation ensures user input is seen by the
emulations at the same time (relative to the emulation's television)

does not yet handle RNGs (randomise on startup or the RNG in the DPC or
DPC+ formats yet). we need to add a context type first
2021-12-05 20:17:42 +00:00
JetSetIlly 464a62c9db userinput package can now forward events to many implementations of HandleInput
preperation for allowing parallel emulations with the same userinput
2021-12-05 20:17:42 +00:00
JetSetIlly bba5ff253e analog thumbstick will never unpause the game on thumbstick center
this prevents thumbsticks from interfering with rewind/pause when it is
in the deadzone but not perfectly centered

correct icon is shown when rewind reaches beginning of buffer. was
showing pause ||. now showing the rewind/pause |<<
2021-11-09 09:29:27 +00:00
JetSetIlly e0d577589f rewind in playmode is more responsive - mousewheel and keyboard
added rewind via gamepad bumper

cleanup of rewind functions in debugger package
2021-11-09 08:40:45 +00:00
JetSetIlly c2d6e4d214 userinput package returns whether a userinput was handled by the emulation
this allows more elegant handling of unpause on controller input - no
unpause unless the controller is plugged in. ie. paddle input won't
cause the game to unpause unless the paddle controller is "plugged in"

added gamepad bumper (rewind in playmode) and guide button
(debugger/playmode switcher)
2021-11-07 09:52:26 +00:00
JetSetIlly 86940981a5 a controller input (including the panel) will unpause emulation (playmode)
better mousewheel support for rewind
2021-11-06 12:37:49 +00:00
JetSetIlly 180f2b5003 added rewind system to playmode
update userinput.EventKeyboard to support Repeat keypresses

in playmode rewind forward/backward occurs on shift-left or shit-right
cursor keys (with repeat)

removed the pause feature (sdlimgui) that caused two-frame kernels to
appear "complete" when paused.
    a) it wasn't consistent
    b) it can cause single-frame kernels to shimmer
    c) it doesn't really work with the rewind system
it'll be addressed in a future commit
2021-10-26 18:48:35 +01:00
JetSetIlly 25b0f1c82f added right player joystick
using default Stella keys:

    Up	    Y
    Down    H
    Left    G
    Right   J
    Fire    F
2021-09-30 17:16:35 +01:00
JetSetIlly cc22223313 refactor of ports package
added PeripheralID type to complement PortsID type. renamed keyboard
peripheral to keypad, which is more accurate and removes any potential
confusion with the physical keyboard the user might be using
2021-08-24 16:02:12 +01:00
JetSetIlly a4ed971a1b analogue thumbstick now controls stick, rather than paddle
the amount of travel in the analogue stick is just too small for it to
be useful for paddle control IMO.

triggers still control paddle but no longer self-centre. the center
position is different for different games. also, it makes some games too
easy.
2021-03-16 22:58:46 +00:00
JetSetIlly 2062ff6edb port monitor 2021-03-14 18:03:49 +00:00
JetSetIlly c3cb43f051 left/right triggers control paddle
moved some gamepad analogue axis code from sdlimgui/service to
userinput/handle
2021-03-09 22:37:08 +00:00
JetSetIlly 3c00d7bbb5 Gamepad start button acts as panel reset switch 2021-03-09 22:37:08 +00:00
JetSetIlly 156534a3fd added userinput package
debugger and playmode refer to userinput package rather than the common
code being in the playmode package

GUI events are now userinput events

more versatile handling of EventData in controller package. parsing of
EventData is handled by the controller types as required. added
EventDataPlayback type to ports package to help distinguish source of
data.

EventDataStick used to specify stick data value. used to help
distinguish between setting a stick direction and toggle a stick
direction. the latter case is useful for (physical) gamepad input and
the former for input from a keyboard.

Gamepad analogue stick can be used for paddle input. PaddleFire removed
and Fire used instead.

version number of playback file increased to 1.1. version detection of
recorder.IsPlaybackFile() improved.
2021-03-09 22:37:08 +00:00