mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 14:03:17 +02:00
support disabling both hands
This commit is contained in:
parent
e0eae23dd3
commit
aca0fa7beb
1 changed files with 8 additions and 3 deletions
|
@ -1266,10 +1266,10 @@ Controller.enableMapping(MAPPING_NAME);
|
|||
var handToDisable = 'none';
|
||||
|
||||
function update() {
|
||||
if (handToDisable !== LEFT_HAND) {
|
||||
if (handToDisable !== LEFT_HAND && handToDisable!=='both') {
|
||||
leftController.update();
|
||||
}
|
||||
if (handToDisable !== RIGHT_HAND) {
|
||||
if (handToDisable !== RIGHT_HAND && handToDisable!=='both') {
|
||||
rightController.update();
|
||||
}
|
||||
}
|
||||
|
@ -1279,13 +1279,18 @@ Messages.subscribe('Hifi-Hand-Disabler');
|
|||
handleHandDisablerMessages = function(channel, message, sender) {
|
||||
|
||||
if (sender === MyAvatar.sessionUUID) {
|
||||
handToDisable = message;
|
||||
if (message === 'left') {
|
||||
handToDisable = LEFT_HAND;
|
||||
}
|
||||
if (message === 'right') {
|
||||
handToDisable = RIGHT_HAND;
|
||||
}
|
||||
if(message==='both'){
|
||||
handToDisable='both';
|
||||
}
|
||||
if(message==='none'){
|
||||
handToDisable='none';
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue