Making a RTS game #49: Optimisation tips & tricks (Unity/C#)

Let’s talk of possible optimisations for our Unity game!

Mina Pêcheux
CodeX
Published in
16 min readFeb 17, 2022

--

⬅️ Tutorial #48: Various fixes, improvements and clean-ups| TOC | Interlude #4: Improving the healthbars ➡️

📕 Get the ebook and bonus material on Gumroad!
🚀 Find the code of this tutorial series on my Github!

In the last episode, we talked about very down-to-earth fixes and refactors to improve our game. Those are of course essential, but they are not the only way to make your game better! In particular, as we are nearing the 1-year anniversary of this tutorial and implemented a lot of systems, I thought it would be a good idea to take a step back and discuss optimisation

Optimisation is obviously an important topic for video games since they usually require you to run code in real-time but with limited resources (especially on mobile platforms). It’s the key to running your game on low-end platforms, to meeting some app store criteria (like the time-to-first-display constraint) and overall just to using less resources (in terms of CPU, memory, energy…).

As explained in several official Unity talks (that I’ll try and sum up in this article), there are plenty of things you should be cautious about as you improve and…

--

--

Mina Pêcheux
CodeX
Writer for

I’m a freelance full-stack web & game developer. I’m passionate about topics like CGI, music, data science and more! Find me at: https://minapecheux.com :)