Preciso de um npc que transporta somente players premium accounts.
Postado em agosto 03, 2011
faz assim ó , crie 1 npc no xml e no script dele coloque isso :
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({'hi'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Quer ir para templo?'}) travelNode:addChildKeyword({'yes'}, StdModule.travel, {npcHandler = npcHandler, premium = true, level = 2, cost = 0, destination = {x=60, y=44, z=7} }) travelNode:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, reset = true, text = 'I wouldn\'t go there either.'}) keywordHandler:addKeyword({'destination'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can take you to \'Ilha dos Eventos\' for just a small fee.'}) -- Makes sure the npc reacts when you say hi, bye etc. npcHandler:addModule(FocusModule:new())
ai você troca os testos e o lugar
ajudei??REP+ please
Veja Meu novo Servidor de Dragon Ball na versao 8.57:http://www.xtibia.com/forum/topic/163190-dragon-ball-server/
Veja meu tutorial de Teleport Talkactions:
http://www.xtibia.com/forum/topic/164905-como-fazer-seu-teleport-talkactions/#entry1084885
Veja meu novo blog , e Acesse:
Ajudei ?? Rep + Por favor
Meta :<X> Reputação 25
< > Reputação 50
< > Reputação 100
Postado em agosto 11, 2011
Dúvida sanada!
O Topico ja pode ser movido.
Obrigado galaverna, lhe concedi +REP!
Abraços