Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bug / Crash  Obi crash after reload scene
#1
Im using obi rope on my character when I start the game the rope works perfectly but when I reload the scene on play or build I'm getting this error.
going to a different scene is working properly but if I load the scene with obi rope twice it crashes.

IndexOutOfRangeException: Index 0 is out of range of '0' Length.
Unity.Collections.NativeArray`1[T].FailOutOfRangeError (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Collections.NativeArray`1[T].CheckElementReadAccess (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Collections.NativeArray`1[T].get_Item (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Obi.BurstColliderWorld+IdentifyMovingColliders.Execute (System.Int32 i) (at Assets/Utility/Obi/Scripts/Common/Backends/Burst/Collisions/BurstColliderWorld.cs:154)
Unity.Jobs.IJobParallelForExtensions+ParallelForJobStruct`1[T].Execute (T& jobData, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Jobs.JobHandle:ScheduleBatchedJobsAndComplete(JobHandle&)
Unity.Jobs.JobHandle:Complete()
Obi.BurstColliderWorld:UpdateWorld(Single) (at Assets/Utility/Obi/Scripts/Common/Backends/Burst/Collisions/BurstColliderWorld.cs:117)
Obi.ObiColliderWorld:UpdateWorld(Single) (at Assets/Utility/Obi/Scripts/Common/Collisions/ObiColliderWorld.cs:397)
Obi.ObiUpdater:BeginStep(Single) (at Assets/Utility/Obi/Scripts/Common/Updaters/ObiUpdater.cs:56)
Obi.ObiFixedUpdater:FixedUpdate() (at Assets/Utility/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:46)

You can check my prefab below.
Thanks in advence.
[Image: jDirCVG]


Attached Files Thumbnail(s)
   
Reply
#2
(15-02-2024, 03:01 PM)kayrakocaeli Wrote: Im using obi rope on my character when I start the game the rope works perfectly but when I reload the scene on play or build I'm getting this error.
going to a different scene is working properly but if I load the scene with obi rope twice it crashes.

IndexOutOfRangeException: Index 0 is out of range of '0' Length.
Unity.Collections.NativeArray`1[T].FailOutOfRangeError (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Collections.NativeArray`1[T].CheckElementReadAccess (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Collections.NativeArray`1[T].get_Item (System.Int32 index) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Obi.BurstColliderWorld+IdentifyMovingColliders.Execute (System.Int32 i) (at Assets/Utility/Obi/Scripts/Common/Backends/Burst/Collisions/BurstColliderWorld.cs:154)
Unity.Jobs.IJobParallelForExtensions+ParallelForJobStruct`1[T].Execute (T& jobData, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) (at <ad3eaa0878d94cbe8e45f9c494d71647>:0)
Unity.Jobs.JobHandle:ScheduleBatchedJobsAndComplete(JobHandle&)
Unity.Jobs.JobHandle:Complete()
Obi.BurstColliderWorld:UpdateWorld(Single) (at Assets/Utility/Obi/Scripts/Common/Backends/Burst/Collisions/BurstColliderWorld.cs:117)
Obi.ObiColliderWorld:UpdateWorld(Single) (at Assets/Utility/Obi/Scripts/Common/Collisions/ObiColliderWorld.cs:397)
Obi.ObiUpdater:BeginStep(Single) (at Assets/Utility/Obi/Scripts/Common/Updaters/ObiUpdater.cs:56)
Obi.ObiFixedUpdater:FixedUpdate() (at Assets/Utility/Obi/Scripts/Common/Updaters/ObiFixedUpdater.cs:46)

You can check my prefab below.
Thanks in advence.
[Image: jDirCVG]

Hi!

This seems unrelated to the rope/solver, as the stack trace points to a collider. Would seem like the engine is trying to access a collider that no longer exists in the scene. However, I've been unable to reproduce this myself.

Could you send a small scene/project that reproduce this issue to support(at)virtualmethodstudio.com so that I can take a closer look?

thank you!

kind regards,
Reply
#3
(16-02-2024, 07:54 AM)josemendez Wrote: Hi!

This seems unrelated to the rope/solver, as the stack trace points to a collider. Would seem like the engine is trying to access a collider that no longer exists in the scene. However, I've been unable to reproduce this myself.

Could you send a small scene/project that reproduce this issue to support(at)virtualmethodstudio.com so that I can take a closer look?

thank you!

kind regards,
Thanks for the reply!
I will prepare a small project for you on monday when I go to office. I'm a staff so can't go there right now.

kinder regars,
Reply
#4
(16-02-2024, 03:57 PM)kayrakocaeli Wrote: Thanks for the reply!
I will prepare a small project for you on monday when I go to office. I'm a staff so can't go there right now.

kinder regars,

Hi there!

I just answered your email. Unfortunately I haven't been able to reproduce this issue, tried a variety of Unity versions and platform combinations to no avail. Enabling Burst's safety checks in order to try and catch the exception you posted the stack trace for doesn't seem to have any effect.

Looking at the stack trace itself, it points to BurstColliderWorld.cs line 154. There, the collision material for the current collider is accessed: the error complains about a collider using a collision material that doesn't exist. This shouldn't be possible in the project you sent, since none of the ObiColliders in the scene (left/right HolsterTrigger and Hooks) use collision materials. Hence, this line of code isn't even executed in the sample project.

I've tried adding a collision material to all 4 ObiColliders in the scene so that the offending line of code does get executed, but this wasn't enough to trigger the exception either.

kind regards,
Reply
#5
(20-02-2024, 09:10 AM)josemendez Wrote: Hi there!

I just answered your email. Unfortunately I haven't been able to reproduce this issue, tried a variety of Unity versions and platform combinations to no avail. Enabling Burst's safety checks in order to try and catch the exception you posted the stack trace for doesn't seem to have any effect.

Looking at the stack trace itself, it points to BurstColliderWorld.cs line 154. There, the collision material for the current collider is accessed: the error complains about a collider using a collision material that doesn't exist. This shouldn't be possible in the project you sent, since none of the ObiColliders in the scene (left/right HolsterTrigger and Hooks) use collision materials. Hence, this line of code isn't even executed in the sample project.

I've tried adding a collision material to all 4 ObiColliders in the scene so that the offending line of code does get executed, but this wasn't enough to trigger the exception either.

kind regards,
Hi Jose!

I noticed that there is a problem .meta files in my project. We use to push git and my coworker clone project in his pc there is no error. I think we should somehow get rid of corrupted meta files.

Thank you for your interest.
Reply