From 77c9e37aef61e7e536571b858702b0de219cf8eb Mon Sep 17 00:00:00 2001 From: Pascal Serrarens Date: Fri, 24 Feb 2023 15:40:16 +0100 Subject: [PATCH] Updated function overriding --- .../Scripts/Interaction/HandInteraction.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs b/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs index 985c910..3ff62ed 100644 --- a/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs +++ b/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs @@ -41,7 +41,7 @@ namespace Passer.Humanoid { inputModule.EnableTouchInput(humanoid, isLeft, 0); } - public HandSocket CreateGrabSocket() { + public virtual HandSocket CreateGrabSocket() { if (hand.bone.transform == null) return null; @@ -816,7 +816,7 @@ namespace Passer.Humanoid { } - protected void LetGoRigidbodyWithoutHandle() { + protected virtual void LetGoRigidbodyWithoutHandle() { Rigidbody objRigidbody = RigidbodyDisabled.UnparentRigidbody(handPalm, grabbedObject.transform); if (objRigidbody != null && !objRigidbody.isKinematic) { if (handRigidbody != null) { @@ -829,11 +829,11 @@ namespace Passer.Humanoid { LetGoStaticWithoutHandle(); } - protected void LetGoStaticWithoutHandle() { + protected virtual void LetGoStaticWithoutHandle() { grabSocket.ReleaseStaticJoint(); } - protected void LetGoRigidbody(Rigidbody grabbedRigidbody) { + protected virtual void LetGoRigidbody(Rigidbody grabbedRigidbody) { DebugLog("LetGoRigidbody"); if (grabbedRigidbody != null) { @@ -856,7 +856,7 @@ namespace Passer.Humanoid { this.grabbedRigidbody = false; } - protected void LetGoHandle(Handle handle) { + protected virtual void LetGoHandle(Handle handle) { DebugLog("LetGoHandle " + handle); if (Application.isPlaying) { if (grabbedHandle != null) {