Discussion:
[Ohrrpgce] Crufty arrowsets
Ralph Versteegen
2018-10-26 03:51:56 UTC
Permalink
James, is there any reason that all these arrowset functions read
keyboard keys, to which gamepad buttons have been mapped, instead of
just reading a gamepad directly?
I'l like the get rid of all of these functions, and instead handle
controls in allmodex, with multiple carray() arrays, one per player.
Since multiple gamepad support is only used for Ouya, which is dead, I
guess I don't need to worry too much about not breaking anything, as
long as at least the first arrowset continues to work.

Also, my plan is to make the second argument to keyval/keyispressed
specify the joystick number if used with a joy: constant, specify the
player number if used with a "* key" virtual key code, and do nothing
with key: constants.
James Paige
2018-10-26 10:11:07 UTC
Permalink
I think that all sounds good to me. I think the reason I mapped all android
joystick stuff through keyboard keys is because OUYA was gamepad-only and I
wanted existing games to work even if they scripted keyval checks to the
arrow keys.

I agree that the multiple gamepad stuff should be deprecated. (I think I
might be the only person to ever use it?) As long as the stuff for the
first gamepad still works that is good enough

I like your plan for the second argument to keyval
Post by Ralph Versteegen
James, is there any reason that all these arrowset functions read
keyboard keys, to which gamepad buttons have been mapped, instead of
just reading a gamepad directly?
I'l like the get rid of all of these functions, and instead handle
controls in allmodex, with multiple carray() arrays, one per player.
Since multiple gamepad support is only used for Ouya, which is dead, I
guess I don't need to worry too much about not breaking anything, as
long as at least the first arrowset continues to work.
Also, my plan is to make the second argument to keyval/keyispressed
specify the joystick number if used with a joy: constant, specify the
player number if used with a "* key" virtual key code, and do nothing
with key: constants.
_______________________________________________
Ohrrpgce mailing list
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
Ralph Versteegen
2018-10-26 11:27:53 UTC
Permalink
On that note, I wanted to add a pref bit that would map joystick keys
to up/down/left/right/enter/esc on the keyboard, and turn it on by
default. Because the number of games which check for joystick keys
instead of just keyboard keys is very close to zero, the number of
games which actually care whether that keyboard and joystick buttons
are distinct (for multiplayer?) is even closer to zero (I would guess:
just your multiplayer OUYA game (which game is that?)), while the
number of games which could be played with joystick by doing that
automapping is large.

As well as ArrowSet, I'd also really like to get rid of
io_remap_android_gamepad entirely, and do the mapping in the engine
instead. This could be some painful refactoring...

On the other hand, supporting multiple players with multiple carray()
arrays is extremely low priority and maybe something I'll never get
around to.
Post by James Paige
I think that all sounds good to me. I think the reason I mapped all android
joystick stuff through keyboard keys is because OUYA was gamepad-only and I
wanted existing games to work even if they scripted keyval checks to the
arrow keys.
I agree that the multiple gamepad stuff should be deprecated. (I think I
might be the only person to ever use it?) As long as the stuff for the
first gamepad still works that is good enough
I like your plan for the second argument to keyval
Post by Ralph Versteegen
James, is there any reason that all these arrowset functions read
keyboard keys, to which gamepad buttons have been mapped, instead of
just reading a gamepad directly?
I'l like the get rid of all of these functions, and instead handle
controls in allmodex, with multiple carray() arrays, one per player.
Since multiple gamepad support is only used for Ouya, which is dead, I
guess I don't need to worry too much about not breaking anything, as
long as at least the first arrowset continues to work.
Also, my plan is to make the second argument to keyval/keyispressed
specify the joystick number if used with a joy: constant, specify the
player number if used with a "* key" virtual key code, and do nothing
with key: constants.
_______________________________________________
Ohrrpgce mailing list
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
James Paige
2018-10-26 12:18:27 UTC
Permalink
The prefer but sounds good.

The only games (I am aware of) that use ouya multiplayer gamepad support
are Don't Eat Soap and Vorpal Florist (the latter is sort of an Easter egg,
for controlling enemies with the second controller)

Both would be relatively trivial to update for the new gamepad scripting
support.

---
James
Post by Ralph Versteegen
On that note, I wanted to add a pref bit that would map joystick keys
to up/down/left/right/enter/esc on the keyboard, and turn it on by
default. Because the number of games which check for joystick keys
instead of just keyboard keys is very close to zero, the number of
games which actually care whether that keyboard and joystick buttons
just your multiplayer OUYA game (which game is that?)), while the
number of games which could be played with joystick by doing that
automapping is large.
As well as ArrowSet, I'd also really like to get rid of
io_remap_android_gamepad entirely, and do the mapping in the engine
instead. This could be some painful refactoring...
On the other hand, supporting multiple players with multiple carray()
arrays is extremely low priority and maybe something I'll never get
around to.
Post by James Paige
I think that all sounds good to me. I think the reason I mapped all
android
Post by James Paige
joystick stuff through keyboard keys is because OUYA was gamepad-only
and I
Post by James Paige
wanted existing games to work even if they scripted keyval checks to the
arrow keys.
I agree that the multiple gamepad stuff should be deprecated. (I think I
might be the only person to ever use it?) As long as the stuff for the
first gamepad still works that is good enough
I like your plan for the second argument to keyval
Post by Ralph Versteegen
James, is there any reason that all these arrowset functions read
keyboard keys, to which gamepad buttons have been mapped, instead of
just reading a gamepad directly?
I'l like the get rid of all of these functions, and instead handle
controls in allmodex, with multiple carray() arrays, one per player.
Since multiple gamepad support is only used for Ouya, which is dead, I
guess I don't need to worry too much about not breaking anything, as
long as at least the first arrowset continues to work.
Also, my plan is to make the second argument to keyval/keyispressed
specify the joystick number if used with a joy: constant, specify the
player number if used with a "* key" virtual key code, and do nothing
with key: constants.
_______________________________________________
Ohrrpgce mailing list
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
_______________________________________________
Ohrrpgce mailing list
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
Loading...