How do I remove drawn images & printed text?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
RBXcpmoderator12345
Citizen
Posts: 59
Joined: Sat Mar 07, 2015 11:53 pm

Re: How do I remove drawn images & printed text?

Post by RBXcpmoderator12345 »

not os.sleep i mean this function

Code: Select all

local clock = os.clock
function sleep(n)  -- seconds
  local t0 = clock()
  while clock() - t0 <= n do end
end
User avatar
s-ol
Party member
Posts: 1077
Joined: Mon Sep 15, 2014 7:41 pm
Location: Cologne, Germany
Contact:

Re: How do I remove drawn images & printed text?

Post by s-ol »

RBXcpmoderator12345 wrote:not os.sleep i mean this function

Code: Select all

local clock = os.clock
function sleep(n)  -- seconds
  local t0 = clock()
  while clock() - t0 <= n do end
end
Same effect as os.sleep, except it also wastes CPU power.

Clearly, here love is getting stuck in a loop that will take n seconds - it therefore can't do anything else.

s-ol.nu /blog  -  p.s-ol.be /st8.lua  -  g.s-ol.be /gtglg /curcur

Code: Select all

print( type(love) )
if false then
  baby:hurt(me)
end
Post Reply

Who is online

Users browsing this forum: Majestic-12 [Bot], slime and 2 guests