Yeah, I'm literally stuck on a simple Coroutine. In my Unity game I've been trying to figure out how to use something like this in a public static void:
StartCoroutine(ExampleCoroutine())
I understand that there is no way to use that line in a public static void, but I'm trying to find a workaround that would do the same thing. So far the internet hasn't been a help, but the closest I've gotten to my problem being solved was something about creating an instance. I didn't understand it because I am a mere novice, but it might be a lead as this is the error I get while creating:
error CS0120: An object reference is required for the non-static field, method, or property 'MonoBehaviour.StartCoroutine(IEnumerator)'
The IEnumerator that the Coroutine starts is marked public static, if that helps at all. Thank you for your time and humouring my stupidity
EDIT: I was asked to show more code, so here I go!
public static void NeedsToBeAccessedElsewhere()
{
StartCoroutine(NeedsDeley());
//Do Stuff
}
public static IEnumerator NeedsDelay()
{
//results
}