W data/spells/scripts tworzymy notatnik , a w nim wpisujemy:
local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE) setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0) setCombatParam(combat, COMBAT_PARAM_DISPEL, CONDITION_PARALYZE) function onCastSpell(cid, var) doPlayerAddMana(cid, x) doPlayerAddHealth(cid,y) return doCombat(cid, combat, var) end
Zapisujemy jako: manaa.lua
x - tu wpisujemy ile many ma nam dodawać runa po użyciu y - tu wpisujemy ile życia ma nam dawać runa po użyciu
W data/spells.xml dodajemy:
<rune name="ManaUh" id="2281" charges="10" lvl="150" needtarget="1" maglv="15" exhaustion="1" enabled="1" allowfaruse="1" script="manaa.lua"><vocation id="3"/><vocation id="7"/></rune>
Oczywiscie vocation id mozemy sobie dowolnie zmienic, jak i lvl i mlvl runy itd... Jeżeli chcemy dodac, aby dana profesja mogla robic tą runke to wpisujemy pod conjure w data/spells.xml :
<conjure name="ManaUh" words="adura mana" reagentId="2260" conjureId="2281" aggressive="0" conjureCount="10" maglv="15" mana="2000" soul="0" prem="0" enabled="1" function="conjureItem"><vocation id="7"/></conjure>
|