I have done exactly the same, still whenever ball reaches the lose collider, GAME OVER scene is not loading
Hi Mayank,
- What does happen when the ball makes contact with the lose collider?
- Does the ball have a CircleCollider2D component on it?
- Do you see an error message about the scene āGAME OVERā not being added to the build settings?
On a related note, please copy/paste your code into your posts and add the code formatting characters both before and after it, rather than taking screenshots. It can be more difficult to read the code when itās in a screenshot, especially when using a mobile device. It also prevents those who are willing to help you from copy/pasting parts of your code back to you with suggestions/corrections. You will get more responses when you make things easier for people generally
Screenshots are however very useful for error messages and details from the Unity editor.
Hope this helps
See also;
- Forum User Guides : How to apply code formatting within your post
The error is-
āScene āGAME OVERā couldnāt be loaded because it has not been added to the build settings or the AssetBundle has not been loaded.
To add a scene to the build settings use the menu File->Build Settingsā¦ā
I have added the circle collider2d
Hi,
Are you saying you added these things after reading my post, or, you had already added these and are still experiencing the same problem?
It was already added.
So, you are getting the error message which states the scene isnāt in the build settings, but it is in the build settings?
yes, itās not working , itās still showing the same error
Seems a bit odd.
Could you zip up your project files and share them with me, Iād be happy to 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.
Okay, where should I upload the file?
^^^
Great - I will take a look now, probably be about 5-10 minutes by the time itās opened, compiled and I can run the game.
okay, Thank you
Hi,
Ok, bit faster than I thought
The first thing I tried was to rename your scenes, removing the spaces in their names. āGAME OVERā became āGameOverā and āLEVEL 1ā became āLevel1ā.
I re-ran the game, same error.
I then opened the Build Settings, selected each scene and pressed the DEL key to remove them.
I then re-added them from the Scenes folder within Assets, clicked on Save Project and re-ran the game - worked perfectly.
Try just the last steps here, e.g. donāt worry about the rename, but remove them and then re-add them from the build settings, save the project and re-run, see if that resolves the issue for you too.
It worked, Thank You so much.
Youāre very welcome, Iām glad you can move forward with the course again
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.