Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Defesa Extra - extradefense [00]
- -- Dano Extra - extraattack [00]
- -- Dano - attack [00]
- -- Defesa - defense [00]
- -- Nome - name [""]
- -- Descrição - description [""]
- -- Artículo (you see a xxx - a=artículo) - article [""]
- local me = {
- {att="defense",valor=30,id=2376},
- {att="extradefense",valor=15,id=2377},
- {att="name",valor="Machado divinu +5",id=2378},
- {att="article",valor="um",id=1967}
- }
- function onUse(cid, item, frompos, item2, topos)
- local possibleitems = {}
- for x,i in pairs(me) do
- table.insert(possibleitems,i.id)
- end
- if isInArray(possibleitems,item2.itemid) then
- for x,i in pairs(me) do
- if i.id == item2.itemid then
- doItemSetAttribute(item2.uid,i.att,i.valor)
- doItemSetAttribute(item2.uid,"description",(getItemAttribute(item2.uid,"description") ~= nil and getItemAttribute(item2.uid,"description") or "Este item foi forjado por "..getPlayerName(cid).."."))
- doSendMagicEffect(topos,12)
- end
- end
- else
- doPlayerSendCancel(cid,"O martelo não tem efeito neste item.")
- end
- return true
- end
Advertisement
Add Comment
Please, Sign In to add comment