MarkSmartRemark
Lua-Noob in Training :D
- Joined
- Jan 27, 2010
- Messages
- 139
- Reaction score
- 3
Hey guys,
Evocation spell based from WoW, its simple but i hope some people can use it..
Gives a chunk of %mana when you cast, and gives you X amount of mana every Y seconds.. easy config at top of spell..
Let me know if theres any bugs, i just tested it and seems to do what its supposed to..
Also i used on 8.60 cryingdamson(0.3.6) v8.2
-Added Cooldown Exhaust (-tetra20)
-Added Working Animation (-tetra20)
Need Help With:
- Adding config where if player moves, spell is cancelled and he gets no mana. (a bit harder but yea, im sure people can use for other spells too)
Make file in /spells folder
EDIT:
Heres spells.xml
Set exhaust regular, there is individual cooldown on the spell.
Aightt deuces!
Evocation spell based from WoW, its simple but i hope some people can use it..
Gives a chunk of %mana when you cast, and gives you X amount of mana every Y seconds.. easy config at top of spell..
Let me know if theres any bugs, i just tested it and seems to do what its supposed to..
Also i used on 8.60 cryingdamson(0.3.6) v8.2
-Added Cooldown Exhaust (-tetra20)
-Added Working Animation (-tetra20)
Need Help With:
- Adding config where if player moves, spell is cancelled and he gets no mana. (a bit harder but yea, im sure people can use for other spells too)
Make file in /spells folder
Code:
-- >>Script by Tabz!<< --
--{Credits: Colandus, based from healing spell; Tetra20, individual cooldown}
--.::.CONFIG.::.--
local first_mana = 15 --- First %of mana added
local percent_mana = 7.5 --- %of mana added each tick afterwards
local heal_tick = 6 --- How many times will it tick?
local tick_length = 15 --- How long between each tick? [seconds]
local cooldown = 120 --- Cooldown time for this spell (Exhaustion)? [seconds]
--.::.CONFIG.::.--
local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, heal_tick * (tick_length*100))
function onCastSpell(cid, var)
local max_mana = getCreatureMaxMana(cid)
if exhaustion.check(cid,299) then
doPlayerSendCancel(cid, "Your Evocation spell still has "..exhaustion.get(cid, 299).." seconds on cooldown.")
return false
end
doCreatureAddMana(cid, (max_mana*(first_mana/100)))
local cpos = getPlayerPosition(cid)
local function onCastSpell2(parameters)
doCreatureAddMana(cid, (max_mana*(percent_mana/100)))
doSendMagicEffect(cpos, 1)
doSendMagicEffect(cpos, 53)
end
local parameters = {cid = cid, combat = combat, var = var}
for i = 0, math.max(heal_tick, 1) - 1 do
addEvent(onCastSpell2, (tick_length*100) * i, parameters)
end
exhaustion.set(cid,299,cooldown)
return true
end
EDIT:
Heres spells.xml
Code:
<instant name="Evocation" words="Evocation" lvl="7" mana="0" aggressive="0" selftarget="1" exhaustion="2000" needlearn="0" event="script" value="Mage/New/Evocation.lua">
<vocation id="1"/>
</instant>
Set exhaust regular, there is individual cooldown on the spell.
Aightt deuces!
Last edited: