A game about forced loneliness, made by TACStudios
1using UnityEngine;
2
3namespace Unity.VisualScripting
4{
5 /// <summary>
6 /// Rounds a decimal number to return an integer.
7 /// </summary>
8 [UnitCategory("Math/Scalar")]
9 [UnitTitle("Round")]
10 public sealed class ScalarRound : Round<float, int>
11 {
12 protected override int Floor(float input)
13 {
14 return Mathf.FloorToInt(input);
15 }
16
17 protected override int AwayFromZero(float input)
18 {
19 return Mathf.RoundToInt(input);
20 }
21
22 protected override int Ceiling(float input)
23 {
24 return Mathf.CeilToInt(input);
25 }
26 }
27}