I need an Npc Whitch will only deal with you if you have loot some quest (that you have that data_key from some quest)
Travel npc code:
Seller Npc:
EUM.. I WANT THE CODE MAKE NPC DEAL WITH YOU IF YOU HAVE THE DATA KEY NEEDED.. WHITCH MEAN YOU NEED TO DO A QUEST BEFORE BE ABLE DEAL WITH HIM....
And here are the character.
and no, its not hunted.. its on Non pvp xD

Ps: I don't have the email, I got the character from RealSoft.
Any question: just ask em ;D
Travel npc code:
Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
-- OTServ event handling functions start
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
-- OTServ event handling functions end
-- Don't forget npcHandler = npcHandler in the parameters. It is required for all StdModule functions!
local travelNode = keywordHandler:addKeyword({'venore'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Do you want to sail to Venore for 60 gold coins?'})
travelNode:addChildKeyword({'yes'}, StdModule.travel, {npcHandler = npcHandler, premium = true, level = 0, cost = 60, destination = {x=32952, y=32022, z=6} })
travelNode:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, reset = true, text = 'Then stay here!'})
local travelNode = keywordHandler:addKeyword({'port hope'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Do you want to sail to Port Hope for 180 gold coins?'})
travelNode:addChildKeyword({'yes'}, StdModule.travel, {npcHandler = npcHandler, premium = true, level = 0, cost = 180, destination = {x=32527, y=32784, z=6} })
travelNode:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, reset = true, text = 'Then stay here!'})
keywordHandler:addKeyword({'sail'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can take you to Venore, Port Hope and Ankrahmun.'})
keywordHandler:addKeyword({'job'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I am the captain of this ship.'})
keywordHandler:addKeyword({'travel'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can only take you to Venore, Port Hope and Ankrahmun.'})
-- Makes sure the npc reacts when you say hi, bye etc.
npcHandler:addModule(FocusModule:new())
Seller Npc:
Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
-- OTServ event handling functions start
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
-- OTServ event handling functions end
local shopModule = ShopModule:new()
npcHandler:addModule(shopModule)
shopModule:addBuyableItem({'light wand', 'lightwand'}, 2163, 500, 'magic light wand')
shopModule:addBuyableItem({'mana fluid', 'manafluid'}, 2006, 50, 7, 'mana fluid')
shopModule:addBuyableItem({'life fluid', 'lifefluid'}, 2006, 80, 10, 'life fluid')
shopModule:addBuyableItem({'heavy magic missile rune', 'heavy magic missile rune'}, 2311, 125, 5, 'heavy magic missile rune')
shopModule:addBuyableItem({'great fireball rune', 'great fireball rune'}, 2304, 130, 2, 'great fireball rune')
shopModule:addBuyableItem({'explosion rune', 'explosion rune'}, 2313, 300, 3, 'explosion rune')
shopModule:addBuyableItem({'ultimate healing rune', 'ultimate healing rune'}, 2273, 175, 1, 'ultimate healing rune')
shopModule:addBuyableItem({'sudden death rune', 'sudden death rune'}, 2268, 325, 1, 'sudden death rune')
shopModule:addBuyableItem({'blank rune', 'blank rune'}, 2260, 10, 1, 'blank rune')
npcHandler:addModule(FocusModule:new())
EUM.. I WANT THE CODE MAKE NPC DEAL WITH YOU IF YOU HAVE THE DATA KEY NEEDED.. WHITCH MEAN YOU NEED TO DO A QUEST BEFORE BE ABLE DEAL WITH HIM....
And here are the character.
and no, its not hunted.. its on Non pvp xD

Ps: I don't have the email, I got the character from RealSoft.
Any question: just ask em ;D
Last edited: