• 🏆 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!

Unrooting + Aggro related questions.

Status
Not open for further replies.
Level 2
Joined
May 22, 2008
Messages
17
How do I make the rooted Tree of Ages/Eternity unroot itself when a specific unit enters a region?

And... is it possible for me to code in such a way that these units will prioritize on attacking a Hero rather than a creep?
i.e. When it is aggro-ed by the creep first for the creep to tank, it will change aggro to the hero when the hero begins attacking it.
 
Last edited:
Level 2
Joined
May 22, 2008
Messages
17
Oh, hi there! And thanks!
What about if there is no triggering unit in a certain region, the ancient will root at a specific area?
I got the "If (Number of units in (Units in Team 1 Gate Keeper Aggro Region <gen>)) Equal to 0" part
I don't know how to deal with the rooting.

P.S. I tested that code and it turns out that it isn't 100% the way I want it to be.
Reason:
1. The tree of ancients lose aggro after awhile (Even though the triggering unit has not pulled the tree far from it's original position and the triggering unit is still within aggro range)
2. The tree then returns to its original position to be rooted (Even without the Rooting Trigger)
3. The tree will not uproot again until (the triggering unit leaves and re-enters the region OR a new triggering unit enters the region)

What I would want:
1. The tree of ancients maintain it's aggro until it is pulled far enough from it's original position.
2. The tree of ancients remains uprooted until there is no triggering unit in the region for 15 seconds.
3. Once the condition "There is no triggering unit in the region for 15 seconds" is true, the tree of ancients will root back at it's original position.

*Bump*
 
Status
Not open for further replies.
Top