• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Event with random time

Dankoo

Active Member
Joined
Sep 4, 2010
Messages
1,007
Reaction score
27
I want to make an event function

Like this:

LUA:
function onTime()
	addEvent(event, RANDOM TIME, cid)
return true
end

I got a suggestion, but don't know how to make it work for real:

LUA:
function onTime()
	addEvent(randomize, 1000, cid)
return true
end

local function randomize(l)
	local s = ''
	for i = 1, math.random(l) do
		s = addEvent (event,1000,cid)
	end
	return s
end

Bah the math.random part is missing... Any ideas, to make a script activate in a random value between 0 and 5 minutes?

Thanks!!!!
 
Back
Top