I'm trying to make a spell that picks units in a circular sector and kills them, however I'm having some trouble. The spell is a non targeting spell (based on roar).
Here's the trigger:
The important part is the 2 conditions:
Whenever I try the map it seems to only kill the gnoll from certain angles, even though I'm facing the gnoll.
I have searched the forums but I haven't found anything that helped me to make it succesful. I've messed around with this spell, trying to get it right for hours thus it's starting to piss me off a lot. Help is appreciated
Here's the trigger:
Trigger:
- Unit - A unit Starts the effect of an ability
- (Ability being cast) Equal to Shove
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Shove_Customvalue Less than 100
- Then - Actions
- Set Shove_Customvalue = (Shove_Customvalue + 1)
- Else - Actions
- Set Shove_Customvalue = 1
- If - Conditions
- Set Shove_Caster[Shove_Customvalue] = (Triggering unit)
- Set Shove_Angle[Shove_Customvalue] = (Facing of Shove_Caster[Shove_Customvalue])
- Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- (Angle from (Position of Shove_Caster[Shove_Customvalue]) to (Position of (Picked unit))) Less than or equal to (Shove_Angle[Shove_Customvalue] + 60.00)
- (Angle from (Position of Shove_Caster[Shove_Customvalue]) to (Position of (Picked unit))) Greater than or equal to (Shove_Angle[Shove_Customvalue] - 60.00)
- (Unit-type of (Picked unit)) Equal to Gnoll
- (Distance between (Position of Shove_Caster[Shove_Customvalue]) and (Position of (Picked unit))) Less than or equal to 500.00
- Then - Actions
- Unit - Kill (Picked unit)
- Else - Actions
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
The important part is the 2 conditions:
Trigger:
- (Angle from (Position of Shove_Caster[Shove_Customvalue]) to (Position of (Picked unit))) Less than or equal to (Shove_Angle[Shove_Customvalue] + 60.00)
- (Angle from (Position of Shove_Caster[Shove_Customvalue]) to (Position of (Picked unit))) Greater than or equal to (Shove_Angle[Shove_Customvalue] - 60.00)
Whenever I try the map it seems to only kill the gnoll from certain angles, even though I'm facing the gnoll.
I have searched the forums but I haven't found anything that helped me to make it succesful. I've messed around with this spell, trying to get it right for hours thus it's starting to piss me off a lot. Help is appreciated