Posted by member 37809 on 2006-05-03 11:29:00 link

tnl is probably too busy laughing at newbie coding to respond... :D
more like, too busy with school. one down, a project and one (more exam) to go. and where do you get the idea that i laugh at newbie coding? i laugh at most code. especially when the code laughs at you first. doesn't matter who writes it.

anyhow, when i released 0.5, i forgot to include the sample lua file for tests. it's in the 0.5 source, and likely has a test case that will use timer.lua.dll; an important detail that isn't explicitly documented is that, yes, timer.lua.dll still requires that you load timer-0.5, since by peeking in that file you will notice that it calls its bangs.

personally i don't use timer.lua.dll because i'm accustomed to timer-0.5's way of doing things (asynchronously). except i don't like step.rc *Timer config.

i use http://tnl.iamserio.us/litestep/lslua/timer.lua [already i see something broken with my code (it doesn't free timer instances)].

untested, but then your thing looks like:
local timer = require 'timer'
local msgbox = lslua.message_box

bang_woot = timer.new {
  delay = 5000;
  action = function() msgbox 'done' end
}