diff --git a/Projects/Android/jni/JKVR/VrInputDefault.cpp b/Projects/Android/jni/JKVR/VrInputDefault.cpp index f742eef..ca32649 100644 --- a/Projects/Android/jni/JKVR/VrInputDefault.cpp +++ b/Projects/Android/jni/JKVR/VrInputDefault.cpp @@ -660,9 +660,8 @@ void HandleInput_Default( ovrInputStateGamepad *pFootTrackingNew, ovrInputStateG if ((pDominantTrackedRemoteNew->Buttons & ovrButton_Trigger) != (pDominantTrackedRemoteOld->Buttons & ovrButton_Trigger)) { - ALOGV("**WEAPON EVENT** Not Grip Pushed %sattack", - (pDominantTrackedRemoteNew->Buttons & ovrButton_Trigger) ? "+" : "-"); - firing = (pDominantTrackedRemoteNew->Buttons & ovrButton_Trigger); + firing = (pDominantTrackedRemoteNew->Buttons & ovrButton_Trigger) && + !vr.item_selector; sendButtonAction("+attack", firing); } @@ -858,7 +857,9 @@ void HandleInput_Default( ovrInputStateGamepad *pFootTrackingNew, ovrInputStateG float threshhold = vr_gesture_triggered_use_threshold->value; // Hand must be extended and at least on waist level // Com_Printf("DISTANCE: %.2f ; HEIGHT: %.2f\n", absoluteDistanceToHMD, verticalDistanceToHMD); - if (!vr.weapon_stabilised && absoluteDistanceToHMD > threshhold && verticalDistanceToHMD > -threshhold) { + bool gestureUseAllowed = !vr.weapon_stabilised && !vr.cin_camera && !vr.misc_camera && + !vr.remote_turret; + if (gestureUseAllowed && absoluteDistanceToHMD > threshhold && verticalDistanceToHMD > -threshhold) { if (!vr.useGestureActive) { vr.useGestureActive = true; sendButtonAction("+use", true); diff --git a/Projects/Android/jni/OpenJK/codeJK2/cgame/cg_weapons.cpp b/Projects/Android/jni/OpenJK/codeJK2/cgame/cg_weapons.cpp index ff96cb4..a8c55a0 100644 --- a/Projects/Android/jni/OpenJK/codeJK2/cgame/cg_weapons.cpp +++ b/Projects/Android/jni/OpenJK/codeJK2/cgame/cg_weapons.cpp @@ -2782,8 +2782,10 @@ void CG_ItemSelectorNext_f( void ) } centity_t *cent = &cg_entities[cg.snap->ps.clientNum]; + + //Only show the stance selection if using saber and in third person int selectors = ((cent->gent->client->ps.forcePowersKnown & ( 1 << FP_SABER_OFFENSE )) && - cent->currentState.weapon == WP_SABER) ? 3 : 2; + cent->currentState.weapon == WP_SABER && cg_thirdPerson.integer) ? 3 : 2; cg.itemSelectorType = (cg.itemSelectorType+1) % selectors; cg.itemSelectorTime = cg.time; } @@ -2796,8 +2798,10 @@ void CG_ItemSelectorPrev_f( void ) } centity_t *cent = &cg_entities[cg.snap->ps.clientNum]; + + //Only show the stance selection if using saber and in third person int selectors = ((cent->gent->client->ps.forcePowersKnown & ( 1 << FP_SABER_OFFENSE )) && - cent->currentState.weapon == WP_SABER) ? 3 : 2; + cent->currentState.weapon == WP_SABER && cg_thirdPerson.integer) ? 3 : 2; if (--cg.itemSelectorType < 0) cg.itemSelectorType = selectors-1; cg.itemSelectorTime = cg.time;