Introduction

This is a 2D topdown game involving different types of basic traps. All you need is to control the character and manage to escape while collecting as many coins as you can. Easy to play, hard to get a high score!

By playing the game, you'll be able to experience 2 scenes. One is trying to get into the car by grabbing the key first, while bypassing the bomb, going through the spike gate and avoiding the fires. The other is to drive the car rushing to the finish line, escaping from the bullets, lasers, and passing the spike strip. Try not to be hit by the traps, or the limited health won't guarantee a win. Meanwhile, try to collect the coins on the road since they are worth a lot in the final score.

Have fun!


Post Mortem

There are a few points I'd like to address in learning Unity and developing the game.

First, apart from the player's key input, this game is mainly triggered by colliders. Box collider, circle collider, and mesh colliders for walls and different traps. However, whether to add rigid body components depends on the exact actions I need. If the trap is transformed by scripts like the bomb or the fire ring, or is exerted by a force like the bullet, then a rigid body component must be added. On the other hand, custom animation without the rigid body like the spikegate, spikestrip and laser could also be used. An extra help of no rigid body is that, the gameobject won't be limited by other colliders, for example, the laser would go through the wall instead of beating the wall and being destroyed. 

Second, there are some tricks I figured out in solving problems about the animations. To change the animation states by a delayed time, I tried to use StartCoroutine, yield and WaitForSeconds at the beginning, only to find out it didn't work. Then, I set a transition bool parameter controlled by scripts using Time.delataTime, still failed. Finally, I deleted the transition bool parameter and used a script to control the play of animation state directly, it worked. This is specifically useful for letting the spikegate close and reopen for some seconds.

Another trick I find out is to use animation events to tell the script when a state begins and ends. GetCurrentAnimatorStateInfo(0).IsName() didn't work. This trick is used for waiting and playing the end animation of scene 1 (car starting up) and then load to scene 2.

What's more, to rotate a gameobject smoothly,  Quaternion.Slerp may be used. However, it is not the case with the fire ring which turns around and around and around in 360 degrees. Using slerp results in rotating to the angle less than 180 degrees. Therefore, it won't rotate from 0 to 359, instead, from 0 to 1. To solve this problem, a very simple line can be introduced -- transform.Rotate(new Vector3(0, 0, 100) * Time.deltaTime * speed).

At last, this game is still in very early development. The game mechanics and gameplay runs well. But there is still a lot more work remaining in the visual part.


Appendix

Here is the design draft of the game.


Download

Download
2D Top Down Game-MacOS-Haoshu.app.zip 33 MB

Comments

Log in with itch.io to leave a comment.

Great work! I love the game mechanism design and the sound effect. This game was done well. I can feel the PH system adds much more fun to it! I think the visual Can be more consistent and refined. Cool!

I loved the outcome of this game. The way you kept a clear concept through the story and also made it simple but also the game itself is pretty engaging and difficult. Well done.

I have to say that the dev logs are so complete and i get to know how you come up with the idea and each sketch. Also the retro-futuristic aesthetics is so cool.

Really tough for its simplicity! Well designed, good concept drawings and execution from your concept. The bombs are very tough in the first level. I really enjoy the fact that it feels masterable despite its simplicity, deceptive and clever. Consider adding more levels! Great game so far.

I loved the design of this game when you presented it in class. Its really fun to get to play it. I love the avatar design, your assets are amazing and the driving the car is a great touch to the game. Your levels are well thought out. The gameplay itself is quite difficult, but kudos for making this game. It kept me hooked. 

I was so impressed when you demo'd the game in class. It definitely hits the aesthetic you are going for and you showed a lot of ingenuity from the avatar/player transfer to your second level when you start driving the car. I enjoyed the difficulty. Great job! 

I love to see your sketches of how you wanted the game to be and love how you made it exactly how you envisioned. The are matches your sketches amazingly. Good job.

The game mechanics I think are really great and the whole game experience is very complete and rich. Although the gameplay drove me crazy at times because it was really difficult for me and I would always die, it must have been a good game design. Very interesting.

This game is amazing. I love the consistent aesthetic and a lot of obstacles, which makes game more playful.

This game was super entertaining, I found myself very challenged to complete it and to keeps my hearts, which of course makes me want to play even more. Also I love the consistent aesthetic it is super well executed. 

I think this game had a good mix of difficulty and pace because I kept dying but replaying! Also, I totally forgot that having more than one life in a game was an option I could use; your game inspired me to think more about that element in my future work.

This is such an engaging game, reminded me of all the recent lightweight games streamed on twitch with close to impossible levels. I genuinely enjoyed playing through it and getting better each run. It's not hard for me to see some seasoned speedrunner mastering this game.

Oh boy, I think you touch a nice challenge level for the player to get motivated to play.  I had to so focus on playing this game because I do not want to die but complete it! I really wanted to get the car but it took me a while. navigating different ways according to the various obstacles, I think, keeps the player engaged. I wich I could do this.   

Not gonna lie, I am a little bit in awe of this game! It's definitely hard and frustrating to play, but you've done a really good job at creating a challenge that doesn't bore the player. I wanted to finish the game, no matter what! I also enjoy the different ways you set up obstacles throughout the game and how you varied the players interactions with the levels. Honestly, fantastic job!