Unity Continues to Steadily Improve
UnityI know I may have mention this a few times before, but SpriteKit for iOS9 was a disaster. Although it included some really cool features (SKAudioNode) and the addition of GameplayKit, it seemed broken, supporting older versions of iOS (7 and 8) was a pain and there was little to no feedback from Apple. Eventually, the release was stabilized and the company I worked for released their educational game. I then started to cheat on SpriteKit by learning Unity, before pivoting to using it solely professionally.
Since then, I’ve written about the differences between SpriteKit and Unity, and how I feel that SpriteKit is dead. Unity, on the other hand, has released a ton of new features over the last two years including built-in analytics, Cloud Build, and Remote Settings, while 2017 had massive 2D improvements (2D Sprite Atlas, Sprite Masks, Sprite Physics Shape) and launched Cinemachine and Timeline.
Unity has almost listened to the community and is slowly offering a more modular solution by separating their engine out into packages. Moreover, although there are three main releases per year, there are weekly incremental updates and bug fixes. The underlying message is very positive for developers and companies who need to invest into a solution for their given projects.
Here are some of the new features I am most looking forward to over the coming releases:
New Editor UI
The Unity Editor UI isn’t pretty, and hasn’t been updated since I remember trying it first back in 2008. Version 2018.3 will sport a minor redesign with flat icons and a modern font, while there will a future ‘opt-in’ full redesign next year that I’ll defo try out once available.
Unity for Small Things
Unity for Small Things is a closed-alpha solution for creating smaller, faster, lighter experiences that is targeted towards Playable Ads and Games in Messaging Apps but also relevant for entry-level mobile devices too. Based on a small ECS (Entity Component System) core, it is modular based which an advanced compression pipeline. In short, builds will be smaller and faster than WebGL. Interestingly, code can be ‘written’ visually by defining components in the Editor. As the runtime supports Web, Android and iOS, it’ll be interesting to test Unity for Small Things once it is available in open beta.
SVG Importer
Released with 2018.2, SVG Importer (presently a preview package) imports SVG files into Unity projects.
The SVG Importer allows you to create sprite assets with a very small file size that will retain their quality at any resolution.
Presently the importer only supports the 2D system (i.e. not the Canvas UI), while generated sprites cannot be colored like regular sprites. In a quick test, an imported SVG was almost 10x smaller in size than a 256x256 PNG. Hopefully we’ll soon see Canvas support, if the generated sprites are performant which such a reduction in asset size, I will probably solely utilize SVGs within my projects.
Memory Profiler
Pretty much a no brainer, being able to more accurately determine where memory is used (and potentially leaked) is something everyone wants to use ASAP!
Pixel Perfect Camera
Not something I needed yet, but good to know that a Pixel Perfect Camera is now available as a preview package. Pixel Art isn’t going anywhere anytime soon, and this feature has been long requested by the community.
Support for using .java and .cpp source files as plugins in a Unity project
You now have the ability to add .java (as well as .cpp and .a) source files to Unity project plugin folders. These files will be recognized as Unity plugins and compiled into the APK without requiring the user to build libraries separately in Android Studio. The plugin code remains a part of the Unity project, eliminating the need to create a separate Android Studio project.
Again, not something I am often in the need of, but useful to have the option of.
Android
ARM64 is now an Android Target Architecture (when using IL2CPP). Gone are the Android Device Filters (FAT, x86 or ARMv7), with a more understandable Target Architecture (ARMv7, ARM64, x86) which can be automatically split into multiple APKs on build.
Google Play Instant allows players to try a 10MB version of a game without having to install it first. The new plugin builds Instant projects and can run them on connected Android devices.
Java (along with cpp and a) source files are now recognized as Unity plugins and compiled into the APK. The plugin code remains a part of the Unity project, eliminating the need to create a separate Android Studio project to build a library.
Improved Prefab Workflow
After years of shying away from the issue, its hard to believe that “nested prefabs” are almost here. In the Improved Prefab Workflow talk by Ciro Continisio, it is clear that the new prefabs are so much more than simply nested, and will be a potential game changer for designers. Cannot wait to try them out.
Entity Component System, Jobs, Burst Compiler
ECS is something I really need to invest time into trying out. All the demos and comparisons highlight the performance benefit, while it is clear that this is the future (althogh the ‘traditional’ MonoBehaviour approach isn’t going anywhere for a while).
TextMesh Pro
Unity bought TextMesh Pro in 2017, and now includes it by default in 2018 version. Unity’s UGUI Text solution is quite limited, not very performant and will be eventually deprecated in favor of TextMesh Pro. TextMesh Pro uses an advanced rendering technique (Signal Distance Field) which requires only one asset to be generated per font, as opposed to bitmap fonts which require a font table for each font size. As a somewhat simplified view, it’s almost like SVGs and PNGs where SVGs can be scaled to any size and remain crisp, while PNGs need to be rendered for each specific size. Moreover, TextMesh Pro offers more advanced options. I haven’t actually used TextMesh Pro before, but will be utilizing it in all my future projects.
Unity’s Evolving Best Practices
Let me dispel a rumor right now, you should not be afraid of using the Animation component, we have no plans at this time to deprecate or remove it.
Although this flies in the face of the Unity documentation which had (doesn’t seem to anymore) listed this component as legacy and shouldn’t be used. For simple UI animations, use a script instead of either animation systems. Not really a ‘new feature’ but somewhat new information.