Bom galera, a porta fica trancada e tal, mas quando eu uso a chave dá a mensagem:
"The key does not match."
Obs: No RME já botei a action id igual no script, 24000.
function onUse(cid, item, frompos, item2, topos)
local pausa = 10000
local door = {x=472, y=378, z=7, stackpos=1}
local ddoor = getThingfromPos(door)
local open_door = 5280
local itemU = 24000
local verify = 0
if item2.uid == itemU then
if ddoor.itemid ~= verify then
doTransformItem(ddoor.uid,open_door)
addEvent(close,pausa,door)
end
else
doPlayerSendCancel(cid,"This key can not be used here")
end
return 1
end
function close(door)
local to_close_door = 5279
local the_close_door = getThingfromPos(door)
doTransformItem(the_close_door.uid,to_close_door)
end
Pergunta
Aerdor 48
Bom galera, a porta fica trancada e tal, mas quando eu uso a chave dá a mensagem:
"The key does not match."
Obs: No RME já botei a action id igual no script, 24000.
function onUse(cid, item, frompos, item2, topos) local pausa = 10000 local door = {x=472, y=378, z=7, stackpos=1} local ddoor = getThingfromPos(door) local open_door = 5280 local itemU = 24000 local verify = 0 if item2.uid == itemU then if ddoor.itemid ~= verify then doTransformItem(ddoor.uid,open_door) addEvent(close,pausa,door) end else doPlayerSendCancel(cid,"This key can not be used here") end return 1 end function close(door) local to_close_door = 5279 local the_close_door = getThingfromPos(door) doTransformItem(the_close_door.uid,to_close_door) endAlguém sabe oq ta errado?
Rep+
Link para o comentário
https://xtibia.com/forum/topic/201969-erro-no-script-de-key-pra-abrir-porta/Compartilhar em outros sites
4 respostass a esta questão
Posts Recomendados