I am using Unity 2019.3.15f1 to build a Coin Pusher game, main feature is using physics engine to simulate a coin pusher game table.
After the game launched, it will run 30 seconds to 2 minutes before crash.
I got a crash log like this:
1 libc.tgkill(tgkill:8)
2 libc.pthread_kill(pthread_kill:68)
3 libc.raise(raise:28)
4 libc.abort(abort:60)
5 libc.__fortify_chk_fail(__fortify_chk_fail:0)
6 libc.___clock_nanosleep(___clock_nanosleep:0)
7 libunity.0xb21bd8(Native Method)
8 libunity.0xb21c48(Native Method)
9 libunity.0xb0af74(Native Method)
10 libunity.0xb005c8(Native Method)
11 libunity.0x9f09b8(Native Method)
12 libunity.0xa064cc(Native Method)
13 libunity.0xa06370(Native Method)
14 libunity.0x2d871c(Native Method)
15 libunity.0x244e44(Native Method)
16 libunity.0x245170(Native Method)
17 libunity.0x244f58(Native Method)
18 libunity.0x2e9388(Native Method)
19 libunity.0x2d6720(Native Method)
20 libunity.0x26b1f8(Native Method)
21 libunity.0x26b22c(Native Method)
22 libunity.0x26b464(Native Method)
23 libunity.0x36cdd0(Native Method)
24 libunity.0x37f344(Native Method)
25 base.0x314050c(Native Method)
after running addr2line for libunity related messages I got this:
physx::Gu::PersistentContactManifold::reduceBatchContacts(physx::Gu::PersistentContact const*, unsigned int, float)
??:?
physx::Gu::PersistentContactManifold::addBatchManifoldContacts(physx::Gu::PersistentContact const*, unsigned int, float)
??:?
$x.56
??:?
physx::Gu::pcmContactConvexConvex(physx::Gu::GeometryUnion const&, physx::Gu::GeometryUnion const&, physx::PxTransform const&, physx::PxTransform const&, physx::Gu::NarrowPhaseParams const&, physx::Gu::Cache&, physx::Gu::ContactBuffer&, physx::Cm::RenderOutput*)
??:?
physx::PxcDiscreteNarrowPhasePCM(physx::PxcNpThreadContext&, physx::PxcNpWorkUnit const&, physx::Gu::Cache&, physx::PxsContactManagerOutput&)
??:?
void PxsCMDiscreteUpdateTask::processCms<&physx::PxcDiscreteNarrowPhasePCM>(physx::PxcNpThreadContext*)
??:?
PxsCMDiscreteUpdateTask::runInternal()
??:?
$x.235
??:?
JobQueue::Exec(JobInfo*, long long, int)
??:?
JobQueue::ExecuteJobFromHighPriorityStack()
??:?
JobQueue::ProcessJobs(JobQueue::ThreadInfo*, void*)
??:?
JobQueue::WorkLoop(void*)
??:?
Thread::RunThreadWrapper(void*)
??:?
It seems like telling me that the problem is located in PhysX engine. Then I found a post related: https://forum.unity.com/threads/debugging-unhandled-null-exception-in-editor-game-view.503475/
But after disable PCM(Persistant Contact Manifold) in physics settings, the crash remains.
Does anyone have any clue for this problem? Any thought or guess will be appreciated.
Thanks in advance.
What I have alread tried:
- Reduce rigidbodies.
- Increase Fixed Timestep in Time setting.
- Replatce mesh colliders with box colliders.
- Turn off/on Persistant Contact Manifold. (By selecting Legacy Contacts Generation)
- Upgrade to Unity 2019.4.4f1