[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Sleep
- From: "Del Buono, Matthew Paul" <delbu9c1@...>
- Date: Wed, 13 Oct 2010 17:42:55 +0000
I think you missed the "non busy" part.
There's no built in sleep but it should be trivial to make a binding for it. I've also seen people use select() from luasocket for this purpose.
Sent from my Verizon Wireless BlackBerry
From: Gabriel Duarte <email@example.com>
Date: Wed, 13 Oct 2010 14:26:26 -0300
To: Lua mailing list<firstname.lastname@example.org>
ReplyTo: Lua mailing list <email@example.com>
Subject: Re: Sleep
local start = os.clock()
while os.clock() - start < length do end
On Wed, Oct 13, 2010 at 2:20 PM, Henning Diedrich <firstname.lastname@example.org>
is there a sleep function that is
- allows for ctrl-C
- doesn't get stuck
- does not require a C extension
I tried busy, system call and sockets from
http://lua-users.org/wiki/SleepFunction for the above reasons they
don't work for me.
Is there a rock offering a simple C-programmed sleep?
It's for a very simple game world tick with the focus on
demonstrating (other) principles, and ease of getting to run
Linux User #471185
Rio de Janeiro - RJ
(55) (21) 9463-7760 -> Mobile
(55) (21) 2464-9302 -> Home
(55) (21) 2529-5080 -> Work