Ir para conteúdo

Npc Esrik (Compra Itens 8.54)


dgprado

Posts Recomendados

Fiz este npc para que os playres podessem vender alguns dos novos itens 8.54, ainda faltam alguns itens mas ja quebra o galho.

 

Xml

<?version="1.0" encoding="UTF-8"?>

<npc name="Esrik" script="data/npc/scripts/Sell/Esrik.lua" walkinterval="2000" floorchange="0">

<health now="100" max="100"/>

<look type="71" head="113" body="113" legs="113" feet="115" addons="0"/>

<parameters>

<parameter key="message_greet" value="Hello |PLAYERNAME|. What is your ned?"/>

<parameter key="message_farewell" value="Bye."/>

<parameter key="module_keywords" value="1" />

<parameter key="keywords" value="job;" />

<parameter key="keyword_reply1" value="I buy new itens." />

</parameters>

</npc>

 

Lua

local keywordHandler = KeywordHandler:new()

local npcHandler = NpcHandler:new(keywordHandler)

NpcSystem.parseParameters(npcHandler)

 

function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end

function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end

function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end

function onThink() npcHandler:onThink() end

 

local shopModule = ShopModule:new()

npcHandler:addModule(shopModule)

 

 

 

shopModule:addSellableItem({'Zaoan Helmet'}, 11296, 45000, 'Zaoan Helmet')

shopModule:addSellableItem({'Drakinata'}, 11299, 10000, 'Drakinata')

shopModule:addSellableItem({'Twin Hooks'}, 11303, 2, 'Twin Hooks')

shopModule:addSellableItem({'Zaoan Halberd'}, 11317, 500, 'Zaoan Halberd')

shopModule:addSellableItem({'Zaoan Sword'}, 11301, 30000, 'Zaoan Sword')

shopModule:addSellableItem({'Zaoan Armor'}, 11295, 14000, 'Zaoan Armor')

shopModule:addSellableItem({'Zaoan Legs'}, 11298, 14000, 'Zaoan Legs')

shopModule:addSellableItem({'Dragon Scale Boots'}, 11114, 40000, 'Dragon Scale Boots')

shopModule:addSellableItem({'Guardian Boots'}, 11234, 35000, 'Guardian Boots')

shopModule:addSellableItem({'Zaoan Shoes'}, 11297, 5000, 'Zaoan Shoes')

shopModule:addSellableItem({'Drachaku'}, 11302, 10000, 'Drachaku')

shopModule:addSellableItem({'Broken Halberd'}, 11329, 100, 'Broken Halberd')

shopModule:addSellableItem({'Cursed Shoulder Spikes'}, 11321, 320, 'Cursed Shoulder Spikes')

shopModule:addSellableItem({'Legionnaire Flags'}, 11328, 500, 'Legionnaire Flags')

shopModule:addSellableItem({'Sais'}, 11300, 16500, 'Sais')

shopModule:addSellableItem({'Spiked Iron Ball'}, 11319, 100, 'Spiked Iron Ball')

 

shopModule:addBuyableItem({'two handed sword'}, 2377, 950, 'two handed sword')

shopModule:addBuyableItem({'broad sword'}, 2413, 950, 'broad sword')

shopModule:addBuyableItem({'sword'}, 2376, 85, 'sword')

shopModule:addBuyableItem({'crimson sword'}, 7385, 610, 'crimson sword')

shopModule:addBuyableItem({'dagger'}, 2379, 5, 'dagger')

shopModule:addBuyableItem({'rapier'}, 2384, 15, 'rapier')

shopModule:addBuyableItem({'sabre'}, 2385, 35, 'sabre')

 

shopModule:addBuyableItem({'battle hammer'}, 2417, 350, 'battle hammer')

shopModule:addBuyableItem({'clerical mace'}, 2423, 540, 'clerical mace')

shopModule:addBuyableItem({'mace'}, 2398, 90, 'mace')

shopModule:addBuyableItem({'morning star'}, 2394, 430, 'morning star')

 

shopModule:addBuyableItem({'hand axe'}, 2380, 8, 'hand axe')

shopModule:addBuyableItem({'axe'}, 2386, 20, 'hand axe')

shopModule:addBuyableItem({'barbarian axe'}, 2429, 590, 'barbarian axe')

shopModule:addBuyableItem({'battle axe'}, 2378, 235, 'battle axe')

 

shopModule:addBuyableItem({'leather helmet'}, 2461, 12, 'leather helmet')

shopModule:addBuyableItem({'chain helmet'}, 2458, 52, 'chain helmet')

shopModule:addBuyableItem({'chain legs'},2648, 80, 'chain legs')

 

shopModule:addBuyableItem({'wooden shield'}, 2512, 15, 'wooden shield')

shopModule:addBuyableItem({'steel shield'}, 2509, 240, 'steel shield')

shopModule:addBuyableItem({'viking shield'}, 2531, 260, 'viking shield')

 

shopModule:addBuyableItem({'chain legs'},2648, 80, 'chain legs')

 

shopModule:addBuyableItem({'brass armor'}, 2465, 450, 'brass armor')

shopModule:addBuyableItem({'chain armor'}, 2464, 200, 'chain armor')

shopModule:addBuyableItem({'leather armor'}, 2467, 35, 'leather armor')

shopModule:addBuyableItem({'scale armor'}, 2483, 260, 'scale armor')

 

 

npcHandler:addModule(FocusModule:new())

Editado por dgprado
Link para o comentário
Compartilhar em outros sites

Oi, eu achei um pequeno erro...

 

 

version="1.0" encoding="UTF-8"?>

 

nessa linha você esqueceu de abrir a Tag "<". Esta linha devia estar assim:

 

<?xml version="1.0" encoding="UTF-8"?>

 

:D

 

 

Valeu arrumei ja, falto na hora q dei ctrl+c do script aki thx

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...