What’s New in Unity 5: Summary

In this article, you’ll give an overview of some of the new shiny features in Unity 5. By Brian Moakley.

Leave a rating/review
Save for later
Share

Epic Games came out swinging with the announcement that the fourth iteration of the Unreal Engine will be free outside of a small 5% cut of gross revenue.

Not to be outdone, Unity Technologies quickly took command of the stage by announcing the release of Unity 5, noting that the free version of Unity would have access to all the features of the professional version.

Then, to make crazy week even crazier, Valve officially announced their latest game engine called Source 2 which will also be free for all developers although the details of the program are still under wraps.

At this point, it’s not hard to feel like an audience member at an Oprah taping. Needless to say, it’s an exciting time to be making games!

We, here, at raywenderlich.com have produced a variety of Unity tutorials over the years, so naturally, we’re all very excited with the latest Unity updates. In this article, I’ll be providing an overview of some of the changes that Unity 5 brings to the table and in the process, covering the following major features:

  • Physical Shaders
  • Real-time Global Illumination
  • Reflection Probes
  • Audio Mixer
  • Physics Engine
  • Animator
  • WebGL
  • Metal & IL2CPP
  • 64 Bit Editor
  • Cloud Builds
  • Licensing Changes

There’s actually a whole lot more, but we didn’t want you to take a day off work to read this article! :]

Physical Shaders

Unity 5’s Standard Shader

Unity 5's Standard Shader

Unity 5’s Standard Shader

Practically, this means, you’ll be using one shader to do 95% of the heavy lifting.

That’s right, you’ll be using this one shader to tweak to your heart’s content to replicate a vast array of materials such as wood, metal, hair, skin, or even stone. The shader can take several textures for input and for those slots that you don’t use, they are optimized out of your project so there is no performance hit. According to Unity Technologies, the idea of physical based shading isn’t meant to produce “realism”, but rather, model how achieve a consistent look and feel in a variety of lighting situations. Basically, how things would really look under different lighting conditions.

For those shader writers out there gripping your chair in white knuckled panic, you can still write your own shaders in Unity and if you need to use any of the Unity 4 shaders, they are available to use as well. They are categorized under Legacy Shaders which tells us they won’t be around for much longer.

Unity Technologies hopes that you won’t have write any new shaders. In fact, in one article, Physical Shaders were referred as the “one shader to rule them all”. That said, for the indie developer this is a great tool to get awesome looking visuals without having to learn any of the shading languages.

Global Illumination

While Physical Shaders are enough to warrant an article in their own right, one of the biggest changes is known as Global Illumination. The idea behind Global Illumination is to calculate lighting effects not based just a global light source, but on reflective surfaces as well. This tends to be very expensive, but Unity gets around it by using a lot of pre-calcuations.

Unity has managed to make this scale from mobile to desktop, giving you the ability to create easy day night cycles in your games, but also create some dynamic realtime lighting to enhance certain moods. One big practical benefit is that this new system does away with Beast Lightmapping in Unity 4.

Mind you, you can still bake your lightmaps, but it’s now all done for you in the background so there’s no need to click a “bake” button anymore. This is what Unity calls “Iterative Light Baking”. Basically, once you finish making an adjustment on a light, Unity will automatically bake the results for you. If you change a different light, it will simply recalculate, and re-bake without you having to worry about it.

Reflection Probes

According Unity’s documentation, “a probe acts much like a camera that captures a spherical view of its surroundings in all directions.” The image is stored as CubeMap which you can apply on reflective materials. These probes can be realtime, but you can also have them baked if you are concerned about performance.

Audio Mixer

Mixing your audio has never been easier.

Mixing your audio has never been easier.

Mixing your audio has never been easier.

Typically, when working in play mode, any changes you make in a scene are dropped once stop the game. The mixer will actually keep your changes, allowing you to set your correct levels while the game is being played.

It will probably take time for some of us to get used to the idea of making lasting changes in play mode, and it may even cause a little confusion in regards to other GameObject and components, but it’s a great feature to have.

Physics Engine

Unity’s physics engine received a big upgrade in this latest release. The underlying PhysX engine was leveled up to version 3.3 which according to the documentation is an entire rewrite.

One big benefit was that Continuous Collision Detection (CCD) has been improved. CCD is useful when working with fast moving bodies. In previous versions of Unity, if a body moved too fast, it would pass through another, even with colliders enabled. According to Unity Technologies, this issue should be a thing of the past, but we’ll have to see in practice.

The wheel collider component also received a makeover. The wheel component can now be used to create realistic suspension and tire friction. Behind the scenes, Unity is using PhysX3’s vehicle SDK. You can use this to create your own vehicles as shown here.

Unity has also updated their cloth simulations. They’ve done away with the Interactive Cloth and Skinned Cloth replaced it with just Cloth. The idea was to give developers flexibility while also making it inexpensive. By default, cloth does not interact with the world. You have to add colliders and even then, cloth will not apply force to the world. It will only receive force. That way, it can be both dynamic while also being low cost to use in your game.