Obi Official Forum
Bug / Crash ArgumentNullException: Value cannot be null. Parameter name: key - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Cloth (https://obi.virtualmethodstudio.com/forum/forum-2.html)
+--- Thread: Bug / Crash ArgumentNullException: Value cannot be null. Parameter name: key (/thread-2703.html)



ArgumentNullException: Value cannot be null. Parameter name: key - diegoaguirreh - 16-01-2021

Hello everyone! 

Hope you have a great weekend. LongStory-Short Story im getting this error 

"ArgumentNullException: Value cannot be null.
Parameter name: key
System.Collections.Generic.Dictionary`2[TKey,TValue].FindEntry (TKey key) (at <9577ac7a62ef43179789031239ba8798>:0)
System.Collections.Generic.Dictionary`2[TKey,TValue].TryGetValue (TKey key, TValue& value) (at <9577ac7a62ef43179789031239ba8798>:0)
Obi.ObiTriangleMeshContainer.GetOrCreateTriangleMesh (UnityEngine.Mesh source) (at Assets/Obi/Scripts/Common/Collisions/ObiTriangleMeshContainer.cs:78)
Obi.ObiColliderWorld.GetOrCreateTriangleMesh (UnityEngine.Mesh mesh) (at Assets/Obi/Scripts/Common/Collisions/ObiColliderWorld.cs:229)
Obi.ObiMeshShapeTracker.UpdateIfNeeded () (at Assets/Obi/Scripts/Common/Collisions/ColliderTrackers/Trackers3D/ObiMeshShapeTracker.cs:38)
Obi.ObiColliderBase.UpdateIfNeeded () (at Assets/Obi/Scripts/Common/Collisions/ObiColliderBase.cs:189)
Obi.ObiColliderWorld.UpdateWorld () (at Assets/Obi/Scripts/Common/Collisions/ObiColliderWorld.cs:362)
Obi.ObiUpdater.BeginStep (System.Single stepDeltaTime) (at Assets/Obi/Scripts/Common/Updaters/ObiUpdater.cs:40)
Obi.ObiFixedUpdater.FixedUpdate () (at Assets/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:54)"


I'm using Unity 2020.2 and I everything was fine until I updated to the new Obi cloth.

Please HELP! I'm going to lost my job if I don't figure this out soon.


RE: ArgumentNullException: Value cannot be null. Parameter name: key - josemendez - 16-01-2021

You have a MeshCollider in your scene, whose input mesh is null.

This is a known bug in 5.6 that will be fixed in upcominf updates. For now, the workaround is simply to ensure all MeshColliders in your scene have a proper reference to a mesh.


RE: ArgumentNullException: Value cannot be null. Parameter name: key - diegoaguirreh - 16-01-2021

(16-01-2021, 10:10 AM)josemendez Wrote: You have a MeshCollider in your scene, whose input mesh is null.

This is a known bug in 5.6 that will be fixed in upcominf updates. For now, the workaround is simply to ensure all MeshColliders in your scene have a proper reference to a mesh.
Hi! Okay, I had to start from 0 not really something good. I had to get a mesh and part by part asking a collider and an obi collider.

I found that the Mesh Collider with Obi Collider crash while testing. Thanks!