D
D
Denis Mashanov2017-01-19 17:38:40
Unity
Denis Mashanov, 2017-01-19 17:38:40

How to work with coroutines?

Good evening everyone. Please tell me how to work with coroutines correctly, and how to do so that after 100ms, perform the actions below yield return. I was able to do it, but when the object moves and the delay is 0.1 second, instead of performing it once, it performs many times. What should I do?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Олег Погребняк, 2017-01-19
@LoneRay

Вот, наверное, то, что ты хочешь.

IEnumerator f()
{
yield return new WaitForSeconds(.1f);
действия;
}

Без кода сложно разобраться.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question