Hello, i have a script, for example, when i pull a lever a wall dissapear, i want to make it appear again after X time, but i don't know how, somebody tell me to use addEvent, but i have no idea how to use this function, help please
AddEvent(Function, time, nil)
function onUse(blabla)
-- This is the custom made function to do whatever happens after AddEVent timer runs out
local function MyFunc()
doCreateItem etc
end
blablabla
blablabla
AddEvent(MyFunc, 10000, nil)
end
AddEvent(doCreateItem(1337, {x=37, y=37, z=37}), 10000, nil)
AddEvent(doCreateItem(1337, {x=37, y=37, z=37}), 10000, nil) -- incorrect
AddEvent(doCreateItem, 10000, 1337, {x=37, y=37, z=37}) --correct