• 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!

Globalevent text above tp- Countdown

Mjmackan

Mapper ~ Writer
Premium User
Joined
Jul 18, 2009
Messages
1,424
Solutions
15
Reaction score
177
Location
Sweden
Hey anyone there able to give me the line for how to count down in 10 minutes?

It should show up: 10:00, 09:59, 09:58 etc..
 
Code:
local time, t = 10 * 60, 0
for x = 1, time do
     addEvent(doSendAnimatedText, t, pos, ""..os.date("%M:%S", time), COLOR_LIGHTGREEN)
     time = time - 1
     t = t + 1000
end
 
Code:
local time, t = 10 * 60, 0
for x = 1, time do
     addEvent(doSendAnimatedText, t, pos, ""..os.date("%M:%S", time), COLOR_LIGHTGREEN)
     time = time - 1
     t = t + 1000
end
Thanks, a school teacher actually helped me though. :)
 
can you give me an example how to change it? and how do i add it to globalevents? in a new file?

@vvglex

Edit this on the script:

POSITION OF TELEPORT : {x = 303, y = 265, z = 15 }

In GlobalEvents.xml put:

Code:
<globalevent name="time" interval="2000" script="nameofscript.lua" />

And the save the script with the name you put in GlobalEvents.xml example:

Saved: nameofscript.lua
Code:
local time, t = 60 * 60, 0
for x = 1, time do
     addEvent(doSendAnimatedText, t,{x = 303, y = 265, z = 15 }, ""..os.date("%M:%S", time), COLOR_LIGHTGREEN)
     time = time - 1
     t = t + 1000
end
 
Back
Top