Here’s a little early holiday present for you. Unity.Physics 0.2.5-preview is now available to download using the Package Manager. Here’s a quick overview of what you can expect to find in this release:
Various bug fixes (yay!)
Updated a few package dependencies (Entities 0.3.0-preview.4)
Compatibility with LiveLink
Various Character Controller improvements
The Physics Sample received some small changes as well, including a package upgrade (LWRP 7.1.6)
For a more detailed list of changes, check out the changelog.
The LiveLink compatibility brings with it major improvements including but not limited to:
Conversion speed
Fixes for memory leaks when editing subscenes
Automatic instancing of colliders using the same shape, significantly decreasing memory usage
Please note that LiveLink compatibility is still experimental. Report any issues you find in this thread or using the Bug Reporter!
You may find that it’s also no longer possible to toggle the Debug Display and Simulation Type at runtime. This is not a bug, but intended behaviour.
Getting this on Mac
Unexpected exception System.IO.FileNotFoundException: Could not load file or assembly ‘Smash, Version=0.3.0.0, Culture=neutral, PublicKeyToken=null’ or one of its dependencies.
File name: ‘Smash, Version=0.3.0.0, Culture=neutral, PublicKeyToken=null’
Oh ok it takes an int3. Really don’t get that decision. So a UnityEngine mesh I have to create an array of int3, but oh wait Create then just copies them to an array of int. It forces a completely unnecessary copy, and unnecessary transformation for the end user.
Given most end users won’t use unsafe pointer ops, how about if you leave the NativeArray overloads and do a memcpy to int3? So keep supporting the format everything outside of Unity.Physics is using and make it more performant then most user implementations would do.
Sadly I can’t get it to work in a build. When I try Unity Physics in the editor and play mode, all is working well. But the moment I build the project and run it the cube just starts right inside the center of the plane that it’s supposed to fall on to.
Here’s what it does in playmode inside the editor:
OrneryHandsomeIlsamochadegu
Basically, I made a prefab for a character, and I’m converting it to Entity representation for faster instantiating and for setting data on it directly after instantiating.
Any ideas? I tried restarting Unity, deleting Library folder, etc… no success so far
We recently pushed out a patch release (0.2.5-preview.1) for the package that solves a couple small issues with LiveLink.
The NetCode samples breaking is a known issue and should be fixed in the next Entities release. If you’re feeling adventurous, you may try to fix it in the package manually. Find the file GameObjectConversionSettings.cs and in it add this line in the Fork method (at around Line 46): BlobAssetStore = BlobAssetStore,
This isn’t a fully tested fix and might bring its own problems so proceed with caution.