I am working on a targeting system in one of my maps and basically what i need to happen is whenever a unit enters into the attack range of of my unit it is shaded a blue tint.
The attack range of my weapon is 7. So i made a region center on to my immortal every .0001 seconds. and i made triggers so when a unit enters the region it turns blue and whenever it leaves the region it resets to regular colors. the region i made has an X and Y size of 14, (because the attack range is 7). when i use these 3 triggers (one to center the region, one when a unit enters the region, one for when a unit leaves the region) it dose not work quite right. my unit can attack a unit before it enters the "Blue zone" in other words, the unit dose not turn blue the right distance from my attacker.
I think the reason for this is because the attack is counting distance between the edge of the radius of each of the units. so i need to know how to either compensate for this or make my attacks go from center to center.
If I did not explane that well enough let me know i can try and explain it better if necessary.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I am working on a targeting system in one of my maps and basically what i need to happen is whenever a unit enters into the attack range of of my unit it is shaded a blue tint. The attack range of my weapon is 7. So i made a region center on to my immortal every .0001 seconds. and i made triggers so when a unit enters the region it turns blue and whenever it leaves the region it resets to regular colors. the region i made has an X and Y size of 14, (because the attack range is 7). when i use these 3 triggers (one to center the region, one when a unit enters the region, one for when a unit leaves the region) it dose not work quite right. my unit can attack a unit before it enters the "Blue zone" in other words, the unit dose not turn blue the right distance from my attacker. I think the reason for this is because the attack is counting distance between the edge of the radius of each of the units. so i need to know how to either compensate for this or make my attacks go from center to center.
If I did not explane that well enough let me know i can try and explain it better if necessary.