Ir para conteúdo

Featured Replies

Postado

Galera, desculpa eu de novo, bom eu tenho um npc Promotion, mas ele n reconhece o id da vocation.

 

Vocations.xml

<?xml version="1.0" encoding="UTF-8"?>
<vocations>
    <vocation id="0" name="None" description="none" needpremium="0" gaincap="5" gainhp="5" gainmana="5" gainhpticks="6" gainhpamount="1" gainmanaticks="6" gainmanaamount="1" manamultiplier="4.0" attackspeed="2000" soulmax="100" gainsoulticks="120" fromvoc="0" attackable="no">
        <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/>
        <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/>
    </vocation>
    
    <vocation id="1" name="Sadie Kane" description="a sadie kane" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="2" gainhpamount="5" gainmanaticks="2" gainmanaamount="30" manamultiplier="1.1" attackspeed="700" soulmax="100" gainsoulticks="120" fromvoc="1">
        <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/>
        <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/>
    </vocation>
    
    <vocation id="2" name="Carter Kane" description="a carter kane" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="2" gainhpamount="5" gainmanaticks="2" gainmanaamount="30" manamultiplier="1.1" attackspeed="900" soulmax="100" gainsoulticks="120" fromvoc="2">
        <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/>
        <skill fist="1.5" club="1.8" sword="1.8" axe="1.8" distance="1.8" shielding="1.5" fishing="1.1" experience="1.0"/>
    </vocation>
    
    <vocation id="3" name="Master Maga Sadie Kane" description="Master Maga Sadie Kane" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="2" gainhpamount="10" gainmanaticks="1" gainmanaamount="40" manamultiplier="1.4" attackspeed="1500" soulmax="200" gainsoulticks="15" fromvoc="1" lessloss="30">
        <formula meleeDamage="1.0" distDamage="1.3" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/>
        <skill fist="1.2" club="1.2" sword="1.2" axe="1.2" distance="1.1" shielding="1.1" fishing="1.1" experience="1.0"/>
    </vocation>
    
    <vocation id="4" name="Master Mago Carter Kane" description="Master Mago Carter Kane" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="1" gainhpamount="20" gainmanaticks="1" gainmanaamount="35" manamultiplier="3.0" attackspeed="1500" soulmax="200" gainsoulticks="15" fromvoc="2" lessloss="30">
        <formula meleeDamage="1.2" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/>
        <skill fist="1.1" club="1.1" sword="1.1" axe="1.1" distance="1.4" shielding="1.1" fishing="1.1" experience="1.0"/>
    </vocation>
    
    <vocation id="9" name="Semideus Sadie Kane" description="Semideus Sadie Kane" needpremium="1" gaincap="35" gainhp="30" gainmana="15" gainhpticks="1" gainhpamount="20" gainmanaticks="1" gainmanaamount="35" manamultiplier="3.0" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="1" lessloss="30">
        <formula meleeDamage="2.4" distDamage="1.0" wandDamage="3.0" magDamage="1.0" magHealingDamage="1.0" defense="3.0" magDefense="1.0" armor="4.0"/>
        <skill fist="5.1" club="3.1" sword="3.1" axe="3.1" distance="4.4" shielding="4.1" fishing="2.1" experience="5.0"/>
    </vocation>
    
    <vocation id="10" name="Semideus Carter Kane" description="Semideus Carter Kane" needpremium="1" gaincap="35" gainhp="30" gainmana="15" gainhpticks="1" gainhpamount="20" gainmanaticks="1" gainmanaamount="35" manamultiplier="3.0" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="2" lessloss="30">
        <formula meleeDamage="2.4" distDamage="1.0" wandDamage="3.0" magDamage="1.0" magHealingDamage="1.0" defense="3.0" magDefense="1.0" armor="4.0"/>
        <skill fist="5.1" club="3.1" sword="3.1" axe="3.1" distance="4.4" shielding="4.1" fishing="2.1" experience="5.0"/>
    </vocation>
    
</vocations>

 

NPC 

 

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 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 = 2, 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})
--[[
local node2 = keywordHandler:addKeyword({'high'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can high promote you for 200000 gold coins. Do you want me to high promote you?'})
node2:addChildKeyword({'yes'}, StdModule.promotePlayer, {npcHandler = npcHandler, cost = 200000, level = 120, promotion = 2, text = 'Congratulations! You are now high promoted.'})
node2:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Alright then, come back when you are ready.', reset = true})
]]--

npcHandler:addModule(FocusModule:new())

 

 

Ja tentei mudar tudo no NPC, com promotion 2 ele da isso:

16:59 You see yourself. You are.

 

Eu ja tenho um NPC promotion ele funciona normal, ai quando chego nesse ele fala que ja to promote.

 

Por favor novamente, me ajudem se puderem.

Editado por Luzetti (veja o histórico de edições)

  • Respostas 6
  • Visualizações 561
  • Created
  • Última resposta

Top Posters In This Topic

Postado

Esta é uma mensagem automática! Este tópico foi movido para a área correta.
Pedimos que você leia as regras do fórum.

Spoiler

This is an automated message! This topic has been moved to the correct area.
Please read the forum rules.

 

                                                              ezgif-1-98aab239f3.gif.1a897c9c3225228909e7b356a5cfb8e4.gif

Postado
  • Autor

cara vc n pode me ajudar?

50 minutos atrás, KotZletY disse:

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.

 

vc n pode me ajudar?

Postado

Nunca vi esse npc de promotio, não sei como funciona essa promoção, no script está promovendo a valor 2, esse valor 2 que ta na promotion, "promotion = 2", é a vocação 2 ?

Essa é a questão! 

                                                              ezgif-1-98aab239f3.gif.1a897c9c3225228909e7b356a5cfb8e4.gif

Postado
  • Autor
35 minutos atrás, KotZletY disse:

Nunca vi esse npc de promotio, não sei como funciona essa promoção, no script está promovendo a valor 2, esse valor 2 que ta na promotion, "promotion = 2", é a vocação 2 ?

Essa é a questão! 

pelo que eu vi...quando ta 1=1,2,3,4,5,6,7,8 quando ta 2=9,10,11...

 

as vocs ta 5 e 6

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.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.7k

Informação Importante

Confirmação de Termo