From c96cd422e186180dde2b2ce95e4e2059ad38ad66 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 24 Nov 2018 11:58:40 +1300 Subject: [PATCH] Fix near parent grab tear away calc for avatar scale --- .../controllers/controllerModules/nearParentGrabEntity.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/system/controllers/controllerModules/nearParentGrabEntity.js b/scripts/system/controllers/controllerModules/nearParentGrabEntity.js index 3be6f602c2..433ad9ef53 100644 --- a/scripts/system/controllers/controllerModules/nearParentGrabEntity.js +++ b/scripts/system/controllers/controllerModules/nearParentGrabEntity.js @@ -171,7 +171,7 @@ Script.include("/~/system/libraries/controllers.js"); var controllerIndex = this.hand === LEFT_HAND ? Controller.Standard.LeftHand : Controller.Standard.RightHand; var controllerGrabOffset = getGrabPointSphereOffset(controllerIndex, true); - controllerGrabOffset = Vec3.multiply(-1, controllerGrabOffset); + controllerGrabOffset = Vec3.multiply(-MyAvatar.sensorToWorldScale, controllerGrabOffset); var distance = distanceBetweenEntityLocalPositionAndBoundingBox(props, controllerGrabOffset); if (distance > tearAwayDistance) { this.autoUnequipCounter++;