As a complete beginner in the programming world and in Unity, I’ve decided to write about my journey from the first steps of downloading the game engine – to the point I was actually able to replicate a game concept. I have no programming background, and I never used Unity before. The only experience that may count towards it is playing video games, which is really nothing if you need to ‘code’ a game.
So how is the whole idea started?
A few weeks ago Csaba sent me a message out of the blue and said ‘Yo, I give you homework. I would like you to create Space Invaders in Unity using Bolt.’
I was looking at the message and thought about how big the task would be. I knew that I won’t learn programming from a single task, but I was thinking that this might be my first steps. Even if I won’t go this way, I will have a better understanding of Unity.
I tried to figure out where to start, so I wrote down as much as I knew about the game. Last time I’ve seen Space Invaders I believe it was a mini-game in Fallout 4.
- Few lines of monsters move from left to right, when reaching the end they move one line down and repeat but this time right to left.
- The player controls a spaceship that can move left, and right and able to shoot projectiles, that hit and kill the monsters.
- The monsters drop bombs (randomly), and if the bombs hit the Player’s spaceship, the Player dies.
- The spaceship needs to be able to respawn and have certain amounts of lives.
It doesn’t sound too much, but I felt it is an impossible task. How shall I do that?
I opened unity.com and downloaded the Unity Hub. Installed Unity 2019.4.8f1 and added a new project I called S_I_1 (Space Invaders).
When I opened the project, I’ve got completely overwhelmed by the interface.
Unity is complicated!
I didn’t know where to start.
I was clicking on the screen, tried to select something. Read through the menus in the hope of finding something familiar. I even downloaded the help documents from their website, and that was a mistake.
It is HUGE! Thousands of pages, articles after articles. This is not where you would start, honestly.
I was thinking to close the program and do something worthwhile. Why I’m spending time on something I don’t understand? Something probably I will not understand as I’m not a programmer. The only thing kept me going that I had a very similar issue when I first met with Photoshop. When I first opened it, I was like ” Noooo way I will learn this”. But through tutorials, mentoring and practice I learned how to use it – well, at least on the level I need it.
So, I realised very quickly that I wouldn’t get anywhere this way, so I turned to Google to solve my problem.
Fortunately, there are plenty of tutorials, training and guidance about Unity available free on the web.
First I couldn’t find BOLT, so I googled it, and I found this fantastic tutorial.
The first one I used was for complete beginners. The reason why I say this video was super helpful as it is not only introduced BOLT to me but in the meantime reached me the basics about Unity. This one-hour training helped me to understand the basics: how to create scenes, objects, variables and so on. It also explained the basics, which is extremely handy as I found it at the beginning, the trivial stuff in Unity can be extremely difficult. Simply as I didn’t know I missed it or I didn’t know what I was looking for.
I missed the part of setting the cube as ‘game object’ and despite my BOLT flow was working correctly, nothing happened. It was annoying to find the step I skipped, but so rewarding when it started to work.
So, after a few hours of playing around with Unity, I managed to go through a tutorial, created something which was working (kind of).
Is this suffering or something rewarding?
And this was the point when I got the boost. It felt so good watching those ugly cubes running after a ball (which was actually a cube as well) and kicking it around. It was basic, ugly and I was following a tutorial step by step, but I made it.
I made those little cubes moving on the screen and ‘interacting’ with each others. I felt super cool.
The result was uplifting so much I wanted to carry on and do more and more and more. I assume this is the driving for game programmers, when they see their ideas becoming live, becoming a reality.
It is awesome.
The whole thing took about 3 hours. I am still very far from understanding Unity or anything complex, but I’ve managed to create a scene where the cubes are running after a ball and the ball bouncing off of them once they touch each other. Through this, I learned the basics and I had ideas about what to change on it.
Next time I will try to create the basics for the Space Invaders and see how far I can get without help.
Excerpt image is by Francesco Ungaro from Pexels