Hi, I have made a teleport scroll but it doesn't seem to work, I dont get any errors though.
When I rightclick on the object ID: 5952 it says "You can not use this object." And nothing happens, what have I done wrong? Please help!
PHP:
local temple = {x=1000, y=1000, z=7}
function onUse(cid, item, frompos, item2, topos)
if getPlayerSkull(cid) then
doPlayerSendCancel(cid,"You cannot use this with a skull.")
return 0
else
doSendMagicEffect(topos,12)
doTeleportThing(cid,temple)
doSendMagicEffect(temple,10)
doPlayerSendTextMessage(cid,22,"You have been teleported to the temple By the powers of this scroll.")
doRemoveItem(item.uid,5952)
end
return 1
end
When I rightclick on the object ID: 5952 it says "You can not use this object." And nothing happens, what have I done wrong? Please help!