Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 /
avatar image
0
Question by Lambastard · Aug 07, 2014 at 12:27 AM · crashc++

Assertion failed, sphere.radius>=0.0f

After some very innocent tweaks to formerly functional code (I added a rigidbody to my camera object, then I removed it again), Unity now crashed on me whenever I try to run my scene.

The following are the text contents of the Microsoft Visual C++ Runtime Library box that pops up:

 "Assertion failed!

 Program: C:\Program Files(x86)\Unity\Editor\Unity.exe
 File: ..\..\Foundation\src\Sphere.cpp
 Line: 456

 Expression: sphere.radius>=0.0f

 For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts

 (Press Retry to debug the application - JIT must be enabled)

 [Abort][Repeat][Ignore]"

Now, an old forum threat recommended checking the cameras for potential errors, so I just deleted the camera altogether. Unity still crashes.

Looking at the VC++ docs also didn't give me anything useful, I'm afraid.

I'd be quite greatly grateful if anyone could point me at the likely source of this problem.

Comment
Add comment
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

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by maximinus.thorus · Aug 17, 2014 at 10:04 PM

Edit: After cleaning up all my code i finally got around to addressing this since the problem didn't go away. I'm procedurally generating all my meshes, and found I get the crash precisely when i set the mesh collider. Now that i can see triangles again i realize at some point i'm multiplying something too many times so my shiny new collider would be stretched in parts waaaay far away. Visually, it renders, but the warped collider is too large. From the editor it looks like at least one quad stretches hundreds or thousands of kilometers from the origin. Whoops.


I found this answer from Graham Dunnett here: http://forum.unity3d.com/threads/bugs.226498/

"These 'errors' are asserts coming from Unity's camera/rendering code. Unity is trying to sort game objects and the sorting is going all wrong. When I have seen this happen before it's because a camera matrix is no longer orthogonal, so, the right, up and at vectors are no longer at 90 degrees to each other. The sphere issue I think is coming from PhysX, and indicates that a bounding sphere has been computed as having a radius of zero. This all leads me to think you have a messed up camera matrix, possibly with a scale of 0,0,0. You might want to find your cameras and take a look a their transform in the inspector.

Don't worry about the OnGUI() message - the editor is implemented using the same gui functions you know and love, and the call stack is basically just saying that the editor had a problem."

None of my cameras have a scale of 0,0,0; but i'm recursively instantiating some objects and i'm digging into the physX hint right now. ...

Comment
Add comment · 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

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.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

unity creashes when using a pinvoke with input string 1 Answer

return char** from C++ DLL 0 Answers

My game has got a lot of crashes on Android Platform, ??? libunity.0x39be38 Caused by java.lang.Error 0 Answers

Unity iOS - "Assertion at reflection.c:6869" only in Development Build 0 Answers

build crashes 1 Answer


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