Ir para conteúdo

Featured Replies

Postado

Estou tendo um certo probleminha no meu ot server 8.40.

A rope e a shovel, estão bugadas, está dando pra usar no chão em qualquer lugar, e com isso ocasiona um bug que faz os jogadores correrem mais rápido. Gostaria de estar arrumando tal problema, poderiam me ajudar?

 

Script Shovel:

 

function onUse(cid, item, frompos, item2, topos)
 if item2.itemid == 28 then
  return 0
 end
 if item2.itemid == 468 then
  doTransformItem(item2.uid,469)
  doDecayItem(item2.uid)
 elseif item2.itemid == 481 then
  doTransformItem(item2.uid,482)
  doDecayItem(item2.uid)
 elseif item2.itemid == 483 then
  doTransformItem(item2.uid,484)
  doDecayItem(item2.uid)
 elseif item2.itemid == 231 then
  rand = math.random(1,30)
  if rand < 6 then
   doSummonCreature("Scarab", topos)
  elseif rand == 15 then
   doPlayerAddItem(cid,2159,1)
  else
   doSendMagicEffect(topos,2)
  end
 else
  return 0
 end
 return 1
 end

 

---------------------------------------------------------------------------------------

 

Script Rope:

 

local spotId = {384, 418, 8278, 8592}
local holeId = {
    294, 369, 370, 383, 392,
    408, 409, 427, 428, 430,
    462, 469, 470, 482, 484,
    485, 489, 924, 3135, 3136,
    7933, 7938, 8170, 8286, 8285,
    8284, 8281, 8280, 8279, 8277,
    8276, 8323, 8380, 8567, 8585,
    8596, 8595, 8249, 8250, 8251,
    8252, 8253, 8254, 8255, 8256,
    8972, 9606, 9625
}

function onUse(cid, item, fromPosition, itemEx, toPosition)
    if(toPosition.x == CONTAINER_POSITION) then
        doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
        return true
    end

    local itemGround = getThingFromPos(toPosition)
    if(isInArray(spotId, itemGround.itemid)) then
        doTeleportThing(cid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z - 1}, false)
    elseif(isInArray(holeId, itemEx.itemid)) then
        local hole = getThingFromPos({x = toPosition.x, y = toPosition.y, z = toPosition.z + 1, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE})
        if(hole.itemid > 0) then
            doTeleportThing(hole.uid, {x = toPosition.x, y = toPosition.y + 1, z = toPosition.z}, false)
        else
            doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTPOSSIBLE)
        end
    else
        return false
    end

    return true
end

 

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Conteúdo Similar

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.8k

Informação Importante

Confirmação de Termo