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

Lua How to add Couldown to a Teleport Scroll

Blysco

New Member
Joined
Oct 12, 2013
Messages
163
Reaction score
2
My Scirpt i want a Couldown for it !
Please help me

Code:
local newpos = {x=32369, y=32241, z=7}

function onUse(cid, item, frompos, item2, topos)
local inFight = hasCondition(cid, CONDITION_INFIGHT)
if not inFight then
doSendMagicEffect(getPlayerPosition(cid),1)
doTeleportThing(cid,newpos)
local tele = doCreateTeleport(1387, newpos, frompos) -- Creates teleport
addEvent(doRemoveItem, 5000, tele.uid) -- Removes teleport after 5 seconds
doCreatureSay(cid, "Teleportet back to Thais !" ,1)
else
doPlayerSendTextMessage(cid,25,"You can't use the teleport scroll if you are PZ LOCKED!!")
return true
end

    end
 
Back
Top