Search Unity

Crash when destroying scene object loaded from AssetBundles

Discussion in 'iOS and tvOS' started by Wawro01, Aug 5, 2015.

  1. Wawro01

    Wawro01

    Joined:
    Apr 23, 2014
    Posts:
    44
    Hi,

    I implemented asset bundles. I'm loading all levels from them and levels are loaded ok .But now when I try to destroy root object of loaded level, game will crash. It happens only on iOS. There is NO error or exception in editor. I've noticed that game will not crash when I include desired level in BuildSettings. (but still loading it from asset bundle). I am imagining why ActivateAwakeRecursively is called when destroying the objects ... this is strange for me. We are using unity 5.1.2p2 since there was some fix with crashes and AssetBundles, but unfortunately it didn't help.

    1. Exception Type: EXC_CRASH (SIGSEGV)
    2. Exception Codes: 0x0000000000000000, 0x0000000000000000
    3. Triggered by Thread: 1

    4. Thread 0:
    5. 0 soldiers 0x00edca90 Unity::GameObject::ActivateAwakeRecursivelyInternal(Unity::DeactivateOperation, AwakeFromLoadQueue&) (GameObject.cpp:209)
    6. 1 soldiers 0x00edcb3e Unity::GameObject::ActivateAwakeRecursively(Unity::DeactivateOperation) (GameObject.cpp:223)
    7. 2 soldiers 0x00fd599e DestroyGameObjectHierarchy(Unity::GameObject&) (GameObjectUtility.cpp:1307)
    8. 3 soldiers 0x00fd5c7a DestroyObjectHighLevel(Object*, bool) (GameObjectUtility.cpp:1468)
    9. 4 soldiers 0x00f5da44 DelayedCallManager::Update(int) (CallDelayed.cpp:178)
    10. 5 soldiers 0x00fdb2a4 PlayerLoop(bool, bool, IHookEvent*) (Player.cpp:1920)
    11. 6 soldiers 0x00e49332 UnityPlayerLoopImpl(bool)
     
  2. zuizuimei

    zuizuimei

    Joined:
    Aug 15, 2013
    Posts:
    16
    have you found the answer? this problem happen to me. it stop in WillDestroyGameObject(), PreDestroyRecursive().i build with unity3d 5.2.2f1 and xode 7.1.
     
    Last edited: Oct 26, 2015
  3. Wawro01

    Wawro01

    Joined:
    Apr 23, 2014
    Posts:
    44
    For me solution was to remove all light probes from all loaded scenes. We decided not to use them either, since old diffuse/mobile shader was over saturated with combination with light probes. But try to destroy objects recursively one by one, make debug.Log and you will see what object you were trying to destroy last, and there problem will be
     
  4. zuizuimei

    zuizuimei

    Joined:
    Aug 15, 2013
    Posts:
    16
    nice. i will try. thanks.
     
  5. bluescrn

    bluescrn

    Joined:
    Feb 25, 2013
    Posts:
    642
    Looks like I'm encountering this same issue 2 years later in 2017.1.0p4... Haven't tried deleting the probes yet though (it isn't exactly a solution...)

    Is it really going to be a choice of 'lightprobes or bundles: pick one'?...