Math functions - misonou/waterpipe GitHub Wiki
Clamps the input value at the given maximum or minimum value.
{{value}} ➜ 100
{{value max 10}} ➜ 10
{{value max 1000}} ➜ 100
{{value min 10}} ➜ 100
{{value min 1000}} ➜ 1000
Rounds the input value to the integer.
{{value}} ➜ 10.4
{{value round}} ➜ 10
{{value floor}} ➜ 10
{{value ceil}} ➜ 11
Performs basic arithmetic operations.
{{value}} ➜ 10
{{value + 1}} ➜ 11
{{value - 1}} ➜ 9
{{value * 2}} ➜ 20
{{value / 2}} ➜ 5
{{value % 2}} ➜ 0
{{value ^ 2}} ➜ 100