beliar34
Member
- Joined
- Feb 28, 2012
- Messages
- 307
- Solutions
- 7
- Reaction score
- 11
Code:
function onUse(cid, item, frompos, item2, topos)
local temple = getPlayerMasterPos(cid)
if hasCondition(cid, CONDITION_INFIGHT) == false then
if getPlayerStorageValue(cid, 80000) == 0 then
doSendMagicEffect(temple, 41)
setPlayerStorageValue(cid,80001,frompos)
setPlayerStorageValue(cid,80000,1)
doSendMagicEffect(temple, 41)
doTeleportThing(cid,temple)
doSendMagicEffect(temple, 41)
elseif getPlayerStorageValue(cid, 80000) == 1 then
doTeleportThing(cid, getPlayerStorageValue(cid, 80001))
setPlayerStorageValue(cid,80000,0)
end
else
doPlayerSendCancel(uid,"You can't use this scroll if you've in fight or get skull")
end
end
Teleport to temple but dont teleport back to exp, tfs 0.3.5, no errors in console