mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
G_MapEventsToControls: Permit automagic controller reassignment for axis events greater than JOYAXISRANGE/2
The author of this commit uses a trigger for A(ccel) and was being misled by the absence of response.
This commit is contained in:
parent
5a7f7b58f0
commit
22294c2c4d
1 changed files with 10 additions and 0 deletions
|
|
@ -467,6 +467,16 @@ void G_MapEventsToControls(event_t *ev)
|
||||||
|
|
||||||
i = ev->data1;
|
i = ev->data1;
|
||||||
|
|
||||||
|
if (AutomaticControllerReassignmentIsAllowed(ev->device)
|
||||||
|
&& (abs(ev->data2) > JOYAXISRANGE/2 || abs(ev->data3) > JOYAXISRANGE/2))
|
||||||
|
{
|
||||||
|
INT32 assigned = AssignDeviceToFirstUnassignedPlayer(ev->device);
|
||||||
|
if (assigned >= 0)
|
||||||
|
{
|
||||||
|
CONS_Alert(CONS_NOTICE, "Player %d device was reassigned\n", assigned + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (i >= JOYANALOGS)
|
if (i >= JOYANALOGS)
|
||||||
{
|
{
|
||||||
// The trigger axes are handled specially.
|
// The trigger axes are handled specially.
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue