Showing the changes to scripts/system/controllers/toggleAdvancedMovementForHandControllers.js (1 of 1 file). Show all
Unified · Split
| @@ -55,7 +55,9 @@ function registerBasicMapping() { · 54 unmodified lines | ||
| 55 | 55 | mappingName = 'Hifi-AdvancedMovement-Dev-' + Math.random(); |
| 56 | 56 | basicMapping = Controller.newMapping(mappingName); |
| 57 | 57 | basicMapping.from(Controller.Standard.LY).to(function(value) { |
| 58 | − return; | |
| 58 | + if (isDisabled) { | |
| 59 | + return; | |
| 60 | + } | |
| 59 | 61 | var stick = Controller.getValue(Controller.Standard.LS); |
| 60 | 62 | if (value === 1 && Controller.Hardware.OculusTouch !== undefined) { |
| 61 | 63 | rotate180(); |
| @@ -72,7 +74,9 @@ function registerBasicMapping() { · 10 unmodified lines | ||
| 72 | 74 | }); |
| 73 | 75 | basicMapping.from(Controller.Standard.LX).to(Controller.Standard.RX); |
| 74 | 76 | basicMapping.from(Controller.Standard.RY).to(function(value) { |
| 75 | − return; | |
| 77 | + if (isDisabled) { | |
| 78 | + return; | |
| 79 | + } | |
| 76 | 80 | var stick = Controller.getValue(Controller.Standard.RS); |
| 77 | 81 | if (value === 1 && Controller.Hardware.OculusTouch !== undefined) { |
| 78 | 82 | rotate180(); |