Note: this is an article dedicated to the windows platform. What am I going to show may or may not apply to other platforms. Those pesky native crashes If you are a long term unity developer, it must have happened to you: Unity suddenly closes itself and shows the dreadedRead More →

20/03/2023 update I wrote a new demo that doesn’t need to use GPUInstancer. Code is now available on github. Note that I also updated the code to use GraphicBuffers instead than ComputeBuffers. For the game I am currently developing, Gamecraft, we are using Svelto.ECS for the game logic, Unity ECSRead More →

A recent tweet asking about how to achieve zero allocation code in Unity inspired me to write a short piece about the importance of memory allocation in c# and game development. C# wasn’t initially designed for game development, but today, thanks to Unity, ECS and Burst, we can achieve greatRead More →

Finally I found the time to play with unmanaged arrays and Memory<T>/Span<T>. In order to investigate possible improvements of the data structures used by Svelto.ECS, I wanted to know what the fastest way to set elements in a preallocated array could be. Using the very powerful BenchmarkDotNet and with theRead More →

If you need a fast and reliable (read very good to avoid collisions) hashing algorithm (not cryptographic), look no further, Murmur 3 is here to the rescue. Take it from here, it’s compatible with Unity3D. Directly translated from the c++ version. More info on Wikipedia and on this definitive answer on stack overflowRead More →

If it’s the first time you visit my blog, please don’t forget to read my main articles on the subject before to continue this post: http://www.sebaslab.com/ioc-container-for-unity3d-part-1/ http://www.sebaslab.com/ioc-container-for-unity3d-part-2/ It’s finally time to share the latest version of my Inversion of Control container, which I named Svelto IoC, which I will keep updatedRead More →

This post can be considered partially outdated as my mind changed quite a bit since when I originally wrote it. First of all, I would never suggest to write a game launcher in Unity now. Use instead .net or the latest version of mono with xamarin. Mono library embedded with Unity 4 is tooRead More →

Unity 3D is a well designed tool, I can say that. It is clearly less painful to use than UDK, no matter what its limitations are. However, as I keep on saying, the c# framework is still full of bad design choices, probably unfortunate inheritances from unity script (why don’tRead More →

recently I needed to compress a binary stream that was getting to big to be serialized over internet. I could not find any way to compress files easily, so eventually I used a 3rd party library that works very well in Unity3D (web player included): SharpZipLib I suppose the followingRead More →

For a long time I wanted to make some experiments with Photon Network Engine at home. During my professional experience, I worked on several multiplayer games, therefore I was pretty curious about it. Exit Games provides two versions of Photon Network Engine: the traditional Photon Server edition and the new Photon CloudRead More →