Hello, everyone, I need a very special help with my script ... I will explain what he does or would do that, and maybe someone there could give me a light ...
It is the following, you pull a lever and it removes a rock in a road closed after the stone has been removed you will have 1 minute to pass or return the stone to appear on the site, but ... when the time for the birth stone is an error in the console and the stone does not appear, please help me with this problem ... thanks:
Here's the script:
Here is the error in the console:
It is the following, you pull a lever and it removes a rock in a road closed after the stone has been removed you will have 1 minute to pass or return the stone to appear on the site, but ... when the time for the birth stone is an error in the console and the stone does not appear, please help me with this problem ... thanks:
Here's the script:
--Fudera Otserver - script by F@bio
function onUse(cid, item, frompos, item2, topos)
local gatepos = {x=1052, y=585, z=10, stackpos=1}
getgate = getThingfromPos(gatepos)
local time_to_pass = 20 -- in seconds
local stoneID = 1304
if item.uid == 2557 and item.itemid == 1945 and getgate.itemid == stoneID then
doRemoveItem(getgate.uid,1)
doTransformItem(item.uid,item.itemid+1)
doCreatureSay(cid, "Teleport Ativado, 1 minutos para fechar.", TALKTYPE_ORANGE_1)
addEvent(addStone, (1000*time_to_pass), stoneID)
elseif item.uid == 2557 and item.itemid == 1946 and getgate.itemid == 0 then
doCreateItem(stoneID,1,gatepos)
doTransformItem(item.uid,item.itemid-1)
else
doPlayerSendCancel(cid,"Sorry not possible.")
end
return 1
end
function addStone()
if getThingfromPos({x=1052, y=585, z=10, stackpos=1}).itemid == 0 then
doCreateItem(1304,1,getThingfromPos({x=1052, y=585, z=10, stackpos=1}))
doSendMagicEffect({x=1052, y=585, z=10, stackpos=1}, CONST_ME_POFF)
return 1
end
end
Here is the error in the console:
Lua Script Error: [Action Interface]
in a timer event called from:
data/actions/scripts/POI/poiquest1.luanUse
luaDoCreateItem(). Tile not found