SC2Mapster.com Wiki

Galaxy / Triggers / Category Math

Math

Arithmetic

Arithmetic (Integer)

  • Returns the addition, subtraction, multiplication or division of the specified integer values.

Clamp (Integer)

  • Adjust the value to make sure it stays within the provided bounds.

Arithmetic Multiple (Integer)

  • Returns the addition, subtraction, multiplication or division of the specified integer values in multiple instances.

Arithmetic (Real)

  • Returns the addition, subtraction, multiplication or division of the specified real values.

Clamp (Real)

  • Adjust the value to make sure it stays within the provided bounds.

Arithmetic Multiple (Real)

  • Returns the addition, subtraction, multiplication or division of the specified real values in multiple instances.

Ceiling (Real)

  • Returns the smallest value that is not less than the argument.

Ceiling (Integer)

  • Returns the smallest value that is not less than the argument.

Cycle

  • Increments an integer variable by 1, but keeps it within a given range. If this increment causes the variable to exceed the Max value, the variable is reset to the Min value.

Floor (Real)

  • Returns the largest value less than or equal to the specified number.

Floor (Integer)

  • Returns the largest value less than or equal to the specified number.

Log2 (Real)

  • Returns the log base 2 of a number.

Log2 (Integer)

  • Returns the log base 2 of a number.

Modulo (Real)

  • Uses real values. Returns the remainder after the dividend has been divided by the divisor.

Modulo (Integer)

  • Uses integer values. Returns the remainder after the dividend has been divided by the divisor.

Power (Real)

  • Returns a value raised to a given power or exponent.

Pow2 (Real)

  • Returns 2 to the power of a value.

Pow2 (Integer)

  • Returns 2 to the power of a value.

Power (Integer)

  • Returns a value raised to a given power or exponent.

Round (Real)

  • Returns the value rounded to zero decimal places.

Round (Integer)

  • Returns the value rounded to zero decimal places.

Square Root (Real)

  • Returns the square root of a number.

Square Root (Integer)

  • Returns the square root of a number.

Trunc (Real)

  • Strips off the fractional portion of a real.

Trunc (Integer)

  • Strips off the fractional portion of a real.

Conditionals

Absolute Value (Real)

  • Returns the value of the real without regard to the sign of the real.

Absolute Value (Integer)

  • Returns the value of the integer without regard to the sign of the integer.

Maximum (Real)

  • Returns the highest of the two real values specified.

Maximum (Integer)

  • Returns the highest of the two integer values specified.

Minimum (Real)

  • Returns the lowest of the two real values specified.

Minimum (Integer)

  • Returns the lowest of the two integer values specified.

Random

Random Angle

  • Returns a random angle between 0 and 360 (inclusive).

Random Real

  • Returns a random real between the specified values (inclusive).

Random Integer

  • Returns a random integer between the specified values (inclusive).

Random Percent

  • Returns a random percentage between 0 and 100 (inclusive).

Trigonometry

Arccosine

  • Returns the arccosine of a number. Allowed range is -1 to 1. The returned value is given in degrees.

Arcsine

  • Returns the arcsine of a number. Allowed range is -1 to 1. The returned value is given in degrees.

Arctangent From Value

  • Returns the arctangent of a number. The returned value is given in degrees.

Arctangent From Deltas

  • Returns the arctangent of a set of X and Y deltas. The returned value is given in degrees.

Cosine

  • Returns the cosine of an angle. The angle should be specified in degrees.

Sine

  • Returns the sine of an angle. The angle should be specified in degrees.

Tangent

  • Returns the tangent of an angle. The angle should be specified in degrees.

You must login to post a comment. Don't have an account? Register to get one!