Ir para conteúdo

Posts Recomendados

E ae galera, olha eu aqui again! sarcastic.gif

 

Estou precisando de ajuda com alguns erros que estão aparecendo no console.

 

Olha só:

 

Script da rope em actions\scripts\rope:

 


--rope sistem--

  function onUse(cid, item, frompos, item2, topos)
  npos = {x=topos.x, y=topos.y, z=topos.z}
  if item2.itemid == 28 then
   return 0
  end 

  if item2.itemid == 384 then
   npos.y = npos.y + 1
   npos.z = npos.z - 1
   doTeleportThing(cid,npos)

  elseif item2.itemid == 418 then
   npos.y = npos.y + 1
   npos.z = npos.z - 1
   doTeleportThing(cid,npos)

  --hole or stair to rope items--

   elseif item2.itemid == 469 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 470 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 475 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 476 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 479 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 480 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 482 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 484 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 485 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 489 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 392 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 383 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 385 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 484 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 408 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 409 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 410 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 427 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 428 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 429 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 430 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end

   elseif item2.itemid == 433 then
   npos.y = npos.y + 1
   downpos = {x=topos.x, y=topos.y, z=topos.z+1, stackpos=255}
   downitem = getThingfromPos(downpos)
   if downitem.itemid > 0 then
   doTeleportThing(downitem.uid,npos)
   end
  --END hole or stair to rope items--
   else
   return 0
   end

   return 1
  end

 

 

ropef.png

 

Script da destroy field rune em actions\scripts\destroyfield:

 


function onUse(cid, item, frompos, item2, topos)
 fieldpos = topos
 fieldpos.stackpos = 254
 fielditem = getThingfromPos(fieldpos)

 if getPlayerMagLevel(cid) >= 3 then
 if fielditem.itemid > 0 and fielditem.itemid ~= 1497 and fielditem.itemid ~= 1498 then
 doSendMagicEffect(topos,2)
 doRemoveItem(fielditem.uid,1)

 if item.type > 1 then
 doChangeTypeItem(item.uid,item.type-1)
 else
 doRemoveItem(item.uid,1)
 end
 else
 doSendMagicEffect(frompos,2)
 return 0
 end
 else
 doSendMagicEffect(frompos,2)
 doPlayerSendCancel(cid,"You don't have the required magic level to use that rune.")
 end
 return 1
end

 

 

destroyi.png

 

Alguma alma bondosa, poderia por favor me ajudar!? PLS cry.gif

 

Abraços!

Link para o comentário
https://xtibia.com/forum/topic/204669-erro-no-script-da-destroy-field-rune-e-no-script-da-rope/
Compartilhar em outros sites

Visitante
Este tópico está impedido de receber novos posts.
×
×
  • Criar Novo...