From 081459a3297579f0c388f8a6bf2aeaad5df91ef6 Mon Sep 17 00:00:00 2001 From: Snorre Date: Sat, 5 Apr 2025 17:58:10 +0200 Subject: [PATCH] fixed the joint atually being between the hand and the body --- scripts/XRHand.cs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scripts/XRHand.cs b/scripts/XRHand.cs index 43ff0ef..a9066c2 100644 --- a/scripts/XRHand.cs +++ b/scripts/XRHand.cs @@ -44,9 +44,16 @@ public partial class XRHand : XRController3D PinJoint3D joint = new(); joint.NodeA = GetPathTo(body); - joint.NodeB = body.GetPath(); + joint.NodeB = GetPath(); joints.Add(joint); + + PinJoint3D joint2 = new(); + joint2.NodeB = GetPathTo(body); + joint2.NodeA = GetPath(); + joints.Add(joint2); + AddChild(joint); + body.AddChild(joint2); } } }