Tenta assim:
local helmets = {
["demon helmet"] = {fist = 10, sword = 20, axe = 10, shield = 10},
}
function onMoveItem(cid, item, formPosition, toPosition, fromItem, toItem, fromGround, toGround, status)
x = helmets[getItemNameById(item.itemid)]
if x then
if not isPlayer(cid) then return false end
if not getPlayerAccess(cid) < 4 then return false end
if getPlayerSkill(cid, 0) >= x.fist and getPlayerSkill(cid, 2) >= x.sword and getPlayerSkill(cid, 3) >= x.axe and getPlayerSkill(cid, 5) >= x.shield then
else
return doPlayerSendCancel(cid, "Sorry, you don't have this permision")
end
else return false
end
return true
end






info
Grupo: Visconde
Registrado: 21/09/10
Posts: 319
Reputação: +27
Char no Tibia: lest sarif
Olá galera do Xtibia, eu adicionei uma nova funçao aki nas minhas sourcers . o nome dela é function onMove
e eu gostaria de um script que só podesse mover o equipamento para o slot , se tivesse as seguintes skills
então , seria uma tabela tipo essa aki olha
local helmets = {
["demon helmet"] = {fist = 10, sword = 20, axe = 10, shield = 10},
}
E não é exatamente esse numero não , só daria para equipar se fosse >=
aki , irei postar a funçao , para voces entenderem mais um pouco sobre.
Editado Dezembro 18 por tonynamoral