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

Order unit to target unit it can't see?

Status
Not open for further replies.
Level 3
Joined
Mar 11, 2019
Messages
31
Hey all, I'm trying to make it so a sold unit from a mercenary camp will moveto/attack a random player unit, but it only seems to work if fog/blackmask are turned off because the unit can't see the target.

Is there a way to make it so units can target units through fog/black mask across large distances?
 
Level 11
Joined
Nov 23, 2013
Messages
665
Instead of targeting a unit, maybe you could try targeting a point (position of unit)?
 
Level 12
Joined
Nov 3, 2013
Messages
989
Besides giving vision of the target unit for the player who owns the sold unit, I don't think so.


If that's not an option, then I guess you could periodically order the sold unit to move to the target unit's position until it comes within rage of vision and then order it to attack.
 
Level 23
Joined
Jul 26, 2008
Messages
1,317
What you are asking for can be copied over directly from ROC campaign UD03.
You can check the trigger here:
2P Campaign: Undead 03

It is for the starting trigger for Sylvanas to attack Arthas, no matter where he is on the map. The trigger is made so that when Arthas is dead, Sylvanas will target random undead buidings/units until there are none left on map or she dies (this is the initial trigger before she is revived at the bottom-right blue base. You can modify it so it fits your needs. Note: For some reason that map has preview triggers disabled, so I cannot show you the exact name without opening up wc3.
 
Status
Not open for further replies.
Top