Inspiration

2 Cars is my favorite mobile game of all time. It required the player to control 2 cars to dodge obstacles. This game builds on top of the existing 2 Cars by making obstacles come from two directions and creating an extra entity to control.

What it does

It allows users to control 2 portals on the left and right and implicitly control a middle portal that will always be perfectly between the left and right portal. Each portal has a corresponding color. Colored balls will fly from left and right, and the users have to position the portal properly to catch the matching colored balls but avoid different colored balls. The user cannot miss any ball and cannot catch a non-matching colored ball.

How I built it

I used Unity and coded the game in C#.

Challenges I ran into

This is my first project in Unity, so I wasn't familiar with a lot of the features. It took me so long to figure out how to detect collision. I spent 2 hours trying to figure out why my sprites weren't detecting collision until someone pointed out to me that since my game is 2D, i have to call OnTriggerEnter2D instead of just OnTriggerEnter since the Z axis may not align. Understanding Unity's differences between 3D and 2D functions was a huge challenge.

I also struggled for about an hour to get the play button to work. I didn't realize that buttons had to belong to a canvas for it to register clicks. I figured this out by running around the room and looking for people working on Unity to help me.

I also forgot to bring a mouse and had to use Unity with a touchpad which was very difficult.

Accomplishments that I'm proud of

I'm very proud I was able to code up this game completely in such a short amount of time. I had no Unity nor C# experience beforehand and had to figure a lot of things out. I'm proud how fun this game ended up being and how much I have learned in such a short amount of time.

What I learned

I learned so much about Unity and C#. I leaned: how game components in Unity interacts, how to pass game component classes to one another, the difference between trigger and collision of rigid objects, the purpose of canvas and its relationship with button and text, how to incorporate human input into the game and restrict human input, and lastly and versatile Unity is to be able to export into different apps in the end.

What's next for 3 Portals

First, I plan to export this out for both IOS and Android, which is just a few clicks. Next, I plan to add some quality-of-life features like pause and highscore tracking. Last, there's some extra game mechanics I think can be added like different types of balls. Overall though I think the app is quite complete for launch onto the app stores soon, and hopefully it can be come viral :)

Built With

Share this project:
×

Updates