The max function compares all arguments with each other and returns the currently highest value. This function can be used with as many arguments as you like. In the example we use a sine and a cosine function to create two arguments with changing values.
sphere.YPosition = max( sin( time * 90 ) * 2, cos( time * 90 ) * 2 );
The function returns always the highest value of all arguments:
|