Can't create a perfect circle with beach balls.
#2

You need the trigonometric functions, i.e. sine and cosine.

pawn Код:
new
    Float:radius = 4.0;  
    Float:angle;

while(angle < 360.0)
{
    new Float:x = radius * floatsin(angle, degrees);
    new Float:y = radius * floatcos(angle, degrees);

    CreateDynamicObject(1598, x, y, 10.0, 0.0, 0.0, 0.0);

    angle += 0.5;
}
I'm not too good with trig stuff, but something along those lines ought to work.
Reply


Messages In This Thread
Can't create a perfect circle with beach balls. - by sleepysnowflake - 04.08.2013, 14:53
Re: Can't create a perfect circle with beach balls. - by Vince - 04.08.2013, 15:14
Re: Can't create a perfect circle with beach balls. - by sleepysnowflake - 04.08.2013, 15:31

Forum Jump:


Users browsing this thread: 1 Guest(s)