I'm trying to find out how to detect range between a triggering unit (casting target ability) and the unit being targeted.
At this stage, I have certain units, that when targeted with a certain ability spawn a unit at it's location.
This issue I'm having is that you can use the ability outside it's range to spawn units, but I don't want this to occur and only work within the ability's range.
The trigger is currently set to detect at 'Generic6 - Complete' stage (ignore shared abilities), not sure whether this has something to do with it?
To return the distance between two points, you can use the Distance Between Points function (aptly named, I know.) Put this in a condition, setting the points to the positions of each unit, and you'll be good to go.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I'm trying to find out how to detect range between a triggering unit (casting target ability) and the unit being targeted.
At this stage, I have certain units, that when targeted with a certain ability spawn a unit at it's location.
This issue I'm having is that you can use the ability outside it's range to spawn units, but I don't want this to occur and only work within the ability's range.
The trigger is currently set to detect at 'Generic6 - Complete' stage (ignore shared abilities), not sure whether this has something to do with it?
Thanks.
To return the distance between two points, you can use the Distance Between Points function (aptly named, I know.) Put this in a condition, setting the points to the positions of each unit, and you'll be good to go.