mirror of
https://github.com/DrBeef/ioq3quest.git
synced 2025-02-15 00:30:43 +00:00
Merge pull request #4 from petr666/feature/uturn
Add uturn command and map it to RTHUMBBACK by default
This commit is contained in:
commit
a156e3cc1b
2 changed files with 8 additions and 4 deletions
|
@ -35,7 +35,7 @@ set vr_button_map_RTHUMBRIGHT ""
|
||||||
set vr_button_map_RTHUMBRIGHT_ALT "weapon 5"
|
set vr_button_map_RTHUMBRIGHT_ALT "weapon 5"
|
||||||
set vr_button_map_RTHUMBBACKRIGHT ""
|
set vr_button_map_RTHUMBBACKRIGHT ""
|
||||||
set vr_button_map_RTHUMBBACKRIGHT_ALT "weapon 4"
|
set vr_button_map_RTHUMBBACKRIGHT_ALT "weapon 4"
|
||||||
set vr_button_map_RTHUMBBACK ""
|
set vr_button_map_RTHUMBBACK "uturn"
|
||||||
set vr_button_map_RTHUMBBACK_ALT "weapon 7"
|
set vr_button_map_RTHUMBBACK_ALT "weapon 7"
|
||||||
set vr_button_map_RTHUMBBACKLEFT ""
|
set vr_button_map_RTHUMBBACKLEFT ""
|
||||||
set vr_button_map_RTHUMBBACKLEFT_ALT "weapon 8"
|
set vr_button_map_RTHUMBBACKLEFT_ALT "weapon 8"
|
||||||
|
|
|
@ -272,9 +272,13 @@ static void IN_SendButtonAction(const char* action, qboolean pressed)
|
||||||
}
|
}
|
||||||
else if (pressed)
|
else if (pressed)
|
||||||
{
|
{
|
||||||
char command[256];
|
if (strcmp(action, "uturn") == 0) {
|
||||||
Com_sprintf(command, sizeof(command), "%s\n", action);
|
CL_SnapTurn(180);
|
||||||
Cbuf_AddText(command);
|
} else {
|
||||||
|
char command[256];
|
||||||
|
Com_sprintf(command, sizeof(command), "%s\n", action);
|
||||||
|
Cbuf_AddText(command);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue