- Recover two ESyncBit values for other uses.

* By masking aiming+centering, we have look bits :)
This commit is contained in:
Mitchell Richters 2023-03-29 22:20:07 +11:00
parent bae18b3023
commit 46b5977a6a
5 changed files with 27 additions and 14 deletions

View file

@ -374,14 +374,22 @@ void ApplyGlobalInput(HIDInput* const hidInput, InputPacket* const inputBuffer)
}
else dpad_lock = 0;
gi->reapplyInputBits(inputBuffer);
inputBuffer->actions |= ActionsToSend;
ActionsToSend = 0;
if (buttonMap.ButtonDown(gamefunc_Aim_Up) || (buttonMap.ButtonDown(gamefunc_Dpad_Aiming) && hidInput->joyaxes[JOYAXIS_Forward] > 0))
{
inputBuffer->actions |= SB_AIM_UP;
inputBuffer->actions &= ~SB_CENTERVIEW;
}
if ((buttonMap.ButtonDown(gamefunc_Aim_Down) || (buttonMap.ButtonDown(gamefunc_Dpad_Aiming) && hidInput->joyaxes[JOYAXIS_Forward] < 0)))
{
inputBuffer->actions |= SB_AIM_DOWN;
inputBuffer->actions &= ~SB_CENTERVIEW;
}
if (buttonMap.ButtonDown(gamefunc_Dpad_Aiming))
hidInput->joyaxes[JOYAXIS_Forward] = 0;