Kodeco Forums

How to Make a Game Like Jetpack Joyride in Unity 2D – Part 3

In the final part of this series, you will generate some coins and lasers, construct a scrolling background, all to some fancy beats.


This is a companion discussion topic for the original entry at http://www.raywenderlich.com/69675/make-game-like-jetpack-joyride-unity-2d-part-3
1 Like

Sir? i have a problem.
MissingReferenceException: The object of type ‘GameObject’ has been destroyed but you are still trying to access it.
Your script should either check if it is null or you should not destroy the object.
UnityEngine.Object.Instantiate[GameObject] (UnityEngine.GameObject original) (at C:/buildslave/unity/build/Runtime/Export/UnityEngineObject.cs:95)
GeneratorScript.AddRoom (Single farhtestRoomEndX) (at Assets/Scripts/GeneratorScript.cs:131)
GeneratorScript.FixedUpdate () (at Assets/Scripts/GeneratorScript.cs:85)

Great tutorial, thanks so much

Hi! I’m trying but I can’t make it shot and destroy the lasers. How it can be possible?

This tutorial is long out of date so I may not work on the latest Unity versions. I’ll give it a whirl and let you know. Cheers!

Thank you man! This will be great. I’m kinda new at game production, and this tutorial helped me a lot. Oh, it’s still working at 4.3. See ya and thanks again!

I really enjoyed this tutorial, took me about 2 days to go through and I have to admit, I’ve learned so much!! Way more than what I’ve learned from watching video tutorials online. Thank you again! Cheers!

1 Like

I’m glad it was helpful! Cheers!

Hi i am having trouble with the lasers and coins. As i put in the parameters in the objects folder with the laser and coins_v prefabs, when i press play it seems fine until i die. When i play again I just go straight through them. And also i am having trouble with the ui when i can’t respawn or play again.

Thanks,

Kirill,

Very nice tutorial! I was able to follow and make changes to make it run on Unity 5.x,
such a nice tutorial deserves an update. Here is a link to my Google Drive with the entire project for Unity 5.x users. Rocket Mouse

Thank you so much for the tutorial
I am running unity 5.5.0 and I am actually looking for a way to calculate the distance
I mean, every time the mouse is moving forward, there has to be a counter in meters indicating how much did he moved forward
Can you help me doing such thing?

Thank you for the great tutorial…!! I’m beginner with Unity, I’m really like it!

Can I export build to mobile Android?

This tutorial is more than six months old so questions are no longer supported at the moment for it. We will update it as soon as possible. Thank you! :]