I tried using flip() but it was a very small delay. I dont want to use time() because doing it that way is very complicated. Is there any other way to make a pause.
\132 is the scattered dot emoji. \129 is the checkerboard emoji. \128 is the horiz rectangle emoji.\146 is the star emoji. I want a pause between every cycle of the for loop
this is my code:
for i=1,4 do if (i==1) then print("\132\132\132 \132\132\132",36,63,7) end if (i==2) then print("\129\129\129 \129\129\129",36,63,7) end if (i==3) then print("\128\128\128 \128\128\128",36,63,7) end if (i==4) then print("\146game over\146",36,63,7) end end |

1


function wait(seconds) local i for i=1,seconds*30 do flip() end end |
Example : wait a quarter of a second :
wait(0.25)



using time()
isn't so bad..
--setup if (something) startTime = time() + optionalDelay ..... --check (on update) local now = time() if ((now >= startTime) && (now < startTime + 1)) then --do phase one elseif ((now >= startTime + 1) && (now < startTime + 2)) then --do phase two elseif ((now >= startTime + 2) && (now < startTime + 3)) then --do phase three elseif ((now >= startTime + 3) && (now < startTime + 4)) then --do phase four end |
*not tested
Put this all inside some kind of if (dead)
check to run during Game Over conditions
[Please log in to post a comment]