É mesmo muito bom
Vou arrumar as palavras e testá-lo aqui
Pelo que parece, está completinho.
OBS:
Põe em Quote e Spoil pra ficar mais fácil pra copiar, code usa uma linha só.
info
Grupo: Lenda
Registrado: 03/10/06
Posts: 2.6k
Reputação: +309
Gênero: Masculino
Char no Tibia: Knight Orion

É mesmo muito bom
Vou arrumar as palavras e testá-lo aqui
Pelo que parece, está completinho.
OBS:
Põe em Quote e Spoil pra ficar mais fácil pra copiar, code usa uma linha só.
info
Grupo: Cavaleiro
Registrado: 04/11/07
Posts: 192
Reputação: +1
Char no Tibia: Ranzor Raven

Bom, mas para que server este npc
?
info
Grupo: Campones
Registrado: 03/05/07
Posts: 31
Reputação: 0
Char no Tibia: Diniz'hell

Filé
vo colokar paraebns pelo NPC ![]()
Editado Março 14 por apaxonado
info
Grupo: Campones
Registrado: 09/08/07
Posts: 1
Reputação: 0
Parabens Npc Nota 10 :smile_positivo:
Editado Março 18 por leonardo_loko
@darllano
Rashid no Global é um npc que viaja para várias cidades e compra itens que os npcs djinn não compram como:
Dsm
Golden Armor
Demon Shield
Steel Boots
assim ajudando muito os players
&Tádzio&
info
Grupo: Campones
Registrado: 08/10/05
Posts: 56
Reputação: +2
Olá
tenho visto que no forum muitas pessoas fazem rashid inuteis, ou diferentes do global...pensando nisso desperdicei um pouco do meu precioso tempo para arrumalo
Credito exclusivamentes a mim:)
Crie um arquivo na pasta Npcs/
Chame0o de Rashid.xml e salve-o
Agora na pasta Npcs/Scripts crie um arquivo chamado Rashid.lua e salve-o
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 if getPlayerPremium(cid) then selfSay('Hello ' .. getCreatureName(cid) .. '! Eu compro swords, clubs, axes, helmets, boots, shields, amulets e armors.') focus = cid talk_start = os.clock() else selfSay('Sorry, only premium players can sell items to me.') focus = 0 talk_start = 0 end elseif msgcontains(msg, 'hi') and (focus ~= cid) and getDistanceToCreature(cid) < 4 then selfSay('Sorry, ' .. getCreatureName(cid) .. '! I talk to you in a minute.') elseif focus == cid then talk_start = os.clock() if msgcontains(msg, 'skull helmet') then sell(cid,5741,getCount(msg),40000) elseif msgcontains(msg, 'beholder helmet') then sell(cid,3972,getCount(msg),7500) elseif msgcontains(msg, 'devil helmet') then sell(cid,2462,getCount(msg),1000) elseif msgcontains(msg, 'pirate hat') then sell(cid,6096,getCount(msg),1000) elseif msgcontains(msg, 'ragnir helmet') then sell(cid,7462,getCount(msg),400) elseif msgcontains(msg, 'krimhorn helmet') then sell(cid,7461,getCount(msg),200) elseif msgcontains(msg, 'helmets') then selfSay('Eu compro skull helmets (40k), pirate hat (1k), devil helmet (1k), ragnir helmet(400gp),krimhorn helmet (200gp), e beholder helmet (7.5k).') elseif msgcontains(msg, 'fur boots') then sell(cid,7457,getCount(msg),2000) elseif msgcontains(msg, 'crocodile boots') then sell(cid,3982,getCount(msg),1000) elseif msgcontains(msg, 'steel boots') then sell(cid,2645,getCount(msg),30000) elseif msgcontains(msg, 'pirate boots') then sell(cid,5462,getCount(msg),3000) elseif msgcontains(msg, 'boots') then selfSay('Eu compro fur boots (2k),steel boots (30k),crocodile boots (1k) e pirate boots (3k).') elseif msgcontains(msg, 'dragon scale mail') then sell(cid,2492,getCount(msg),40000) elseif msgcontains(msg, 'mammoth fur cape') then sell(cid,7463,getCount(msg),6000) elseif msgcontains(msg, 'golden armor') then sell(cid,2466,getCount(msg),20000) elseif msgcontains(msg, 'dwarven armor') then sell(cid,2603,getCount(msg),30000) elseif msgcontains(msg, 'leopard armor') then sell(cid,3968,getCount(msg),1000) elseif msgcontains(msg, 'pirate shirt') then sell(cid,6095,getCount(msg),500) elseif msgcontains(msg, 'armors') then selfSay('Eu compro dragon scale mail (40k), mammoth fur cape(6k), golden armor (20k) dwarven armor (30k), leopard armor (1k) e pirate shirt (500gp).') elseif msgcontains(msg, 'pirate knee breeches') then sell(cid,5918,getCount(msg),200) elseif msgcontains(msg, 'light shovel') then sell(cid,5710,getCount(msg),300) elseif msgcontains(msg, 'cvbnvbnin legs') then sell(cid,2478,getCount(msg),50) elseif msgcontains(msg, 'legs') then selfSay('Eu pirate knee breeches (200gp), and light shovel (300gp).') elseif msgcontains(msg, 'demon shield') then sell(cid,2520,getCount(msg),30000) elseif msgcontains(msg, 'medusa shield') then sell(cid,2536,getCount(msg),9000) elseif msgcontains(msg, 'castle shield') then sell(cid,2535,getCount(msg),5000) elseif msgcontains(msg, 'scarab shield') then sell(cid,2540,getCount(msg),2000) elseif msgcontains(msg, 'dark shield') then sell(cid,2521,getCount(msg),400) elseif msgcontains(msg, 'tortoise shield') then sell(cid,6131,getCount(msg),150) elseif msgcontains(msg, 'bone shield') then sell(cid,2535,getCount(msg),80) elseif msgcontains(msg, 'shields') then selfSay('Eu compro demon (30k), medusa (9k),castle (5k),scarab (2k),dark (400gp),tortoise (150gp) and bone shields (80gp).') elseif msgcontains(msg, 'crystal sword') then sell(cid,7449,getCount(msg),600) elseif msgcontains(msg, 'wyvern fang') then sell(cid,7408,getCount(msg),1500) elseif msgcontains(msg, 'dragon slayer') then sell(cid,7402,getCount(msg),15000) elseif msgcontains(msg, 'swords') then selfSay('Eu compro crystal (600gp), wyvern fang (1.5k) and dragon slayer (15k).') elseif msgcontains(msg, 'war axe') then sell(cid,2454,getCount(msg),9000) elseif msgcontains(msg, 'beastslayer axe') then sell(cid,2381,getCount(msg),1500) elseif msgcontains(msg, 'daramanian waraxe') then sell(cid,2440,getCount(msg),1000) elseif msgcontains(msg, 'axes') then selfSay('Eu compro war axe (9k), beastslayer axe (1.5k), daramanian waraxe (1k).') elseif msgcontains(msg, 'sapphire hammer') then sell(cid,7437,getCount(msg),7000) elseif msgcontains(msg, 'amber staff') then sell(cid,7426,getCount(msg),8000) elseif msgcontains(msg, 'lunar staff') then sell(cid,2417,getCount(msg),5000) elseif msgcontains(msg, 'brutetamers staff') then sell(cid,7379,getCount(msg),1500) elseif msgcontains(msg, 'dragonbone staff') then sell(cid,7430,getCount(msg),3000) elseif msgcontains(msg, 'clubs') then selfSay('Eu compro sapphire hammer (7k), amber staff (8k), dragonbone staff (3k), lunar staff (5k) e brutetamer staff(1.5k).') elseif msgcontains(msg, 'scarab amulet') then sell(cid,2135,getCount(msg),200) elseif msgcontains(msg, 'ancient amulet') then sell(cid,2142,getCount(msg),200) elseif msgcontains(msg, 'amulets') then selfSay('Eu compro scarab (200gp) e ancient amulet (200gp).') elseif string.find(msg, '(%a*)bye(%a*)') and getDistanceToCreature(cid) < 4 then selfSay('Good bye, ' .. getCreatureName(cid) .. '!') focus = 0 talk_start = 0 end end end function onCreatureChangeOutfit(creature) end function onThink() if (os.clock() - talk_start) > 20 then if focus > 0 then selfSay('...') end focus = 0 end if focus ~= 0 then if getDistanceToCreature(focus) > 5 then selfSay('...') focus = 0 end end endNpc testado e funcionando, obrigado por usarem ele .
Editado Março 15 por skinaa