Você já viu algumas dessas magias?
Kage bunshin no jutsuTonton
Chunnin bunshin no jutsu
Você pode modificá-las para sumonar outros monstros, é só saber.
Vou pegar como exemplo a magia "Tonton".
attackType = ATTACK_NONE
animationEffect = NM_ANI_NONE
hitEffect = NM_ME_NONE
damageEffect = NM_ME_MAGIC_ENERGIE
animationColor = GREEN
offensive = false
drawblood = false
EnergieObject = MagicDamageObject(attackType, animationEffect, hitEffect, damageEffect, animationColor, offensive, drawblood, 0, 0)
function onCast(cid, creaturePos, level, maglv)
centerpos = {x=creaturePos.x, y=creaturePos.y, z=creaturePos.z}
time = 10
ret = summonCreature(cid, 'Tonton')
if (ret) then
doTargetMagic(cid, centerpos, time, EnergieObject:ordered())
end
return ret
end
Nessa parte:
ret = summonCreature(cid, 'Tonton')
Em vermelho, você muda o monstro que o player irá sumonar.
Um exemplo de magia já pronta, dessa vez sumonando uma "Ameba":
Ameba.lua (coloque na pasta instant)
attackType = ATTACK_NONE
animationEffect = NM_ANI_NONE
hitEffect = NM_ME_NONE
damageEffect = NM_ME_MAGIC_ENERGIE
animationColor = GREEN
offensive = false
drawblood = false
EnergieObject = MagicDamageObject(attackType, animationEffect, hitEffect, damageEffect, animationColor, offensive, drawblood, 0, 0)
function onCast(cid, creaturePos, level, maglv)
centerpos = {x=creaturePos.x, y=creaturePos.y, z=creaturePos.z}
time = 10
ret = summonCreature(cid, 'Ameba')
if (ret) then
doTargetMagic(cid, centerpos, time, EnergieObject:ordered())
end
return ret
end
(Perceba que eu apenas mudei o nome do monstro para ameba...)
Então, lá no spells.xml adicione a tag:
<spell name="Ameba" words="summon ameba" maglv="1" mana="20" enabled="1"><vocation id="1" /><vocation id="2" /><vocation id="3" /><vocation id="4" /><vocation id="5" /><vocation id="6" /><vocation id="7" /><vocation id="8" /><vocation id="9" /></spell>
Em negrito o nome do arquivo.lua, e em vermelho, respecivamente, palavras da magia, ml necessário e mana que será gasta.
Dúvidas? Pergunte :smile_positivo:




info
Grupo: Campones
Registrado: 15/05/11
Posts: 17
Reputação: +2
Preciso de um pet system para meu serv (narutibia >>> Dno V2) so q, sem ser por talkactions ja q n tem isso no meu (=0)
e sim ser por magia se possível, dou rep++
Editado Junho 4 por rasinske