What things cause this message?
The content was stopped because a fatal content error has been detected.
This is throwing me in two scenes that load as StreamPlayer,
With the other if it is working correctly should look for things that can cause this fatal message ?
I feel like when you see the blue screen of the dead T_T
3 Answers
3
Just ran across this again today. We’ve seen it here a couple of times on the projects we’ve worked on. We believe it has either to do with how generics are broken in the version of mono that unity is using or the Component.GetComponent functions have a bug in them that randomly show their ugly head.
To fix this, in the code, go through all references to GetComponent, GetComponents, GetComponentInChildren, and GetComponentsInChildren and make sure they refer to the gameObject for these functions.
So rather than:
void TestBehaviourFunc()
{
Renderer myRenderer = GetComponent<Renderer>();
}
you would use
void TestBehaviourFunc()
{
Renderer myRenderer = gameObject.GetComponent<Renderer>();
}
If this doesn’t work, I’d suggest looking for anything that might be nesting generics, where a class taking a generic parameter has a function taking a different generic parameter.
Example:
class TestGeneric<T>
{
public TestFunc<G>()
{
}
}
should be
class TestGeneric<T>
{
public TestFunc(Type secondType)
{
}
}
The second is a bit clunkier, but at least it doesn’t crash the web player.
On some browsers (eg. Chrome and IE) it is likely to cause a cache overflow. I had the same problem and converted 3000 lines of successive spaghetti code into several functions to make it running simultaneously. Now it also runs on Chrome and IE not causing the plugin crash.
For more information:
http://forum.unity3d.com/threads/177077-Max-amount-of-variables-Crashing-Chrome-and-IE-running-in-Firefox
I’ve seen this message caused by huge constructor (5000+ lines) that was only initializing a dictionary (string → List of 350 strings). Don’t ask why…
That was “fixed” by splitting it into two functions.
will accept any comments as to contribute something to tell me that may be doing wrong to someone else to happen? was solved without doing anything or is it something specific or is about many things together? something I could indicate where to start looking, do not ask for the solution, only the generic causes
– anon26777563i also have that problem, and don't know why... it seems happen uncertainly
– anon69579597