Ir para conteúdo

Ajuda Com Vocaçoes


gustavoMtek

Posts Recomendados

Testou com um problema que nao sei oque pode ser...

tenho um server e pretendo cria novos tipos de vocaçao

 

meu vocations.xml acredito que nao aja erros, mais olha... nao é o original que vai fika no server pq nao estou com criatividade pra cria os nome agr so pra posta bunitinho aki no xtibia....

 

 

<?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="400" 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="Sorcerer" description="a sorcerer" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="70" gainmanaticks="3" gainmanaamount="170" manamultiplier="1.1" attackspeed="500" 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="Druid" description="a druid" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="70" gainmanaticks="3" gainmanaamount="170" manamultiplier="1.1" attackspeed="500" 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="Paladin" description="a paladin" needpremium="0" gaincap="20" gainhp="10" gainmana="15" gainhpticks="4" gainhpamount="140" gainmanaticks="4" gainmanaamount="140" manamultiplier="1.4" attackspeed="400" soulmax="100" gainsoulticks="120" fromvoc="3">
	<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.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="Knight" description="a knight" needpremium="0" gaincap="25" gainhp="15" gainmana="5" gainhpticks="3" gainhpamount="170" gainmanaticks="6" gainmanaamount="70" manamultiplier="3.0" attackspeed="400" soulmax="100" gainsoulticks="120" fromvoc="4">
	<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.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="5" name="Master Sorcerer" description="a master sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="70" gainmanaticks="3" gainmanaamount="170" manamultiplier="1.1" attackspeed="500" 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="6" name="Elder Druid" description="a elder druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="70" gainmanaticks="3" gainmanaamount="170" manamultiplier="1.1" attackspeed="500" 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="7" name="Royal Paladin" description="a  royal paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="4" gainhpamount="140" gainmanaticks="4" gainmanaamount="140" manamultiplier="1.4" attackspeed="400" soulmax="100" gainsoulticks="120" fromvoc="3">
	<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.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="8" name="Elite Knight" description="a elite knight" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="3" gainhpamount="170" gainmanaticks="6" gainmanaamount="70" manamultiplier="3.0" attackspeed="400" soulmax="100" gainsoulticks="120" fromvoc="4">
	<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.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="Master Sorcerer" description="a master sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="80" gainmanaticks="2" gainmanaamount="180" manamultiplier="1.1" attackspeed="600" soulmax="200" gainsoulticks="15" fromvoc="5" lessloss="30">
	<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="10" name="Elder Druid" description="a elder druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="80" gainmanaticks="2" gainmanaamount="180" manamultiplier="1.1" attackspeed="600" soulmax="200" gainsoulticks="15" fromvoc="6" lessloss="30">
	<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="11" name="Royal Paladin" description="a  royal paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="150" gainmanaticks="3" gainmanaamount="150" manamultiplier="1.4" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="7" lessloss="30">
	<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.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="12" name="Pinto Matador" description="a pinto matador" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="2" gainhpamount="180" gainmanaticks="4" gainmanaamount="80" manamultiplier="3.0" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="8" lessloss="30">
	<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.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="13" name="Master Sorcerer" description="a master sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="90" gainmanaticks="2" gainmanaamount="190" manamultiplier="1.1" attackspeed="600" soulmax="200" gainsoulticks="15" fromvoc="9" lessloss="30">
	<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="14" name="Elder Druid" description="a elder druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="90" gainmanaticks="2" gainmanaamount="350" manamultiplier="1.1" attackspeed="600" soulmax="200" gainsoulticks="15" fromvoc="10" lessloss="30">
	<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="15" name="Royal Paladin" description="a  royal paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="160" gainmanaticks="3" gainmanaamount="160" manamultiplier="1.4" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="11" lessloss="30">
	<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.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="16" name="Matador" description="a matador" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="2" gainhpamount="190" gainmanaticks="4" gainmanaamount="90" manamultiplier="3.0" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="12" lessloss="30">
	<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.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="17" name="Warmasterfull Sorcerer" description="a warmasterfull sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="100" gainmanaticks="2" gainmanaamount="200" manamultiplier="1.1" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="13" lessloss="30">
	<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="18" name="Ancient Druid" description="a ancient druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="100" gainmanaticks="2" gainmanaamount="200" manamultiplier="1.1" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="14" lessloss="30">
	<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="19" name="Blessed Paladin" description="a  blessed paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="150" gainmanaticks="3" gainmanaamount="150" manamultiplier="1.4" attackspeed="400" soulmax="200" gainsoulticks="15" fromvoc="15" lessloss="30">
	<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.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="20" name="Legendary Knight" description="a legendary knight" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="2" gainhpamount="200" gainmanaticks="4" gainmanaamount="100" manamultiplier="3.0" attackspeed="400" soulmax="200" gainsoulticks="15" fromvoc="16" lessloss="30">
	<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.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="21" name="Vip Sorcerer" description="a vip sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="200" gainmanaticks="2" gainmanaamount="400" manamultiplier="1.1" attackspeed="400" soulmax="200" gainsoulticks="15" fromvoc="17" lessloss="30">
	<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="22" name="Vip Druid" description="a vip druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="200" gainmanaticks="2" gainmanaamount="400" manamultiplier="1.1" attackspeed="400" soulmax="200" gainsoulticks="15" fromvoc="18" lessloss="30">
	<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="23" name="Vip Paladin" description="a vip paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="350" gainmanaticks="3" gainmanaamount="350" manamultiplier="1.4" attackspeed="350" soulmax="200" gainsoulticks="15" fromvoc="19" lessloss="30">
	<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.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="24" name="Vip Knight" description="a vip knight" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="2" gainhpamount="400" gainmanaticks="4" gainmanaamount="200" manamultiplier="3.0" attackspeed="350" soulmax="200" gainsoulticks="15" fromvoc="20" lessloss="30">
	<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.1" club="1.1" sword="1.1" axe="1.1" distance="1.4" shielding="1.1" fishing="1.1" experience="1.0"/>
</vocation>
</vocations>

 

 

continuando....

 

criei os 4 npc para promover...

fui la testa e so funcionou até as vocaçao de id:16

 

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({'promotion'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can promote you for 300000 gold coins. Do you want me to promote you?'})
   node1:addChildKeyword({'yes'}, StdModule.promotePlayer, {npcHandler = npcHandler, cost = 300000, premium = true, level = 600, promotion = 3, text = 'Congratulations! You are now promoted.'})
   node1:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Alright then, come back when you are ready boy.', reset = true})


npcHandler:addModule(FocusModule:new())  

/\ funcionou 
\/ nao funcionou

[code]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({'promotion'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I can promote you for 400000 gold coins. Do you want me to promote you?'})
   node1:addChildKeyword({'yes'}, StdModule.promotePlayer, {npcHandler = npcHandler, cost = 400000, premium = true, level = 1200, 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 boy.', reset = true})


npcHandler:addModule(FocusModule:new())  

 

entao precisso de uma ajuda para arrumar isso

 

 

OBs: desculpa pelos erros de porgutgues :X

PS:alguem mova pra sessao correta nao sei aonde posta essa duvida...

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...