From 879a715b09892699e2b9dd3ed1e1f48f32a1c157 Mon Sep 17 00:00:00 2001 From: Pascal Serrarens Date: Mon, 22 Sep 2025 07:56:21 +0200 Subject: [PATCH] Add check for destroyed gameobjects --- Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs b/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs index a656542..7de4b33 100644 --- a/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs +++ b/Runtime/HumanoidControl/Scripts/Interaction/HandInteraction.cs @@ -327,6 +327,9 @@ namespace Passer.Humanoid { bool grabHandle = false; bool grabHandleInSocket = false; foreach (Collider collider in colliders) { + if (collider == null) + continue; + GameObject obj; Rigidbody objRigidbody = collider.attachedRigidbody; if (objRigidbody != null)