I was wondering how to turn this code into a specific time like every 5 minutes ~ 300 seconds with the minInterval being 90 seconds always
[code]
if AMG.UseTimer then
timer.Create( "StartMinigame", AMG.minInterval, 90, function()
StartMinigame( table.Random( mgType ), AMG.minLength )
end)
end
[/code]
Thanks!
What? you want this to repeat indefinitely every 5 mins?
[code]
if AMG.UseTimer then
timer.Create( "StartMinigame", 5 * 60, 0, function()
StartMinigame( table.Random( mgType ), AMG.minLength )
end)
end
[/code]
I have no idea what you're trying to do, but I'm just going to assume you're requesting something like this;
[lua]
AMG = {
TimerMins = 5,
UseTimer = true,
minInterval = 90,
minLength = ???
}
timer.Create("AMGTimer", AMG.TimerMins * 60, 0, function()
if AMG.UseTimer then
timer.Create( "StartMinigame", AMG.minInterval, 1, function()
StartMinigame( table.Random( mgType ), AMG.minLength )
end)
end)
end
[/lua]
Sorry, you need to Log In to post a reply to this thread.