Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
Do Multiple ActionsFor each (Integer TH_INT) from 1 to TH_INT, do (Actions)
U need to use a tempInt for the first looping integer and then from 1 to ur max index. Also u dont de-index anywere so u will hit the max array limit somewere.
My tutorial has a chapter on indexing that can help u. Things a GUIer Should Know. its in my sig.
The chapter in there is how to index
Do Multiple ActionsFor each (Integer TempINT) from 1 to TH_INT, do (Actions)
Loop - Actions
Set TempPoint[1] = (Position of TH_Missile[TH_INT])
Set TempPoint[2] = (TempPoint[1] offset by 35.00 towards (Facing of TH_Missile[TH_INT]) degrees)
Set TempUnitGroup = (Units within 50.00 of TempPoint[1] matching ((((Matching unit) belongs to an enemy of (Owner of TH_Missile[TH_INT])) Equal to (==) True) and (((Matching unit) is alive) Equal to (==) True)))
Unit Group - Pick every unit in TempUnitGroup and do (Actions)
Loop - Actions
Unit - Cause TH_Caster[TH_INT] to damage (Picked unit), dealing TH_Damage[TH_INT] damage of attack type Spells and damage type Normal
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Number of units in TempUnitGroup) Greater than or equal to (>=) 1
Then - Actions
Unit - Kill TH_Missile[TH_INT]
-------- End --------
Set TH_INT = (TH_INT - 1)
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
TH_INT Equal to (==) 0
Then - Actions
Game - Display to (All players) the text: off
Trigger - Turn off (This trigger)
Else - Actions
Else - Actions
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
TH_Range[TH_INT] Less than or equal to (<=) 0.00
Then - Actions
Unit - Kill TH_Missile[TH_INT]
-------- End --------
Set TH_INT = (TH_INT - 1)
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
TH_INT Equal to (==) 0
Then - Actions
Game - Display to (All players) the text: off
Trigger - Turn off (This trigger)
Else - Actions
Else - Actions
Unit - Move TH_Missile[TH_INT] instantly to TempPoint[2]
It problem is in ur looping trigger. U need to use the tempInt variable as the index. Ur using the maxindex variable. U only use maxindex variable when de-indexing
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.