Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This question was closed Dec 22, 2015 at 10:17 PM by Fattie for the following reason:

lo qual

avatar image
0
Question by Universalerror · Dec 22, 2015 at 08:39 PM · loadingscenesasyncloading screen

LoadLevelAsync coroutine reloads level repetedly

I have encountered a problem that has completely thrown me. I have a main menu with three options to start the game and a loading text that is managed by using LoadLevelAsync. My issue is that when I load the game from the first two options (Level attack and Standard) the game operates as normal with no issues. However, when I load the game from the third option (Endurance) the scene will constantly reload and occasionally cause the game to nearly crash. This is my code for the function.

(redacted)

Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image gjf · Dec 22, 2015 at 07:08 PM 1
Share

"(It's a mess, I know.)" :(

the best advice i can give is to clean it up first.

you've got control logic all over the place and loading from more than one place too - moving it to a single piece of code will help with clarity and make it much more readable for you and anyone who might need to help, although your errors might disappear if you rewrite this ;)

avatar image Universalerror gjf · Dec 23, 2015 at 08:53 AM 0
Share

Yeah, it was written a while ago when first starting Unity. I think that rewriting it would probably be the number one priority right now.

avatar image Fattie · Dec 22, 2015 at 10:16 PM 0
Share

UniversalError, I sent you a reward point for effort! Enjoy the UI system, it is incredibly easy to use.

1 Reply

  • Sort: 
avatar image
1
Best Answer

Answer by Fattie · Dec 22, 2015 at 10:15 PM

You simply

cannot do

what you are doing. Sorry for the bad news.

You must use Unity's UI system.

It is incredibly easy - it will take you literally less time than it took me to type this.

Click once to add a Canvas. Click again to add a Button.

alt text

You're done - go prepare for Christmas.

A useful tip for you when making your first UI is, generally select "Scale With Screen Size":

alt text

Fortunately there is literally nothing to learn with the UI system. If you do the two clicks I describe above you're a top expert. Nothing more to know.

Regarding the code you posted there are so many problems it would not be practical to address them. It is not conceptually possible to do what you're trying to do. Cheers and good luck.


screen-shot-2015-12-22-at-41232-pm.png (180.4 kB)
screen-shot-2015-12-22-at-41006-pm.png (41.7 kB)
Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Universalerror · Dec 23, 2015 at 08:33 AM 0
Share

I just want to be certain that I'm following correctly. Are you saying that I can only have a level loaded asynchronously by using UI components?

avatar image Universalerror · Dec 23, 2015 at 09:54 AM 0
Share

I've rewritten the code using the same methods as before but using logical structures (y'know, like any sensible coder) and it works now. I'm not sure what you meant when you stated that what I was doing wasn't possible.

avatar image Fattie Universalerror · Dec 23, 2015 at 02:57 PM 0
Share

good work, season's greetings

avatar image Universalerror Fattie · Dec 23, 2015 at 05:09 PM 0
Share

Seasons greetings to you too. Could you explain what you thought I was doing please? I honestly can't figure it out.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Switching scenes 1 Answer

loading progress scene slows down game framerate 1 Answer

Additive async loading breaks my lightmapping on mobile devices 0 Answers

Default Cursor hourglass during app load 2 Answers

Seamless Room Transitions 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges