Bom como Scripter vou passar a voces uma criaçao minha
1º> vá na pasta data/npcs copie um npc renomei-o como Gui,abra e apage tudo e coloque isso
<?xml version="1.0"?> <npc name="Gui" script="data/npc/scripts/rings.lua" access="3" lookdir="2"> <mana now="800" max="800"/> <health now="200" max="200"/> <look type="129" head="74" body="110" legs="120" feet="80"/> </npc>
2º>vá a pasta data/npc/scripts copie um e renomei-o como rings,apaue o que tem dentro e coloque isso \/
local focus = 0 local talk_start = 0 local target = 0 local following = false local attacking = false function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye then.') focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function onCreatureSay(cid, type, msg) msg = string.lower(msg) if (msgcontains(msg, 'hi') and (focus == 0)) and getDistanceToCreature(cid) < 4 then selfSay('Hello, ' .. creatureGetName(cid) .. '! I sell sword ring (100gp), axe ring (100gp), club ring (100gp), time ring(100gp), life ring (100gp), energy ring (100gp), power ring (100), might ring (100gp), stealth ring(100gp) and ring of healing(100gp).') focus = cid talk_start = os.clock() elseif msgcontains(msg, 'hi') and (focus ~= cid) and getDistanceToCreature(cid) < 4 then selfSay('Sorry, ' .. creatureGetName(cid) .. '! I talk to you in a minute.') elseif focus == cid then talk_start = os.clock() if msgcontains(msg, '[color="#FF8C00"]might ring') then buy(cid,[color="#FF0000"]2164[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]stealth ring[/color]') then buy(cid,[color="#FF0000"]2165[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]power ring[/color]') then buy(cid,[color="#FF0000"]2166[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]energy ring[/color]') then buy(cid,[color="#FF0000"]2167[color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]life ring[/color]') then buy(cid,[color="#FF0000"]2168[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]time ring[/color]') then buy(cid,[color="#FF0000"]2169[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]sword ring[/color]') then buy(cid,[color="#FF0000"]2107[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]axe ring[/color]') then buy(cid,[color="#FF0000"]2208[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]club ring[/color]') then buy(cid,[color="#FF0000"]2209[/color],getCount(msg),100) elseif msgcontains(msg, '[color="#FF8C00"]ring of healing[/color]') then buy(cid,[color="#FF0000"]2214[/color],getCount(msg),100) elseif msgcontains(msg, 'bye') and getDistanceToCreature(cid) < 4 then selfSay('Good bye, ' .. creatureGetName(cid) .. '!') focus = 0 talk_start = 0 end end end function onCreatureChangeOutfit(creature) end function onThink() if (os.clock() - talk_start) > 30 then if focus > 0 then selfSay('Next Please...') end focus = 0 end if focus ~= 0 then if getDistanceToCreature(focus) > 5 then selfSay('Good bye then.') focus = 0 end end end
id do anel
nome do ring
se quiser colocar algum ring :
elseif msgcontains(msg, 'NOME DO ANEL') then buy(cid,ID DO ANEL,getCount(msg),PREÇO AQUI)
Espero ter ajudado
até a proxima :smile_positivo: