HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

CasterSystem spells....

02-04-2005, 05:17 PM#1
Shark
ok, here's the trigger, i'll give you the details later...
Gedlee Electric
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Gidlee's Electric Loop (Triggerer)
Actions
Set PointVar = (Position of (Triggering unit))
Set UnitVar = (Triggering unit)
Set IntegerVar = (Level of (Ability being cast) for (Triggering unit))
Set RealVar = (500.00 + (Real((IntegerVar x 150))))
Set GroupVar = (Units within RealVar of (Position of UnitVar) matching (((Owner of (Matching unit)) is an enemy of (Owner of (Triggering unit))) Equal to True))
Custom script: set bj_wantDestroyGroup = true
Custom script: call CasterSetCastSourceLoc(udg_PointVar)
Custom script: call CasterSetRecycleDelay(3)
For each (Integer A) from 1 to (1 + (3 x IntegerVar)), do (Actions)
Loop - Actions
Set UnitVar2 = (Random unit from GroupVar)
Custom script: call CasterCastAbility( GetOwningPlayer(udg_UnitVar), 'A00A',"forkedlightning", udg_UnitVar2, false)
Unit Group - Remove UnitVar2 from GroupVar
-------- prepare the Area argument --------
Custom script: call RemoveLocation(udg_PointVar)



ok, i'm experimenting a bit, and im trying to make a spell that will pick all units in range of the casting unit, cast lightning on them (its a 100dmg, one bolt forked lightning) from the point of the triggering unit.....

i used Big Bad Voodoo as my dummy spell.....
the realVar was meant to be way smaller, but since i'm debugging it, most of the values are scaled up.....

anywayz, the spell is meant to pick several units, and depending on the level of the spell cast (currently only lev 1, i should fix that), it will hit 5/8/10
or to be more accurate, it will pick a random unit, cast lightning on it, and remove that unit from the PickedUnits group, so you can't hit the same unit twice......

some may ask "why don't u use forked lightning when it does the exact same thing ?" well, my answer is - i need to do it this way.... and i want to do it this way :)

once again, the system has to be something like this
1)pick units in range
2) blast one from the position of the unit casting the dummy spell, remove blasted unit from group
3) blast again, until you blasted the whole group OR you hit the max blast number
cap aka max blast number is 4/7/10 depending on the level of the dummy skill....

P.S. Lord Vexorian, i downloaded your Demon Sword and Shield spells (actualy, those are the only ones i had time to look at more closely), great job on the Sword one, but the shield one needs more work. i reworked your shield spell, to work with Mana Shield, but then i figured out some more stuff, so i settled for Mana Shield with limited absorbancy... also, your demon shield keeps on shooting even if the hero reaches 0 MP, which is totaly unfair, since u can keep on pummeling everyone even if you're out of mana... fixed that one too...