Archived copy of war3source.com, the War3Source forum (2009–2020), rebuilt from the Internet Archive by wc3mods.net. This page was captured on 2012-10-24 (original capture). Forum · All archived topics · Wiki · Bug tracker · Blog

War3:Source

Development => Development and Programming Help => Topic started by: Scyther on May 29, 2012, 02:02:35 AM



Title: X axis of a target?
Post by: Scyther on May 29, 2012, 02:02:35 AM
I want to create an effect where three beams that start on me go to my aim point and two positions to the side of it.

The problem is when I move the target along the X axis it is based on the map not the x axis of the target position..

If this makes sense to anyone, got any idea? :/


Title: Re: X axis of a target?
Post by: -El Diablo on May 30, 2012, 05:47:27 AM
There is a race that goes forward to the target.. but i've gotta recall which one..


Title: Re: X axis of a target?
Post by: Revan on May 30, 2012, 07:47:06 AM
he have already managed it by using the same dirty workaround i've used in anivia

Code:
decl Float:fAngles[3];
GetClientEyeAngles(client, fAngles);
new ax = 1;
if(fAngles[1]<150 && fAngles[1]>25) {
ax = 0;
fAngles[1]=90.0;
}
else if(fAngles[1]>-150 && fAngles[1]<-25) {
ax = 0;
fAngles[1]=90.0;
}