lewis1234
Be Smart.
- Joined
- Oct 9, 2011
- Messages
- 108
- Solutions
- 1
- Reaction score
- 10
tfs 8.6 4.0
is there anyway someone can add it so when the teleport is created, it is also created with an actionid
is there anyway someone can add it so when the teleport is created, it is also created with an actionid
Code:
local createpos = {x=1090,y=1022,z=2} -- Every 15min where will the Teleport Appear
local topos = {x=947,y=1096,z=9} -- Where will the Teleport take you
local msg = "Pac man event has now closed! It will open again in 10 minutes! All participants get Ready to run!"
local timetoclose = 60 -- in second
local function remove()
local tp = getTileItemById(createpos,1387).uid
if tp ~= 0 then
doRemoveItem(tp)
doBroadcastMessage(msg)
end
end
function onThink(interval)
doCreateTeleport(1387, topos, createpos)
doBroadcastMessage("pac man event TP is now open!\nCatch the teleport within "..timetoclose.." seconds! Teleport is Located in Event Room.")
addEvent(remove,timetoclose*1000)
return true
end