Vector2.setRound() - Mtax-Development/GML-OOP GitHub Wiki

Arguments

Name
Type
Optional
value1?
Yes
value2?
Yes

Returns

Not applicable.

Description

Set all values to equivalent closest integers. Numbers that are exactly half-integers will be rounded to closest even integer. The numbers used are based on what arguments are provided:
  • None: Current constructor properties will be rounded.
  • A single number: Will be used for both values.
  • A single array: First two positions will be used for x and y values, respectively.
  • A single constructor: Respective properties will be used.
  • Two numbers: Will be used for x and y values, respectively.

⚠️ **GitHub.com Fallback** ⚠️