Sometimes when I start my game, I get pointless warnings. I do not know where they come from and I do not have any objects that address a script that does not exist. How can I remove or fix these messages?
Console:
Inspector:
When I right click on the icon of the file in the inspector I get two possible options. Both of them do not work or when I try to click on them nothing happens.
Inspector context menu:
To fix just delete ALL the meta files in the assets folder and reopen your project. Unity should rebuild all the script references. Also make sure to remove all compile errors.
It happens when the file and the name class has not the same name.
Example:
public class Cube : MonoBehaviour
In this case, Unity is not able to link the file and the class. Both have to have the same name.
public class SingleCube : MonoBehaviour
I had this same issue as well. I think it's caused by deleting the default scene but not changing the "Scenes in Build" in the build settings. Here's how I fixed it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With