Wednesday 18 November 2015

I hate Unity3d engine

I hate Unity engine. I hate it so much on so many levels that I cannot even express my rage with human words.
Whenever I have an obstacle I need to surpass using unity engine I spend 1/4th of a time solving a problem and 3/4th of a time jumping around Unity so called architecture.

Not to look too far away - you cannot simply load something from code. Of course there is a way to do this Unity devs will say. All you have to do is put things in Resource directory...

Hell yeah you can. But guess what. Atlasing does not work on Resource directory OH SNAP.

So if you paid money for Unity PRO (once there was major difference between Free and PRO like atlasing support only in PRO) to get a functionality, you soon realise that you cannot use it as you wish.

No problem. There are ways to overcome this issue etc.

Next stop, the most fundamental thing in 2d game development, which Unity claims to support so well since version 4.5 or 4.6 w/e, is asset partitioning depending on densities of display you are working with.

Every single game I have worked on ended up having some kind of asset variants for various displays. SD/HD/UHD or whatever - you name it. Also sometimes we ended up redoing some layouts or displays for small screens - no problem.

In Unity this is almost impossible to get right out of the box. Even official presentations and docs end up recommending using hand crafted solution powered by... Resources folder.

Seriously... what? Come again? Res... what did you just say?! I guess Resources don't support atlasing but that is not the problem in eyes of Unity devs. Ok, TexturePacker it is. No problem, another tool another software.

The thing is.... how to put it lightly... That after about half year of working on a game you end up with things blowing up right in your face. The thing called Out of Memory error.

You build a game in Unity and it just fails because Unity 32bit runs out of memory. Someone, somehow, thought that it is perfectly fine to allocate memory for everything that is being currently processed in Resources folders along required dependencies to load each thing. We generate a package that is about 250MB but when stuff in Resources gets build the building process allocates somewhere around 2.8GB! Add two or three sprites more and you're done.

The Unity 64 bit removes this limitation but guess what you have to pay for an upgrade if you were already on PRO version ;)

And to rant some more. I remember them saying Unity 4 will stick for quite some time... Yeah they pretty much don't care about it for quite some time and I assume they will keep updating 5 probably till mid of 2016 and then announce another version that will require you to upgrade your license.

That's just pure fun. But hey, it can't be that bad... right? Of course not my friend! Unity 5 is being constantly developed and adds tons of new cool features (don't complain that after X years you still cant Find an object BY NAME in the scene when it's disabled, these are non important issues). Finally Unity acknowledged the need for SD HD support so they reworked how asset bundles worked and added this support for Variants.

Sounds cool? You simply select a directory where you HD assets are, label it as sprite-bundle. Tag it as HD variant and do same thing for SD sprites. All you have to do is some wiring in code and you are done. And it actually works! Amazaballs... it works untill it stops which happens probably 15 minutes later when you're done with their sample project and want to use it real-life project.

You start doing the same stuff you just did and you hit Hash Collision while building your asset bundle.

It doesn't care that you have two files at two different paths, what matters is the fact that both files are called background.png. Unity devs will ask `WHO would do that`, right? This is so obvious that they forgot to mention it in the docs. Like the limit on Resources folder or like what Graphics.setAllDirty() does except the fact that it sets all as dirty (that is exactly what the docs say - why even bother write this. I can read the function name for crying out loud, I am not a retarded. I even have a common sense and suspect what it does. What I want is some details and explantations on what it does. If its freaking public interface it is meant to be used, if so I wan't to know what. And that was just an example that first came to my mind but there is so much more to the docs one could write.)

It complains even when trying to make a bundle out of such complicated tree like so:
"bundle/foo/I_hate_unity.txt"
"bundle/bar/I_hate_unity.txt"

Where bundle was supposed to be the root of the asset bundle.

I have so much more I would like to share, but for now my rage got milder and I really have little to no time recently so I will just carry on doing my side projects and hopefully be back soon with something other than pure rage and destruction. Some day I will come in peace to share my experiences that I recently had plenty of.

PS: Last one thing. I also hate Unity community. Toy engine*, for toy games made by wanna be game developers that should stick with their toys not computers. So many noise and simply plain wrong answears produced by hords of developers for whom C# is a scripting languague.

OK, I am done now...

* I know its a bit harsh and not true but sometimes looking and the majority of content produced with Unity and community requests you can get this vibe.

1 comment:

  1. I like your post because your content is original. Your posts are always helpful to me. I really admire your effort.
    Fotosizer Professional Crack

    ReplyDelete