Node book›Maths
Round
A whole number from a number: the nearest, down or up.
One node on the bench: its dropdown switches between the choices below, keeping the wires that still fit. In a file each choice has its own id.
| Choice | Id | What it does |
|---|---|---|
| nearest | math/Round | The nearest whole number |
| down | math/Floor | The whole number at or under it |
| up | math/Ceil | The whole number at or over it |
nearest
The nearest whole number: 2.5 is 3.
- Does
- A value: worked out when a node wired to it asks
- Runs
- On every machine
- In a file
math/Round
- invaluea number
The number.
- outresulta whole number
The nearest whole number.
down
The whole number at or under it: 2.7 is 2.
- Does
- A value: worked out when a node wired to it asks
- Runs
- On every machine
- In a file
math/Floor
- invaluea number
The number.
- outresulta whole number
Rounded down.
up
The whole number at or over it: 2.1 is 3.
- Does
- A value: worked out when a node wired to it asks
- Runs
- On every machine
- In a file
math/Ceil
- invaluea number
The number.
- outresulta whole number
Rounded up.
Modding