Postado Maio 23, 2016 9 anos Olá, eu estou com uma script de um npc que teleporta você por dinheiro, porém eu quero que eu seja teleportado sem eu falar yes. Por exemplo >> eu falo hi, e logo em seguida o nome da cidade que no caso é new city. Com está script q eu tenho é presiso falar hi, new city e yes para ser teleportado. Segue a script. 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({'new city'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Você deseja ir para New City em troca de 1000 gps?'}) travelNode:addChildKeyword({''}, StdModule.travel, {npcHandler = npcHandler, premium = false, level = 0, cost = 1000, destination = {x=1558, y=956, z=14} }) travelNode:addChildKeyword({''}, StdModule.travel, {npcHandler = npcHandler, premium = false, level = 0, cost = 1000, destination = {x=1959, y=956, z=14} }) -- Makes sure the npc reacts when you say hi, bye etc. npcHandler:addModule(FocusModule:new())
Postado Maio 23, 2016 9 anos Esta é uma mensagem automática! Este tópico foi movido para a área correta.Pedimos que você leia as regras do fórum. Mostrar conteúdo oculto This is an automated message! This topic has been moved to the correct area.Please read the forum rules. _ .-'` `} _./) / } .'o \ | } '.___.'`.\ {` /`\_/ , `. } ME DA UMA NOZ! \=' .-' _`\ { `'`;/ `, } _\ @ ; } /__`;-...'--' Cluck!
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.