I need to get to work the StepOut, StepIn is working fine, help please
The error is error luadoremove item, item not found... have tried in many different ways but i cannot get it to work, or it gives me a nill error or this one
<movevent type="StepIn" uniqueid="10225" event="script" value="spa.lua"/>
<movevent type="StepOut" uniqueid="10225" event="script" value="spa.lua"/>
The error is error luadoremove item, item not found... have tried in many different ways but i cannot get it to work, or it gives me a nill error or this one
<movevent type="StepIn" uniqueid="10225" event="script" value="spa.lua"/>
<movevent type="StepOut" uniqueid="10225" event="script" value="spa.lua"/>
Lua:
function onStepIn(cid, item, position, fromPosition)
local itemid = 1386
local pos = {x=461, y=1374, z=10, stackpos=1}
if isPlayer(cid) == TRUE
then
doCreateItem(itemid, 1, pos)
end
return true
end
function onStepOut(cid, item, position, fromPosition)
if isPlayer(cid) == TRUE
then
doRemoveItem(pos, 1)
end
return TRUE
end
Last edited: