Last active
August 29, 2015 14:09
-
-
Save SethDusek/0fd2ece7615d25adc6bd to your computer and use it in GitHub Desktop.
I moved to gist instead of pastebin because it very nice
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
c = coroutine.wrap(function() | |
for i = 1,40 do | |
print(i) | |
if getfenv(c).yield==true then | |
print("HELLOOO") coroutine.yield() | |
end | |
print(getfenv().yield) | |
wait(1) | |
end end) | |
c() | |
wait(5) | |
getfenv(c).yield=true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment