SPELL MUI : need help 2 fix
i tested this trigger few over time i know its aint mui..... i know i should use hashtable ..... but i dont have time yet i might start to study it tomorrow.... its hard for a French guy to understand all meaning
i think the line that use to destroy tree(within 200) of position of picked unit dont work...
here is the code i gets
i tested this trigger few over time i know its aint mui..... i know i should use hashtable ..... but i dont have time yet i might start to study it tomorrow.... its hard for a French guy to understand all meaning
i think the line that use to destroy tree(within 200) of position of picked unit dont work...
here is the code i gets
-
Ameretusu effect
-
Events
-
Unit - A unit Starts the effect of an ability
-
-
Conditions
-
(Ability being cast) Equal to Amaterasu
-
-
Actions
-
Set AmerSuccess[1] = False
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
AmerSuccess[1] Equal to False
-
AmerOwner[(Integer A)] Equal to No unit
-
-
Then - Actions
-
For each (Integer A) from 1 to 40, do (Actions)
-
Loop - Actions
-
Set AmerTarget3[(Integer A)] = (Position of (Target unit of ability being cast))
-
Set AmerPlayer[1] = (Owner of (Triggering unit))
-
Set AmerReal3[(Integer A)] = 10.00
-
Set AmerOwner[(Integer A)] = (Triggering unit)
-
Set AmerReal2[(Integer A)] = (0.18 x ((Real((Level of (Ability being cast) for AmerOwner[(Integer A)]))) x ((Real((Strength of AmerOwner[(Integer A)] (Exclude bonuses)))) + 3.75)))
-
Trigger - Turn on Ameretusu loop <gen>
-
Trigger - Run Ameretusu loop <gen> (checking conditions)
-
-
-
-
Else - Actions
-
-
-
-
Ameretusu loop
-
Events
-
Time - Every 0.25 seconds of game time
-
-
Conditions
-
Actions
-
Set AmerSuccess[1] = False
-
Game - Display to (All players) the text: LOOP BEGIN
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
AmerOwner[(Integer A)] Not equal to No unit
-
-
Then - Actions
-
For each (Integer A) from 1 to 40, do (Actions)
-
Loop - Actions
-
Set AmerSuccess[1] = True
-
Set AmerGroup[(Integer A)] = (Units within 500.00 of AmerTarget3[(Integer A)] matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of AmerPlayer[1]) Equal to True)))
-
Unit Group - Pick every unit in AmerGroup[(Integer A)] and do (Actions)
-
Loop - Actions
-
Set AmerUnit[(Integer A)] = (Picked unit)
-
Set AmerTarget2[(Integer A)] = (Position of AmerUnit[(Integer A)])
-
Set AmerReal3[(Integer A)] = (AmerReal3[(Integer A)] - 0.25)
-
Unit - Cause AmerOwner[(Integer A)] to damage AmerUnit[(Integer A)], dealing AmerReal2[(Integer A)] damage of attack type Spells and damage type Normal
-
Destructible - Pick every destructible within 500.00 of AmerTarget3[(Integer A)] and do (Actions)
-
Loop - Actions
-
Destructible - Kill (Picked destructible)
-
-
-
Destructible - Pick every destructible within 200.00 of AmerTarget2[(Integer A)] and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked destructible) is alive) Equal to True
-
-
Then - Actions
-
Destructible - Pick every destructible within 200.00 of AmerTarget2[(Integer A)] and do (Actions)
-
Loop - Actions
-
Destructible - Kill (Picked destructible)
-
-
-
-
Else - Actions
-
-
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(AmerReal3[(Integer A)] Less than or equal to 0.00) or (AmerSuccess[1] Equal to False)
-
-
Then - Actions
-
Custom script: call DestroyGroup( udg_AmerGroup[ GetForLoopIndexA( ) ] )
-
Custom script: call RemoveLocation( udg_AmerTarget2[ GetForLoopIndexA( ) ] )
-
Trigger - Turn off (This trigger)
-
Game - Display to (All players) the text: END
-
-
Else - Actions
-
-
Custom script: call RemoveLocation( udg_AmerTarget2[ GetForLoopIndexA( ) ] )
-
Custom script: call DestroyGroup( udg_AmerGroup[ GetForLoopIndexA( ) ] )
-
-
-
-
-
-
Else - Actions
-
-
-
Last edited: