Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Physics Body and Burst Error

Discussion in 'Burst' started by Zeraphan, Mar 6, 2020.

  1. Zeraphan

    Zeraphan

    Joined:
    Nov 20, 2019
    Posts:
    14
    I am convering a prefab into an entity. As soon as I add the PhysicsBody.cs to the GameObject I start getting a Burst error:
    (0,0): Burst error BC1040: Loading from a non-readonly static field `Unity.Collections.LowLevel.Unsafe.UnsafeUtility.IsUnmanagedCache`1<Unity.Physics.BodyIndexPair>.value` is not supported

    Nothing in the rest of the error shows anywhere that it is my code for me to try and figure out what is going on. Removing the PhysicsBody goes back to no errors.
     
  2. dhbahr

    dhbahr

    Joined:
    Aug 11, 2019
    Posts:
    14
    I am also experiencing it since I upgraded to 0.7.0-preview19 tonight. Does not seem to hinder anything much (although my playground does not have much to be hindered either).
     
    destructor465 likes this.
  3. tertle

    tertle

    Joined:
    Jan 25, 2011
    Posts:
    3,647
    Don't think it's an issue with entities but the new collection package and burst 1.3p. Force downgrading burst to 1.2.3 solved this for our project. Waiting for a fix.
     
    destructor465 likes this.
  4. dhbahr

    dhbahr

    Joined:
    Aug 11, 2019
    Posts:
    14
    It actually happens to me with burst 1.2.3.
     
    destructor465 likes this.
  5. Kitties

    Kitties

    Joined:
    Mar 29, 2018
    Posts:
    1
    I have the save issue on unity 2019.3.3f1 with Burst 1.3.0 preview.4 and Collections 0.6.0 preview.
    Whenever i launch playmode with gameobjects having physicsbody.cs on them these errors appear in console.

    (0,0): Burst error BC1040: Loading from a non-readonly static field `Unity.Collections.LowLevel.Unsafe.UnsafeUtility.IsUnmanagedCache`1<int>.value` is not supported
    (0,0): Burst error BC1040: Loading from a non-readonly static field `Unity.Collections.LowLevel.Unsafe.UnsafeUtility.IsUnmanagedCache`1<Unity.Physics.BodyIndexPair>.value` is not supported

    upd:
    same on 2019.3.4.f1
     
    Last edited: Mar 8, 2020
    destructor465 likes this.
  6. destructor465

    destructor465

    Joined:
    Jan 30, 2016
    Posts:
    18
    I experiencing exactly same issue. It started with burst 1.2.3 for some reason (not sure which package update triggered it), then I upgraded burst to 1.3.0 as at first I thought that old burst is causing it, but it didn't solve it. Seems like it doesn't affect performance so that's good.
     
  7. schaefsky

    schaefsky

    Joined:
    Aug 11, 2013
    Posts:
    89
    Same issue Burst 1.2.3 Entities 0.70 Unity 2019.3.4f1
     
    KKCooler and nqphandev like this.
  8. MineLucky

    MineLucky

    Joined:
    Dec 27, 2014
    Posts:
    2
    Same issue.I downgrading Entities to 0.6.0 and Collections to 0.5.2,it worked for me.
     
  9. momiji_jin

    momiji_jin

    Joined:
    Feb 25, 2020
    Posts:
    5
    Me, too.
    My package version:
    Havok Physics for Unity 0.1.2
    Hybrid Renderer 0.3.5 ​
    in Unity 2019.3.3f1.
    When to stop, i have "A Native Collection has not been disposed, resulting in a memory leak. Enable Full StackTraces to get more details."
    I am looking to quickly deal with this issues~
     
  10. momiji_jin

    momiji_jin

    Joined:
    Feb 25, 2020
    Posts:
    5
    add a Physics Step Script Component about any GameObject(need add Convert To Entity Script Component) in Unity editor, (0,0): Burst error BC1040 disappeared. But still "A Native Collection has not been disposed, resulting in a memory leak. Enable Full StackTraces to get more details.", I think it's my side of the code.
     
  11. momiji_jin

    momiji_jin

    Joined:
    Feb 25, 2020
    Posts:
    5
    Update Collections package to 0.6.0 in PackageManager, nothing else was edited, run no error,nice !