Exemplo de uma das magias Intense Healing!!
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HEALING)
setCombatParam(combat, COMBAT_PARAM_EFFECT, 12)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false)
setCombatParam(combat, COMBAT_PARAM_DISPEL, CONDITION_PARALYZE)
setHealingFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 5, 6)
function onCastSpell(cid, var)
return doCombat(cid, combat, var)
end
spells.xml
<!-- Healing Spells -->
<instant name="Light Healing" words="exura" lvl="9" mana="20" aggressive="0" selftarget="1" exhaustion="1000" needlearn="0" event="script" value="healing/light healing.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="4"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
<vocation id="8"/>
</instant>
<instant name="Antidote" words="exana pox" lvl="10" mana="30" aggressive="0" selftarget="1" exhaustion="1000" needlearn="0" event="script" value="healing/antidote.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="4"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
<vocation id="8"/>
</instant>
<instant name="Antiflame" words="exana flam" lvl="15" mana="35" aggressive="0" selftarget="1" exhaustion="1000" needlearn="0" event="script" value="healing/antiflame.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="4"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
<vocation id="8"/>
</instant>
<instant name="Intense Healing" words="exura gran" lvl="11" mana="70" aggressive="0" selftarget="1" exhaustion="1000" needlearn="0" event="script" value="healing/intense healing.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
</instant>
<instant name="Heal Friend" words="exura sio" lvl="18" mana="140" prem="1" aggressive="0" needtarget="1" params="1" exhaustion="1500" needlearn="0" event="script" value="healing/heal friend.lua">
<vocation id="2"/>
<vocation id="6"/>
</instant>
<instant name="Ultimate Healing" words="exura vita" lvl="20" mana="160" aggressive="0" selftarget="1" exhaustion="1000" needlearn="0" event="script" value="healing/ultimate healing.lua">
<vocation id="1"/>
<vocation id="2"/>
<vocation id="3"/>
<vocation id="5"/>
<vocation id="6"/>
<vocation id="7"/>
</instant>
<instant name="Mass Healing" words="exura gran mas res" lvl="36" mana="350" prem="1" aggressive="0" exhaustion="1500" needlearn="0" event="script" value="healing/mass healing.lua">
<vocation id="2"/>
<vocation id="6"/>
</instant>
<instant name="Divine Healing" words="exura san" lvl="35" mana="200" prem="1" selftarget="1" aggressive="0" exhaustion="1000" needlearn="0" event="script" value="healing/divine healing.lua">
<vocation id="3"/>
<vocation id="7"/>
</instant>
<instant name="Wound Cleansing" words="exana mort" lvl="30" mana="65" prem="1" selftarget="1" aggressive="0" exhaustion="1200" needlearn="0" event="script" value="healing/wound cleasing.lua">
<vocation id="4"/>
<vocation id="8"/>
</instant>
<instant name="exuraico" words="exura ico" lvl="50" mana="90" prem="1" selftarget="1" aggressive="0" exhaustion="1000" needlearn="0" event="script" value="healing/exuraico.lua">
<vocation id="4"/>
<vocation id="8"/>
</instant>