Hello!
I made this spell, but I am needing to use mayNotMove, because without it, if I move to another direction, the last part of the spell goes also to another direction.
I want the spell to keep on the initial point and direction without using mayNotMove, how can I do that?
tfs 0.3.7
Here is the script:
I made this spell, but I am needing to use mayNotMove, because without it, if I move to another direction, the last part of the spell goes also to another direction.
I want the spell to keep on the initial point and direction without using mayNotMove, how can I do that?
tfs 0.3.7
Here is the script:
Code:
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE)
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_ICETORNADO)
setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ICE)
setAttackFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 4.5, 9)
local combat2 = createCombatObject()
setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE)
setCombatParam(combat2, COMBAT_PARAM_EFFECT, CONST_ME_ICETORNADO)
setAttackFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 4.5, 9)
local combat3 = createCombatObject()
setCombatParam(combat3, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE)
setCombatParam(combat3, COMBAT_PARAM_EFFECT, CONST_ME_ICETORNADO)
setAttackFormula(combat3, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 4.5, 9)
local area = createCombatArea(tor1)
setCombatArea(combat, area)
local area2 = createCombatArea(tor2)
setCombatArea(combat2, area2)
local area3 = createCombatArea(tor3)
setCombatArea(combat3, area3)
local function onCastSpell1(parameters)
--mayNotMove(parameters.cid, TRUE)
doCombat(parameters.cid, combat, parameters.var)
end
local function onCastSpell2(parameters)
doCombat(parameters.cid, combat2, parameters.var)
end
local function onCastSpell3(parameters)
--mayNotMove(parameters.cid, FALSE)
doCombat(parameters.cid, combat3, parameters.var)
end
function onCastSpell(cid, var)
local parameters = { cid = cid, var = var, combat1 = combat1, combat2 = combat2, combat3 = combat3 }
addEvent(onCastSpell1, 1, parameters)
addEvent(onCastSpell2, 500, parameters)
addEvent(onCastSpell3, 1000, parameters)
return true
end