• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

[Solved] Distance between points condition

Status
Not open for further replies.
Level 2
Joined
Jul 10, 2019
Messages
14
People seem to easily find the distance between point condition. I can't. What are you supposed to click on exactly? The only thing I know is that it's an integer comparison.
 
Be careful to clean up any point (location) values it is passed. Such conditions are a common cause of location leaks.
Interesting. I thought you only get location leaks from regions or variables that set said unit position. Will keep that in mind.
 
All points leak. Basically anytime you make a trigger action and there is a point where you have to replace the default value of (Center of (Playable Map Area)) or (Position of (Triggering Unit)) or whatever, that is always a point, which should be cleaned.

Here you can see how you can check which kind of information the argument wants:

tempsnip.png


And if you look closely, you'll notice that it actually leaks two points, because the distance is measured between two different points. So you need to set two variables, TempPointA and TempPointB, and after that you can make the condition check in an if-then-else statement.
 
Status
Not open for further replies.
Back
Top