Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice
  2. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  3. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Editor error in unity 2018.3b8

Discussion in '2018.3 Beta' started by Pnvanol, Nov 17, 2018.

  1. Pnvanol

    Pnvanol

    Joined:
    Jan 11, 2016
    Posts:
    114
    Code (CSharp):
    1. UnityException: DestroyImmediate can only be called from the main thread.
    2. Constructors and field initializers will be executed from the loading thread when loading a scene.
    3. Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
    4. UnityEngine.Object.DestroyImmediate (UnityEngine.Object obj) (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.bindings.cs:322)
    5. UnityEditor.NormalCurveRenderer.FlushCache () (at C:/buildslave/unity/build/Editor/Mono/Animation/AnimationWindow/CurveRenderer/NormalCurveRenderer.cs:649)
    6. UnityEditor.CurveWrapper.Finalize () (at C:/buildslave/unity/build/Editor/Mono/Animation/AnimationWindow/CurveEditor.cs:54)
    7. UnityEngine.UnhandledExceptionHandler:<RegisterUECatcher>m__0(Object, UnhandledExceptionEventArgs)
    8.  

    I admit I have destroy inmediate in the scene, but havent got a clue where to start. By the way this message still allows me to play the scene...
     
  2. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,589
    LeonhardP and Pnvanol like this.