Re: Lua coroutine using
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Lua coroutine using
- From: Enrico Colombini <erix@...>
- Date: 2008年10月27日 17:16:10 +0100
Didro wrote:
(because AFAIK we can't add Lua code to early created coroutine)
If you don't want to use many coroutines, you could add code indirectly,
by having a coroutine execute a list of functions from a table that you
update by inserting/removing/replacing functions (in that case you
shouldn't use ipairs to walk the table, but check the index with #table
after every routine execution).
It may or may not be practical, depending on your usage.
Enrico