=]! Vim trazer otro NPC que editei, o Frodo... No meu OTServ antigo ele vendia acessorios como ropes, shovels, BP marrom, etc...
Agora eu coloquei ele pra vender mais alguns acessorios como Obsidian Knife, Blessed Wooden Stake, Todas as BPS, e mais coisas...

Certo ai vai:
†- Va para data/npc/scripts na pasta do seu OT;
†- Abra qualquer arquivo .LUA que estiver la, delete todo seu conteudo e cole o conteudo abaixo (clique em mostrar spoil):
local focus = 0 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 ropes (50gp), picks (50gp), shovels (50gp), backpacks (brown, blue, red, yellow, purple, golden green, gray, fur, star and pirate backpack, 100gps), fishing rods (100gp),torches (5gp), obsidian knife (10k), blessed wooden stake (10k), key ring (7k) and backpack of holding (40k).') 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, 'rope') then buy(cid,2120,getCount(msg),50) elseif msgcontains(msg, 'shovel') then buy(cid,2554,getCount(msg),50) elseif msgcontains(msg, 'pick') then buy(cid,2553,getCount(msg),50) elseif msgcontains(msg, 'brown backpack') then buy(cid,1988,getCount(msg),100) elseif msgcontains(msg, 'green backpack') then buy(cid,1998,getCount(msg),100) elseif msgcontains(msg, 'yellow backpack') then buy(cid,1999,getCount(msg),100) elseif msgcontains(msg, 'red backpack') then buy(cid,2000,getCount(msg),100) elseif msgcontains(msg, 'purple backpack') then buy(cid,2001,getCount(msg),100) elseif msgcontains(msg, 'blue backpack') then buy(cid,2002,getCount(msg),100) elseif msgcontains(msg, 'gray backpack') then buy(cid,2003,getCount(msg),100) elseif msgcontains(msg, 'golden backpack') then buy(cid,2004,getCount(msg),100) elseif msgcontains(msg, 'fur backpack') then buy(cid,7342,getCount(msg),100) elseif msgcontains(msg, 'star backpack') then buy(cid,5949,getCount(msg),100) elseif msgcontains(msg, 'pirate backpack') then buy(cid,5926,getCount(msg),100) elseif msgcontains(msg, 'fishing rod') then buy(cid,2580,getCount(msg),100) elseif msgcontains(msg, 'torch') then buy(cid,2050,getCount(msg),5) elseif msgcontains(msg, 'backpack of holding') then buy(cid,2365,getCount(msg),40000) elseif msgcontains(msg, 'obsidian knife') then buy(cid,5908,getCount(msg),10000) elseif msgcontains(msg, 'blessed wooden stake') then buy(cid,5942,getCount(msg),10000) elseif msgcontains(msg, 'key ring') then buy(cid,5801,getCount(msg),7000) 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
†- Depois de ter colado o conteudo acima, salve o arquivo como seller.lua;
†- Depois va para a pasta data/npc e faça algo parecido, abra um arquivo .xml, delete seu conteudo e cole o conteudo abaixo (clique em mostrar spoil):
<?xml version="1.0"?> <npc name="Frodo" script="data/npc/scripts/seller.lua" access="1" lookdir="2"> <mana now="800" max="800"/> <health now="200" max="200"/> <look type="159" head="78" body="121" legs="0" feet="116" addons="0"/> </npc>
†- Agora salve o arquivo como Frodo.xml e pronto!
_____________________________________________________________________________
Obs.: Testei o NPC na versao 0.4.5 - XML do Aries, e funfo certinho, se der algum erro poste aqui...
Espero que gostem
