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 /
  • Help Room /
avatar image
0
Question by aaronmhargrove · May 09, 2016 at 01:44 PM · fatal errorkillkill playerfatal-error

Fatal error! What happened?

I am attempting to have asteroids (which spawn randomly) delete from the world after they hit a certain boundary. It was working fine a week ago and now that I changed it from -10 to -20 it crashes Unity no matter what I have the boundary set at, pegs the RAM, and gives the Unity error "Fatal Error! Size overflow in allocator." My player code is an exact mirror and it works correctly, so that confused me even further. I don't know if it is something I did with C# (not my native language) or if I am doing something Unity doesn't like. If anyone knows what this error means or has a possible solution please let me know! I only found one article on this and it was never answered. Here is the code associated with it.

 using UnityEngine;
 using System.Collections;
 
 public class Enemy : MonoBehaviour
 {
     public Transform astroid;
     public int fallBoundaryE = -20;
 
     public void Update()
     {
         if (transform.position.y <= fallBoundaryE)
         {
             GameMaster.KillEnemy(this);
         }
     }
 
 }

This is the code it calls from GameMaster

 using UnityEngine;
 using System.Collections;
 
 public class GameMaster : MonoBehaviour {
 
     public static void KillPlayer(Player player)
     {
         Destroy(player.gameObject);
     }
     public static void KillEnemy(Enemy astroid)
     {
         Destroy(astroid.gameObject);
     }
 }
 






Comment
Add comment · Show 1
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 Bonfire-Boy · May 09, 2016 at 01:57 PM 0
Share

What is it that is making you think this code is the source of the problem?

0 Replies

· Add your reply
  • Sort: 

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Vuforia fatal error, Size overflow in allocator, Unity 2017.3.0f3 0 Answers

Kill Player Method Doesn't Work ? 0 Answers

!CreateDirectoryRecursive(fullpath) fatal error, I've tried everything 2 Answers

Moved Project to new PC. Corrupted Artifact removed now game won't load 0 Answers

Cant Kill enemy with Raycast C# (SOLVED) 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