You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting the following message while I am trying to attach World.cs and Chunk,cs script into the respective game objects.
"The script don't inherit a native class that can manage a script"
Please suggest what needs to be done.
Might be a little late with this, but the issue you have is likely because of the naming of the files/classes.
The attached scripts in your comment are named Code_Chunk.cs and Code_World.cs, but they should be Chunk.cs and World.cs as the class names inside them are called Chunk and World
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Chunk : MonoBehaviour {
....
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class World : MonoBehaviour {
....
}
So the solution is that you either do ONLY ONE(1. or 2.) of the things below:
Rename the files: Code_Chunk.cs to Chunk.cs and Code_World.cs to World.cs
Rename the class names: public class Chunk : MonoBehaviour to public class Code_Chunk : MonoBehaviour and public class World : MonoBehaviour to public class Code_World : MonoBehaviour
I am getting the following message while I am trying to attach World.cs and Chunk,cs script into the respective game objects.
"The script don't inherit a native class that can manage a script"
Please suggest what needs to be done.
Code_Chunk.cs.txt
Code_World.cs.txt
Thanks in advance
The text was updated successfully, but these errors were encountered: