Someone help me to get door position to set player there
To change this 1,2,3 to door position
To change this 1,2,3 to door position
Code:
local storage = 55565
local open_door
function onUse(cid, item, frompos, item2, toPosition)
if(getPlayerStorageValue(cid, storage)) ~= -1 then
if(item.uid == 1225) then -- north / south
open_door = 1226
elseif(item.uid == 1223) then -- east / west
open_door = 1224
end
doTransformItem(item.uid, open_door)
doTeleportThing(cid, {x = 1, y = 2, z = 3})
else
doPlayerSendTextMessage(cid, MESSAGE_EVENT_ADVANCE,"You not complete postman quest!")
end
return true
end