Take item pinches only from a mostly open hand

- Now that holding the wheel engages the race controls, closing the other hand on the rim could
  bring thumb and index together on the way and fire an item. A pinch uses an item only while the
  hand's grasp is under 0.5; a relaxed hand reads about 0, a hand closed on a rim about 0.9.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
iChris4andClaude Opus 5.5 committed 2026-09-25 00:42:48 +02:00
1 parent d3ad9fbd56
commit 38b7f89d74
4 files changed
+19 -4

No files matched your search

+2 -2
View File
@@ -992,8 +992,8 @@ void OpenXRInput::Sync(XrTime predicted_display_time, const OpenXRPointerScreen&
if (bare_held[0] || bare_held[1]) {
std::array<bool, kHands> item_pinch{};
for (uint32_t hand = 0; hand < kHands; ++hand) {
item_pinch[hand] = m_hand_driven[hand] && m_pinch_gate[hand].Update(m_pinch[hand], m_wheel_held[hand],
dt_seconds);
const bool pinch = hand_tracking::ItemPinch(m_pinch[hand], m_driving.hands[hand].grasp);
item_pinch[hand] = m_hand_driven[hand] && m_pinch_gate[hand].Update(pinch, m_wheel_held[hand], dt_seconds);
}
hand_tracking::ApplyBareHandRace(hands, bare_held, item_pinch);
} else {