Search Unity

NavMesh (load from AssetBundle) Always Crash on iOS

Discussion in 'Navigation' started by nekokiller2012, Nov 19, 2015.

  1. nekokiller2012

    nekokiller2012

    Joined:
    Oct 22, 2012
    Posts:
    8
    As the title. I have tried unity 5.1.3, 5.2.2p4, 5.3.0rc will crash on iOS 6/7/8/9

    1. bake navmesh and build the scene to asset bundle.
    2. load asset bundle done and then use Application.LoadLevel to load the scene.
    3. using any NavMesh api will cause ios crash.

    example:
    use NavMesh.SamplePosition, will got error message : InvalidateNavMeshHit and then crash

    the same project same code, works fine on Editor / Android.
    only crash on ios.

    if using Application.LoadLevelAdditive( ) then NavMesh api works fine ! but you will got problems about the Light Maps ...
     
  2. nekokiller2012

    nekokiller2012

    Joined:
    Oct 22, 2012
    Posts:
    8
    example project attached (NavMeshTest.zip)
     

    Attached Files:

  3. nekokiller2012

    nekokiller2012

    Joined:
    Oct 22, 2012
    Posts:
    8
    ok, solved. check the 'Strip engine code*' ( in optimization of player settings ) will cause this problem, so uncheck it.
     
    Last edited: Nov 22, 2015
  4. jehovah0121qq

    jehovah0121qq

    Joined:
    Nov 14, 2013
    Posts:
    68
    What if you want to strip engine code? Which types (classes/structs/enums/...) are supposed to be written to the link.xml white list so that the game doesn't crash?