I am trying to refactor my code from the EditorWindow calss to a couple of scripts and I then encounter this problem:> The type or namespace name 'MyClass' could not be found (are you missing a using directive or an assembly reference?) [Assembly-CSharp-Editor]
Structure:
> Assets>> AssetName>>> Editor>>>>> MyAsset.cs>>> Scripts>>>> MyClass.cs
MyAsset.cs:
namespace MyAssetNamespace
{
public class MyAsset : EditorWindow
{
private List MyClassList = new List();
// excluded the rest of the code here
}
}
MyClass.cs:
namespace MyAssetNamespace
{
public class MyClass : MonoBehaviour
{
public int SomeNumber { get; set; }
}
}
The error occurs in `MyAsset.cs` on `private List MyClassList = new List();` where I am unable to use `MyClass` even when they are within the same namespace.
I am using Unity 5.5.0f3, is there something about `EditorWindow` that prevents this from working?
↧