- Joined
- Mar 30, 2008
- Messages
- 666
Hey!
I get an error and I don't know why.
Here is my first trigger that gets erorr.
I get an error and I don't know why.
Here is my first trigger that gets erorr.
-
Retaliation
-
Events
- Unit - A unit Is attacked
-
Conditions
- (Level of Retaliation for (Attacked unit)) Greater than or equal to 1
- (Random integer number between 1 and 100) Less than or equal to (5 x (Level of Retaliation for (Attacked unit)))
- (((Attacked unit) is an illusion) Equal to False) and (((Attacking unit) is A melee attacker) Equal to True)
-
Actions
- -------- Variable to determine the special effect which should be placed at point of attacked unit --------
- Set Ret_SpEf = Abilities\Spells\Orc\MirrorImage\MirrorImageCaster.mdl
- -------- Don't modify anything below this line --------
- -------- Here we set variables for main hero's stats to add them to the clone in future --------
- Set Ret_Stats[1] = (Strength of (Attacked unit) (Exclude bonuses))
- Set Ret_Stats[2] = (Agility of (Attacked unit) (Exclude bonuses))
- Set Ret_Stats[3] = (Intelligence of (Attacked unit) (Exclude bonuses))
- -------- Here we store the items of the main hero into the variables in order to get the full damage dealt by illusion afterwards --------
- Set Ret_Items[1] = (Item carried by (Attacked unit) in slot 1)
- Set Ret_Items[2] = (Item carried by (Attacked unit) in slot 2)
- Set Ret_Items[3] = (Item carried by (Attacked unit) in slot 3)
- Set Ret_Items[4] = (Item carried by (Attacked unit) in slot 4)
- Set Ret_Items[5] = (Item carried by (Attacked unit) in slot 5)
- Set Ret_Items[6] = (Item carried by (Attacked unit) in slot 6)
- Set Ret_Loc = (Position of (Attacked unit))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Number of units in Ret_Group) Equal to 0
-
Then - Actions
- Custom script: set udg_Ret_Group = CreateGroup()
- Else - Actions
-
If - Conditions
- Unit - Create 1 Dummy (Retatialitzation) for (Owner of (Attacked unit)) at Ret_Loc facing Default building facing degrees
- Unit - Set level of Retaliation for (Last created unit) to (Level of Retaliation for (Attacked unit))
- -------- Adding stats and items to the newly created hero --------
- Hero - Modify Strength of (Last created unit): Set to Ret_Stats[1]
- Hero - Modify Agility of (Last created unit): Set to Ret_Stats[2]
- Hero - Modify Intelligence of (Last created unit): Set to Ret_Stats[3]
- Hero - Give Ret_Items[1] to (Last created unit)
- Hero - Give Ret_Items[2] to (Last created unit)
- Hero - Give Ret_Items[3] to (Last created unit)
- Hero - Give Ret_Items[4] to (Last created unit)
- Hero - Give Ret_Items[5] to (Last created unit)
- Hero - Give Ret_Items[6] to (Last created unit)
- -------- End --------
- Unit - Order (Last created unit) to Attack (Attacking unit)
- Animation - Change (Last created unit)'s vertex coloring to (100.00%, 100.00%, 100.00%) with 60.00% transparency
- Special Effect - Create a special effect at Ret_Loc using Ret_SpEf
- Unit Group - Add (Last created unit) to Ret_Group
- Special Effect - Destroy (Last created special effect)
- Unit - Add a 1.20 second Unknown expiration timer to (Last created unit)
- Custom script: call RemoveLocation(udg_Ret_Loc)
-
Events
-
Retaliation Cleaning
-
Events
- Unit - A unit Is attacked
-
Conditions
- ((Attacking unit) is in Ret_Group) Equal to True
-
Actions
- -------- Here we are setting the additional damage should be dealt --------
- Set Ret_Damage = (5.00 x (Real((Level of Retaliation for (Attacking unit)))))
- -------- Don't modify anything below this line --------
- Unit - Cause (Attacking unit) to damage (Attacked unit), dealing Ret_Damage damage of attack type Normal and damage type Normal
- Unit Group - Remove (Attacking unit) from Ret_Group
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Ret_Group is empty) Equal to True
-
Then - Actions
- Custom script: call DestroyGroup(udg_Ret_Group)
- Else - Actions
-
If - Conditions
-
Events