Hello I’ve been taking the course on unity 2d and when I got to the section three video 27
it is displaying the error "error cs0029 cannot implicitly convert type ‘state’ to ‘state’ ".Please help with it.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[CreateAssetMenu(menuName = "state")]
public class state : ScriptableObject
{
[TextArea(30, 10)] [SerializeField] string StoryText;
[SerializeField] state[] NextStates ;
public string GetStateStory()
{
return StoryText;
}
public state GetNextState()
{
return NextStates;
}
}
The error is showing at the
return NextStates;