Difference between revisions of "Core.yield"
From GiderosMobile
m (formatting) |
(----) |
||
Line 1: | Line 1: | ||
− | + | '''Available since:''' Gideros 2016.06<br/> | |
+ | '''Class:''' [[Core]]<br/> | ||
− | + | === Description === | |
− | + | Yield function running as background task. | |
− | |||
− | |||
− | |||
− | === | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
+ | Core.yield([number of seconds to wait])<br/> | ||
+ | Core.yield(true) -- yield for a single frame and disable auto yield<br/> | ||
+ | Core.yield(false) -- don't yield now, but reenable autoyield<br/> | ||
<source lang="lua"> | <source lang="lua"> | ||
Line 20: | Line 13: | ||
</source> | </source> | ||
+ | === Parameters === | ||
+ | '''state''': (number or boolean) number of seconds to yield or boolean to enable/disable auto yield<br/> | ||
− | + | ---- | |
− | + | {{Special:PrefixIndex/Core}} | |
− | |||
<br/> | <br/> |
Revision as of 17:05, 2 December 2019
Available since: Gideros 2016.06
Class: Core
Description
Yield function running as background task.
Core.yield([number of seconds to wait])
Core.yield(true) -- yield for a single frame and disable auto yield
Core.yield(false) -- don't yield now, but reenable autoyield
Core.yield(state)
Parameters
state: (number or boolean) number of seconds to yield or boolean to enable/disable auto yield