Hacker News new | past | comments | ask | show | jobs | submit login

Where you getting this information that tasks and IEnumerator can’t be used for games? I’ve been using Unity for 10 years and tasks and Ienumerators are used as coroutines all the time. Recently worked on Hello Kitty Island Adventure and almost all game logic goes through an async coroutine library. Most memory worries are in graphics and object overhead, not coroutine stack allocations.



I mean you don't want to use a Task for per frame work like and use a coroutine instead because tasks are pretty heap allocation heavy. When did I ever mention ienumerator?


IEnumerator is how Unity implements coroutines.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: