• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

How to make whisps cast a spell on sight?

Status
Not open for further replies.
Level 29
Joined
Mar 10, 2009
Messages
5,016
>>>
  • Untitled Trigger 001
    • Events
    • Conditions
    • Actions
      • Set temppoint = YOUR POINT
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within 600.00 of temppoint matching ((Unit-type of (Matching unit)) Equal to Wisp)) and do (Actions)
        • Loop - Actions
          • Set temppoint2 = (Position of (Picked unit))
          • Unit - Order (Picked unit) to Night Elf Wisp - Detonate temppoint2
          • Custom script: call RemoveLocation(udg_temppoint2)
      • Custom script: call RemoveLocation(udg_temppoint)
 
Level 7
Joined
Feb 22, 2009
Messages
158
You could use "unit acquires a target" event. Make acquisition range same as sightrange. Make a hidden attack for wisps, then remove it and order to use hidden detonate ability on the target.

but it would make a single unit to do that. I wanna that to be like - FOR EVERY WHISP ON THE MAP! It'll be rpg, man, cmon Imagine -

you came to the forest, full of wandering spirits, you can try to walk throughout those, but if you will come too near, those will detonate and absorb mana.

Idea: in the forest will be other creeps too, who will attack, so XP farming will be more difficult!
 
Level 17
Joined
Feb 11, 2011
Messages
1,860
What about this:

  • detonate
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units owned by Neutral Hostile of type Wisp) and do (Actions)
        • Loop - Actions
          • Set p = (Position of (Picked unit))
          • Set p = (Position of (Random unit from (Units within 500.00 of p matching ((((Owner of (Matching unit)) is an enemy of Neutral Hostile) Equal to True) and (((Matching unit) is A Hero) Equal to True)))))
          • Unit - Order (Picked unit) to Night Elf Wisp - Detonate p
          • Custom script: call RemoveLocation(udg_p)
 
Level 7
Joined
Feb 22, 2009
Messages
158
What about this:

  • detonate
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units owned by Neutral Hostile of type Wisp) and do (Actions)
        • Loop - Actions
          • Set p = (Position of (Picked unit))
          • Set p = (Position of (Random unit from (Units within 500.00 of p matching ((((Owner of (Matching unit)) is an enemy of Neutral Hostile) Equal to True) and (((Matching unit) is A Hero) Equal to True)))))
          • Unit - Order (Picked unit) to Night Elf Wisp - Detonate p
          • Custom script: call RemoveLocation(udg_p)

kk this is better :)
 
Status
Not open for further replies.
Top