Coming from LibGDX to Unity

For a few years I coded a handful of games for the Android system using LibGDX then took a break. Somehow the coding bug has crept back in recently and I started searching for an easier/faster route. I stumbled upon Unity and thought to give it a try. However, I have found growing pains that have made me question my move.

I mainly code 2D games and find a few things difficult for my mind to wrap around.

  1. The coordinate system is foreign to me. I am used to using pixels and having the the bottom or top left start at 0,0. I don’t know what units Unity uses.
  2. The game code syntax seems intimidating and harder than what I am used to. For instance, It seems you have to call long lines just to get a sprite’s x or y. Instead of “sprite.x” or “sprite.width”, I have to access the GameObject, then “transform” than “position” then the “x”. I still don’t even know how to get a sprite’s width or height without coding a few long lines that don’t seem intuitive.
  3. I have gone through a few tutorials and find that they all accomplish the same thing but from a very different angle. This leads me to confusion because I don’t know which is the preferred way and I can’t remember all the different techniques.

I have heard that the Unity community is friend l so I thought I would ask your opinion on these things.

Thanks

I’ll be honest, I’m not sure if you are asking a question or just voicing your experience with Unity. I haven’t used LibGDX, so I have no clue how it works. Unity to me is fairly easy, but I have been using it a long time now and have learned a lot over the years and still continue to learn. It’s also not the first engine I’ve used, so when I started I had to just go in knowing they don’t do things the way other engines do.

Most of the time you’re going to have growing pains when switching engines or starting a new game engine when you haven’t used one in awhile.

The Unity community is fairly helpful. Most of us are Unity developers ourselves, so we do try to help when we can. We do like to see a person make an effort on their own, but if you get stuck or have questions, come back and ask and if someone can help, they usually do.

1 Like