Olá, já tenho um script de um npc de promotions, porém ele promove tanto as acc premium quanto as free, preciso que ele promova exclusivamente as acc premium.
Segue o código que tenho abaixo.
local keywordHandler = KeywordHandler:new()local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid)endfunction onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid)endfunction onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg)endfunction onThink() npcHandler:onThink()endlocal node1 = keywordHandler:addKeyword({'promot'}, StdModule.say,{npcHandler = npcHandler, onlyFocus =true, text ='I can promote you for 20000 gold coins. Do you want me to promote you?'})
node1:addChildKeyword({'yes'}, StdModule.promotePlayer,{npcHandler = npcHandler, cost =20000, level =20, promotion =1, text ='Congratulations! You are now promoted.'})
node1:addChildKeyword({'no'}, StdModule.say,{npcHandler = npcHandler, onlyFocus =true, text ='Alright then, come back when you are ready.', reset =true})
npcHandler:addModule(FocusModule:new())
Pergunta
emersongo 0
Olá, já tenho um script de um npc de promotions, porém ele promove tanto as acc premium quanto as free, preciso que ele promova exclusivamente as acc premium.
Segue o código que tenho abaixo.
Link para o comentário
Compartilhar em outros sites
5 respostass a esta questão
Posts Recomendados