• 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 /
avatar image
Question by Lemoln · Dec 02, 2013 at 04:30 PM · androidcrashloadingcompiling

Android level doesn't want to work after Application.LoadLevel

I made an entire game level (not very big) and made a simple menu with a "START" button. On the PC everything worked fine, but after installing it on two different devices the game crashes after a while loading the level. The menu loads fine, the button works (I made it dissapear before loading the level) but the level just wouldn't work. I created an empty level, using the same player prefab and a simple empty terrain and it loads fast and works fine! The size of my .apk is 110 mb, if it can help... Please tell me what to do!

Comment

People who like this

0 Show 12
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 meat5000 ♦ · Dec 02, 2013 at 04:52 PM 0
Share

Lots of people have experienced this very issue when loading a level from OnGUI.

Use OnGUI as a trigger but perform loadlevel in a separate function.

avatar image Lemoln · Dec 02, 2013 at 05:26 PM 0
Share

I'm using Raycast, not OnGUI...

avatar image meat5000 ♦ · Dec 02, 2013 at 05:27 PM 0
Share

Raycasting a plane as a button?

avatar image Lemoln · Dec 02, 2013 at 05:29 PM 0
Share

Raycasting a 3D Text, but doesn't matter, yes.

avatar image jacksmash2012 · Dec 02, 2013 at 05:34 PM 0
Share

When you run it in the editor and load the level, are there absolutely no errors in the console at all? Errors may crash the app on the device but may not be obvious in the editor (for example, a null pointer exception).

Show more comments

1 Reply

· Add your reply
  • Sort: 
avatar image

Answer by haim96 · Dec 02, 2013 at 06:06 PM

Hi,

i had also issues with android, every thing look fine on PC but on android thing goes wrong. to find out what is go wrong i did the following:

in your android SDK you should have file named "monitor.bat". it should be in a folder named "tools". open this monitor and run your app while your device connected to the USB in debug mode. make sure you can see your device on the device panel (upper left). if you don't pull it out and reconnect it again. if still not work make sure your android device have proper usb driver installed (check device manager).

after you got your device connected run the app and look at the bottom section. this is the run time log (also called catlog). you may find there run time errors that unity doesn't show on editor. in my case i had reference to missing prefab. not sure how the editor skipped that but he did. hope this will help you some how.... good luck!

Comment

People who like this

0 Show 3 · 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 haim96 · Dec 02, 2013 at 06:08 PM 0
Share

by the way, if you able to "build and run" from unity the monitor should work fine...

avatar image Lemoln · Dec 03, 2013 at 01:59 PM 0
Share

Didn't help(

avatar image haim96 · Dec 03, 2013 at 02:15 PM 0
Share

well, this is not s solution but a way to find a solution. did you look at the log? any strange red lines (error)?

i'm almost convinced that if things doesn't work only in android these should pop in run time.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

18 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity android game not working and it crashes 2 Answers

Game crashes as soon as splashscreen is displayed in android 3 Answers

Problem with terminating apps on Android 1 Answer

Android Plugin made the app break on relaunch. 1 Answer

Android 5 (lollipop) Crash Fatal signal 7 (SIGBUS) 4 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