Fenix Manual
Fenix Manual
Command Reference
Math Commands

Abs
Acos
Advance
Asin
Atan
Cos
Fget_Angle
Fget_Dist
Near_Angle
Pow
Rand
Rand_Seed
Sin
Sqrt
Tan
Xadvance

Near_Angle
Last Modified: May 29, 2005 21:05PM
(Any)
Description

NEAR_ANGLE(INT ANGLE1, INT ANGLE2, INT MAX_INC)

PARAMETERS:
angle1: Original angle
angle2: Angle of destiny
max_inc: Maximum number of thousandth of degree increasing the original angle.


DESCRIPTION:
This function approximates the first angle to the second to a maximum number of thousandth of degree, and gives back the new angle.

This new angle will never exceed the angle of destiny:

if the distance between both angles is smaller to the parameter of maximum increase, then the resulting angle will be exactly the same as that of the destiny angle.

It is necessary to consider that the value of max_inc will have to be positive; nevertheless, it will be added to or reduced to the original angle according to the side of the circumference where the distance between both angles is smaller.

This function serves as aid to make processes so that they persecute to others but that they have a limited turning capacity each frame

User Contributed Notes
Near_Angle
Add Notes About Notes
There are no user contributed notes for this page.
Last updated: Mon, 30 May 2005 - 10:33:03

Manual © 2005 By Gary Moncrieff(Dazzy), Notes belong to their respective posters