mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 17:03:58 +02:00
On touch, grip is a trigger, not a button, so it can have lots of callbacks with slightly different values that we ignore. In that case, don't update hand/joint.
This commit is contained in:
parent
4839a6e872
commit
7ba5ea4229
1 changed files with 3 additions and 3 deletions
|
@ -519,11 +519,9 @@
|
|||
|
||||
function updateTriggers(value, fromKeyboard, hand) {
|
||||
if (currentHand && hand !== currentHand) {
|
||||
debug("currentHand", currentHand, "ignoring messages from", hand);
|
||||
debug("currentHand", currentHand, "ignoring messages from", hand); // this can be a lot of spam on Touch. Should guard that someday.
|
||||
return;
|
||||
}
|
||||
currentHand = hand;
|
||||
currentHandJointIndex = getIdealHandJointIndex(MyAvatar, handToString(currentHand)); // Always, in case of changed skeleton.
|
||||
// ok now, we are either initiating or quitting...
|
||||
var isGripping = value > GRIP_MIN;
|
||||
if (isGripping) {
|
||||
|
@ -531,6 +529,8 @@
|
|||
if (state !== STATES.INACTIVE) {
|
||||
return;
|
||||
}
|
||||
currentHand = hand;
|
||||
currentHandJointIndex = getIdealHandJointIndex(MyAvatar, handToString(currentHand)); // Always, in case of changed skeleton.
|
||||
startHandshake(fromKeyboard);
|
||||
} else {
|
||||
// TODO: should we end handshake even when inactive? Ponder
|
||||
|
|
Loading…
Reference in a new issue