This is my first spell as well as first thread here
Please excuse any indecencies I may commit ^^
As this is my first spell, I'm having issues making it MUI. I understand that I've got leaks and such, and I intend on fixing those later, but the main issue is that the spell does not work.
If I cast the spell 3 times simultaneously, it breaks and will not deal damage. The effect still works, but no damage is dealt (neither DOT or instant). I am having issues identifying which parts are non-MUI, and would like some professional help
PS. I didn't know that 'Point with polar opposite' was an option
So I used cosine and sine to recreate it unknowingly xD
Chaos Laser: Opens a portal over the course of 2 seconds, which unleashes a devastating laser that scars the land, as well as those in it's vicinity.
As this is my first spell, I'm having issues making it MUI. I understand that I've got leaks and such, and I intend on fixing those later, but the main issue is that the spell does not work.
If I cast the spell 3 times simultaneously, it breaks and will not deal damage. The effect still works, but no damage is dealt (neither DOT or instant). I am having issues identifying which parts are non-MUI, and would like some professional help
PS. I didn't know that 'Point with polar opposite' was an option
-
Chaos Laser
-

Events
-


Unit - A unit Starts the effect of an ability
-
-

Conditions
-


(Ability being cast) Equal to Chaos Laser
-
-

Actions
-


-------- Config --------
-


-------- Pretend that there is config here. I removed it to save space --------
-


-------- ---------------------------- --------
-


-------- Trigger starts here --------
-


-------- ---------------------------- --------
-


Set chaosMaxIndex = (chaosMaxIndex + 1)
-


Set comboUnit[chaosMaxIndex] = (Casting unit)
-


Set comboTarget[chaosMaxIndex] = (Target unit of ability being cast)
-


-------- Is it targeting a unit or the ground? --------
-


If ((Unit-type of comboTarget[chaosMaxIndex]) Not equal to No unit-type) then do (Set castPoint[chaosMaxIndex] = (Position of comboTarget[chaosMaxIndex])) else do (Set castPoint[chaosMaxIndex] = (Target point of ability being cast))
-


Set tempPoint[chaosMaxIndex] = (Point(((X of castPoint[chaosMaxIndex]) + (600.00 x (Cos((180.00 + (Facing of comboUnit[chaosMaxIndex])))))), ((Y of castPoint[chaosMaxIndex]) + (600.00 x (Sin((180.00 + (Facing of comboUnit[chaosMaxIndex]))))))))
-


-------- !! DO THIS AT THE END !! --------
-


Unit Group - Remove all units from chaosDmgGroup[chaosMaxIndex]
-


If (chaosStun Equal to True) then do (Unit - Pause comboTarget[chaosMaxIndex]) else do (Do nothing)
-


Unit - Create 1 chaosDummy for (Owner of comboUnit[chaosMaxIndex]) at tempPoint[chaosMaxIndex] facing (Facing of comboUnit[chaosMaxIndex]) degrees
-


Unit Group - Add (Last created unit) to tempGroup[chaosMaxIndex]
-


-------- Effects --------
-


Animation - Change (Last created unit)'s vertex coloring to (100.00%, 100.00%, 0.00%) with 0.00% transparency
-


Animation - Change (Last created unit)'s animation speed to 300.00% of its original speed
-


Animation - Play (Last created unit)'s birth animation
-


Trigger - Turn on loop <gen>
-
-
-
loop
-

Events
-


Time - Every 0.03 seconds of game time
-
-

Conditions
-

Actions
-


For each (Integer chaosCurrentIndex) from 1 to chaosMaxIndex, do (Actions)
-



Loop - Actions
-




-------- Effects --------
-




Set timeKeeper[chaosCurrentIndex] = (timeKeeper[chaosCurrentIndex] + 1)
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






timeKeeper[chaosCurrentIndex] Equal to 67
-
-





Then - Actions
-






Unit - Create 1 laserDummy for (Owner of comboUnit[chaosCurrentIndex]) at tempPoint[chaosCurrentIndex] facing (Facing of comboUnit[chaosCurrentIndex]) degrees
-






Unit Group - Add (Last created unit) to tempGroup[chaosCurrentIndex]
-






Animation - Change (Last created unit)'s size to (150.00%, 0.00%, 0.00%) of its original size
-






For each (Integer A) from 1 to 10, do (Actions)
-







Loop - Actions
-








Unit - Create 1 laserDummy for (Owner of comboUnit[chaosCurrentIndex]) at tempPoint[chaosCurrentIndex] facing (Facing of comboUnit[chaosCurrentIndex]) degrees
-








Unit Group - Add (Last created unit) to tempGroup[chaosCurrentIndex]
-








Animation - Change (Last created unit)'s size to (75.00%, 0.00%, 0.00%) of its original size
-
-
-






-------- Pick units and deal damage --------
-






For each (Integer A) from 1 to 100, do (Actions)
-







Loop - Actions
-








If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-









If - Conditions
-










chaosLaserDamage[(Integer A)] Not equal to 0.00
-
-









Then - Actions
-










If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-











If - Conditions
-












And - All (Conditions) are true
-













Conditions
-














(Level of Chaos Laser for comboUnit[chaosCurrentIndex]) Equal to (Integer A)
-














FriendlyFire Equal to False
-
-
-
-











Then - Actions
-












Unit Group - Add all units of (Units within 50.00 of castPoint[chaosCurrentIndex] matching (((Matching unit) belongs to an ally of (Owner of comboUnit[chaosCurrentIndex])) Not equal to True)) to chaosDmgGroup[chaosCurrentIndex]
-












Custom script: exitwhen true
-
-











Else - Actions
-












Unit Group - Add all units of (Units within 50.00 of castPoint[chaosCurrentIndex]) to chaosDmgGroup[chaosCurrentIndex]
-
-
-










Unit Group - Pick every unit in chaosDmgGroup[chaosCurrentIndex] and do (Actions)
-











Loop - Actions
-












Unit - Cause comboUnit[chaosCurrentIndex] to damage (Picked unit), dealing chaosLaserDamage[(Integer A)] damage of attack type Spells and damage type Magic
-
-
-
-









Else - Actions
-










Custom script: exitwhen true
-
-
-
-
-






Unit - Unpause comboTarget[chaosCurrentIndex]
-






-------- More effects --------
-






For each (Integer A) from 1 to 3, do (Actions)
-







Loop - Actions
-








Special Effect - Create a special effect at castPoint[chaosMaxIndex] using Abilities\Spells\Human\FlameStrike\FlameStrike1.mdl
-








Set tempSpecEffGroup[(Integer A)] = (Last created special effect)
-
-
-






Trigger - Turn on Chaos Laser DOT <gen>
-






-------- Setup the next index --------
-






Set timeKeeper[chaosCurrentIndex] = 0
-






Set comboUnit[chaosCurrentIndex] = comboUnit[chaosMaxIndex]
-






Set comboTarget[chaosCurrentIndex] = comboTarget[chaosMaxIndex]
-






Set castPoint[chaosCurrentIndex] = castPoint[chaosMaxIndex]
-






Set tempPoint[chaosCurrentIndex] = tempPoint[chaosMaxIndex]
-






Set chaosDmgGroup[chaosCurrentIndex] = chaosDmgGroup[chaosMaxIndex]
-






Set tempGroup[chaosCurrentIndex] = tempGroup[chaosMaxIndex]
-






Set timeKeeper[chaosCurrentIndex] = timeKeeper[chaosMaxIndex]
-






Set chaosMaxIndex = (chaosMaxIndex - 1)
-






Set chaosCurrentIndex = (chaosCurrentIndex - 1)
-






-------- Turn off the periodic event if unneeded --------
-






If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-







If - Conditions
-








chaosMaxIndex Equal to 0
-
-







Then - Actions
-








Trigger - Turn off (This trigger)
-
-







Else - Actions
-
-
-





Else - Actions
-
-
-
-
-
-
Chaos Laser DOT
-

Events
-


Time - Every 0.25 seconds of game time
-
-

Conditions
-

Actions
-


Set chaosCounter[chaosCurrentIndex] = (chaosCounter[chaosCurrentIndex] + 1)
-


Unit Group - Remove all units from chaosDmgGroup[chaosCurrentIndex]
-


-------- Pick units and deal damage --------
-


For each (Integer A) from 1 to 100, do (Actions)
-



Loop - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






chaosLaserDPT[(Integer A)] Not equal to 0.00
-
-





Then - Actions
-






-------- If the ability level has a damage value --------
-






If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-







If - Conditions
-








And - All (Conditions) are true
-









Conditions
-










(Level of Chaos Laser for comboUnit[chaosCurrentIndex]) Equal to (Integer A)
-










FriendlyFire Equal to False
-
-
-
-







Then - Actions
-








Unit Group - Add all units of (Units within chaosRange[(Integer A)] of castPoint[chaosCurrentIndex] matching (((Matching unit) belongs to an ally of (Owner of comboUnit[chaosCurrentIndex])) Not equal to True)) to chaosDmgGroup[chaosCurrentIndex]
-








-------- Break --------
-








Custom script: exitwhen true
-
-







Else - Actions
-








Unit Group - Add all units of (Units within chaosRange[(Integer A)] of castPoint[chaosCurrentIndex]) to chaosDmgGroup[chaosCurrentIndex]
-
-
-






-------- Deal Damage to units that match --------
-






Unit Group - Pick every unit in chaosDmgGroup[chaosCurrentIndex] and do (Actions)
-







Loop - Actions
-








Unit - Cause comboUnit[chaosCurrentIndex] to damage (Picked unit), dealing chaosLaserDPT[(Integer A)] damage of attack type Spells and damage type Magic
-
-
-
-





Else - Actions
-






-------- Break --------
-






Custom script: exitwhen true
-
-
-
-
-


-------- Cleanup & Reset after delay --------
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




chaosCounter[chaosCurrentIndex] Equal to 12
-
-



Then - Actions
-




-------- !! FIX AND REMOVE OTHER LEAKS !! --------
-




Unit Group - Pick every unit in tempGroup[chaosCurrentIndex] and do (Unit - Explode (Picked unit))
-




For each (Integer A) from 1 to 3, do (Actions)
-





Loop - Actions
-






Special Effect - Destroy tempSpecEffGroup[(Integer A)]
-
-
-




Set chaosCounter[chaosCurrentIndex] = 0
-




-------- If all instances are finished, stop trigger --------
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






chaosMaxIndex Equal to 0
-
-





Then - Actions
-






Trigger - Turn off (This trigger)
-
-





Else - Actions
-
-
-



Else - Actions
-
-
-
Attachments
Last edited:











