Help please

Status
Not open for further replies.
Level 16
Joined
Jul 31, 2012
Messages
2,217
  • Custom script: set bj_wantDestroyGroup = true
  • Set temp_Unit_Group = (Units within 275.00 of (Target point of ability being cast) matching (((Owner of (Matching unit)) Equal to (Random player from Enemy_Players[(Player number of (Owner of (Triggering unit)))])) and (((Matching unit) is A structure) Equal to False)))
  • Unit Group - Pick every unit in (temp_Unit_Group) and do (Actions)
    • Loop - Actions
      • Unit - Cause (Triggering unit) to damage (Picked unit), dealing 100.00 damage of attack type Spells and damage type Normal
in these lines: Enemy_Players[array] contain all enemy players of the player (array)

i used to check the owning players with 3 times or and or and or but i don't want to do this again

Can anybody tell me the problem in these line?
 
Sometimes the filtering is better to do like this.
  • Untitled Trigger 004
    • Events
    • Conditions
    • Actions
      • Unit Group - Pick every unit in (Units within 512.00 of (Center of (Playable map area))) and do (Actions)
        • Loop - Actions
          • Set u1 = (Picked unit)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (u1 is alive) Equal to True
              • (u1 is A structure) Equal to False
              • (u1 belongs to an enemy of (Owner of (Triggering unit))) Equal to True
            • Then - Actions
            • Else - Actions
You propably want to check the enemy status.
 
Status
Not open for further replies.
Back
Top