mirror of
https://github.com/DrBeef/ioq3quest.git
synced 2024-11-25 13:31:10 +00:00
Merge pull request #71 from petr666/feature/control-tweaks
Hardcode A to skip server search in menu instead of using moveup bind hack
This commit is contained in:
commit
df4bc0c072
1 changed files with 20 additions and 7 deletions
|
@ -306,12 +306,6 @@ static qboolean IN_SendInputAction(const char* action, qboolean inputActive, flo
|
|||
vr.weapon_stabilised = qfalse;
|
||||
}
|
||||
}
|
||||
//Special case for moveup as we can send a space key instead allowing us to skip
|
||||
//server search in the server menu
|
||||
else if (strcmp(action, "+moveup") == 0)
|
||||
{
|
||||
Com_QueueEvent(in_vrEventTime, SE_KEY, K_SPACE, inputActive, 0, NULL);
|
||||
}
|
||||
else if (strcmp(action, "+weapon_select") == 0)
|
||||
{
|
||||
vr.weapon_select = inputActive;
|
||||
|
@ -899,13 +893,32 @@ static void IN_VRButtons( qboolean isRightController, uint32_t buttons )
|
|||
Cbuf_AddText("cmd team spectator\n");
|
||||
}
|
||||
}
|
||||
else if (VR_useScreenLayer() || cl.snap.ps.pm_type == PM_INTERMISSION)
|
||||
{
|
||||
// Skip server search in the server menu
|
||||
if (!IN_InputActivated(&controller->buttons, ovrButton_A)) {
|
||||
IN_ActivateInput(&controller->buttons, ovrButton_A);
|
||||
Com_QueueEvent(in_vrEventTime, SE_KEY, K_SPACE, qtrue, 0, NULL);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
IN_HandleActiveInput(&controller->buttons, ovrButton_A, "A", 0, qfalse);
|
||||
}
|
||||
} else {
|
||||
if (VR_useScreenLayer() || cl.snap.ps.pm_type == PM_INTERMISSION)
|
||||
{
|
||||
// Skip server search in the server menu
|
||||
if (IN_InputActivated(&controller->buttons, ovrButton_A)) {
|
||||
IN_DeactivateInput(&controller->buttons, ovrButton_A);
|
||||
Com_QueueEvent(in_vrEventTime, SE_KEY, K_SPACE, qfalse, 0, NULL);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
IN_HandleInactiveInput(&controller->buttons, ovrButton_A, "A", 0, qfalse);
|
||||
}
|
||||
}
|
||||
|
||||
if (buttons & ovrButton_B) {
|
||||
IN_HandleActiveInput(&controller->buttons, ovrButton_B, "B", 0, qfalse);
|
||||
|
|
Loading…
Reference in a new issue