SpiderOT
™ツʂριԃҽɾσƚ➽ ٩(•‿•)۶★彡
hello i get this error
sometime not all the time
and sometime i found the door closed on player and they get debug
error
and the script
please need help fast
sometime not all the time
and sometime i found the door closed on player and they get debug
error
Code:
[10/09/2009 00:44:25] Lua Script Error: [MoveEvents Interface]
[10/09/2009 00:44:25] data/movements/scripts/closingdoor.lua:onStepOut
[10/09/2009 00:44:25] luaDoTransformItem(). Item not found
[10/09/2009 00:46:28] Lua Script Error: [MoveEvents Interface]
[10/09/2009 00:46:28] data/movements/scripts/closingdoor.lua:onStepOut
[10/09/2009 00:46:28] luaDoTransformItem(). Item not found
Code:
function onStepOut(cid, item, position, fromPosition)
local newPosition = {x = position.x, y = position.y, z = position.z}
if(isInArray(verticalOpenDoors, item.itemid)) then
newPosition.x = newPosition.x + 1
else
newPosition.y = newPosition.y + 1
end
doRelocate(position, newPosition)
local tmpPos = {x = position.x, y = position.y, z = position.z, stackpos = -1}
local tileCount = getTileThingByPos(tmpPos)
local i = 1
local tmpItem = {uid = 1}
while(tmpItem.uid ~= 0 and i < tileCount) do
tmpPos.stackpos = i
tmpItem = getTileThingByPos(tmpPos)
if(tmpItem.uid ~= item.uid and tmpItem.uid ~= 0 and isMoveable(tmpItem.uid)) then
doRemoveItem(tmpItem.uid)
else
i = i + 1
end
end
doTransformItem(item.uid, item.itemid - 1)
return true
end