Distance between Floats not working
#2

Why don't you just use GetDistanceBetweenPoints instead of copying your code 3 times? Bad practice.

pawn Код:
stock Float:GetDistanceBetweenPoints(Float:x1, Float:y1, Float:z1, Float:x2, Float:y2, Float:z2)
{
    x1 -= x2;
    y1 -= y2;
    z1 -= z2;
    return floatsqroot((x1 * x1) + (y1 * y1) + (z1 * z1));
}
Reply


Messages In This Thread
Distance between Floats not working - by Jstylezzz - 18.07.2012, 20:47
Re: Distance between Floats not working - by Vince - 18.07.2012, 21:01
Re: Distance between Floats not working - by Jstylezzz - 18.07.2012, 21:03
Re: Distance between Floats not working - by Vince - 18.07.2012, 21:30
Re: Distance between Floats not working - by Jstylezzz - 18.07.2012, 21:32

Forum Jump:


Users browsing this thread: 1 Guest(s)