My game doesn’t load the next level after building it?

My game doesn’t load next level…it works fine in unity but when I build it.it does not load next level… HTTPS://pkgamers.itch.io/redd-vs-black please check it out.

Hi Pramo, welcome to the community?

Are all of your scenes added to the build settings?

If you do not include all of the required scenes here, when you build your game, the scenes you’ve not include will not be in the build and errors are likely to happen.

Hope this helps :slight_smile:


See also;

1 Like

Yes… I included all my scenes in order. I thought problem with scene manager and even changed it to loadlevel(1). No spelling mistakes were there

1 Like

Hi,

Ok, so that’s a good start.

Could you zip up your project files and share them so I can take a look?

The forum will allow uploads of up to 10MB, if your project files (zipped) are larger than that you would need to use a service such as Google Drive or Dropbox, and then share the URL.


Updated Sat Sep 29 2018 20:31

Which scene is it that you are having problems with btw? As the menu loads, as does the game, and then the level restarts over and over each time I collider with a cube.


Updated Sat Sep 29 2018 20:36

You game is annoyingly addictive btw, I cant stop playing it now! :smiley:


Updated Sat Sep 29 2018 20:39

Ok, so after a lot of attempts, I finally got to the end of the first set of falling black cubes and then it was just endless white road with the score incrementing constantly. Is this where the next level is supposed to load?

Yes after the last row of black box… The level should end and next level should be loaded.i placed the end trigger right after that.but it keeps on going and does not completes.do I need to send the file which I exported(after build) or whole project (including assets etc)?

It would be easier for me if you could zip the whole project and either upload it here, assuming its 10MB or less, or, use Google Drive/Dropbox or similar, and then provide the URL.

If you give me the whole project I can just run it and debug, as opposed to having to try and recreate the issue with pieces of your project.

It will be removed from my laptop afterwards, don’t worry, I won’t steal anything :slight_smile:

Oops… I got no idea like that.just clearing my doubt.after all it’s just a simple game you are capable more than this why should I doubt you. Here’s the link
https://drive.google.com/file/d/1PiI_Pf_bYbgGBLKqQ20bShnUxo_ItKS4/view?usp=drivesdk

I seem to be having some difficulties downloading it, when I select download it opens a new tab and just keeps swirling. I will leave it a little longer. How big is the zip file?

It’s failing with a server 409 error!

It’s 224mb

Is that the zipped size? I’ve just “Added it to my drive” and it shows as 93MB, perhaps it hasn’t finished uploading or is corrupt?

The file isn’t right. It just tried to virus scan it before downloading it, via Google Drive, and that failed too.

You might need to re-upload it I think.

No actually it’s 224 and 93 after zipped.it works fine for me.when I click the link… It starts loading after some time
Ok I’ll reupload it and send u the link

Ah… ok, I’ll try again then, definitely seems to be problematic though :frowning:

Ok, it seems to be working now… that was very odd… never had that with Google Drive before, and I don’t think I’ve ever seen a 409 error before… lol… I have the zip file now… give me a few minutes to open it and take a look. :slight_smile:

When I zip it shows size as 97 but when I upload in drive it shows 93 is this a issue

https://drive.google.com/file/d/1EMzTtfjs_-LHxJAg3Ws3y95n9NaPvyl9/view?usp=drivesdk

Reuploaded it

Will try again.

This is looking more positive, I’m seeing the usual screens now via Google Drive - fingers crossed :slight_smile:

Hope it works :sweat_smile: btw thanks for Ur patience

1 Like

You’re very welcome. Unzipping now.

Thank god.help me with this… Struggling more than a week

No worries, just opening project now, I have a different Unity version so it’s just doing a update (your project, not Unity).

What exactly is it that you think detects the end of the level? I see all of the obstacle GameObjects, if I click on the highest numbered one (28) to try and get to where this level should end, I don’t see anything else in that area that would indicate some form of trigger collider or similar? Am I missing something?

Oh hang on, its something to do with the canvas isn’t it… bear with me…

I think this is your problem. You have your end GameObject as a child of the canvas. The canvas is being drawn to the camera, as such I don’t think you’ll ever actually reach it, because you can’t “touch” it so to speak.


Updated Sat Sep 29 2018 22:31

Ok, give this a go;

  • create a new empty GameObject in the Hierarchy in Level 1
  • set its Transform to 0, 3, 100. Rotation 0, 0, 0. Scale 1, 1, 1
  • name it “End”
  • add a Box Collider to it
  • tick the Is Trigger property of the Box Collider component
  • add your EndTrigger.cs script as a component
  • select all of your obstacle GameObjects and disable them (makes testing easier)
  • run the game

Your ball will now roll all the way along the track, hits the trigger, displays a message, loads the next scene.

To then tidy up, I’d suggest removing the “end” GameObject you have from the canvas. You also have an “end1”, not sure what that is, I didn’t check it out but if you don’t need it, get rid of it.

Don’t forget to re-enable all of your obstacles and save the scene.

You would then need to add a copy of the new end GameObject in the relevant location in each level.

Alternatively… if the only way to get a score is by travelling along the road, then you know that if they get a score of 99+ they have reached the end of the first level. You could remove the collider altogether and base progression purely on their accumulated score. Just a thought.

Hope this helps :slight_smile:

1 Like

Oh I see.so it was the mistake I didn’t notice.now what should I do.but how it runs fine unity editor then?

Privacy & Terms