Reference
Numbers
15 Game Mode Studio nodes. Pick one for its pins, settings and limits.
value Math Adds, takes away, multiplies, divides, or picks the smaller or bigger number. value Random Number A random number from Min to Max (whole numbers unless Fractions is on). value Math Function Absolute value, rounding, square root and more; Truncate drops the fraction toward zero (-2.7 becomes -2, where Round down gives -3). value Clamp Keeps a number between Min and Max. value Lerp A number between A and B: Alpha 0 is A, 1 is B, 0.5 halfway. value In Range Is the number from Min to Max? value Number A number. value Random Chance Yes Percent % of the time (a new roll each time it's worked out). value Random Bool Yes or no, half the time each. value Weighted Random Pick Picks an index from an array of weights (a weight of 3 is picked three times as often as 1); with Items wired, the item at that index too. value Map Range A value from one range moved into another: In Min..In Max becomes Out Min..Out Max (Clamp keeps it inside). value Sin / Cos / Tan The sine, cosine or tangent of an angle (degrees, or radians). value Atan2 The angle of the direction X, Y (from the X axis, -180..180 degrees, or radians). value Degrees / Radians Degrees to radians or radians to degrees. value Bitwise Bits of whole numbers (the fractions are dropped): And, Or, Xor, Not (of A), or A shifted left or right by B bits.
Adds, takes away, multiplies, divides, or picks the smaller or bigger number.
Inputs (2) A Number A: a number. Leave it empty to use the setting. B Number B: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (3) A A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Do Pick one: A + B, A - B, A × B, A ÷ B, smaller, bigger, remainder of A ÷ B, A to the power B. Default: add. B A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 1.
value math.random Copy link
A random number from Min to Max (whole numbers unless Fractions is on).
Inputs (2) Min Number Min: a number. Leave it empty to use the setting. Max Number Max: a number. Leave it empty to use the setting. Outputs (1) Number Number The number. Settings (3) Min A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 1. Max A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 10. Fractions On or off. Default: false.
Absolute value, rounding, square root and more; Truncate drops the fraction toward zero (-2.7 becomes -2, where Round down gives -3).
Inputs (1) In Number In: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (2) In A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Do Pick one: Absolute (no minus), Round, Round down, Round up, Square root, Minus, Sign (-1, 0, 1), Truncate (toward zero). Default: abs.
Keeps a number between Min and Max.
Inputs (3) Value Number Value: a number. Leave it empty to use the setting. Min Number Min: a number. Leave it empty to use the setting. Max Number Max: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (3) Value A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Min A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Max A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 100.
A number between A and B: Alpha 0 is A, 1 is B, 0.5 halfway.
Inputs (3) A Number A: a number. Leave it empty to use the setting. B Number B: a number. Leave it empty to use the setting. Alpha Number Alpha: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (3) A A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. B A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 100. Alpha A number from -100 to 100. A wire into the pin of the same name is used instead. Default: 0.5.
value math.in_range Copy link
Is the number from Min to Max?
Inputs (3) Value Number Value: a number. Needs a wire. Min Number Min: a number. Leave it empty to use the setting. Max Number Max: a number. Leave it empty to use the setting. Outputs (1) In range Yes/No In range: yes or no. Settings (2) Min A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Max A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 100.
value math.number Copy link
A number.
Outputs (1) Number Number The number. Settings (1) Number A number from -100000 to 100000. Default: 0.
value random.chance Copy link
Yes Percent % of the time (a new roll each time it's worked out).
Inputs (1) Percent Number Percent: a number. Leave it empty to use the setting. Outputs (1) Yes Yes/No Yes: yes or no. Settings (1) Percent A number from 0 to 100. A wire into the pin of the same name is used instead. Default: 25.
value random.bool Copy link
Yes or no, half the time each.
Outputs (1) Yes Yes/No Yes: yes or no.
value random.weighted Copy link
Picks an index from an array of weights (a weight of 3 is picked three times as often as 1); with Items wired, the item at that index too. -1 when every weight is 0.
Inputs (2) Weights Array of Number Weights: a list of numbers. Needs a wire. Items Array of the node's type Items: a list of the type set in Holds. Optional. Outputs (2) Index# Number Index: a number. Item The node's type Item: the type set in Holds. Settings (1) Holds What kind of values it holds. Default: number.
value math.map_range Copy link
Map Range
Value In Min In Max Out Min Out Max
A value from one range moved into another: In Min..In Max becomes Out Min..Out Max (Clamp keeps it inside).
Inputs (5) Value Number Value: a number. Leave it empty to use the setting. In Min Number In Min: a number. Leave it empty to use the setting. In Max Number In Max: a number. Leave it empty to use the setting. Out Min Number Out Min: a number. Leave it empty to use the setting. Out Max Number Out Max: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (6) Value A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 50. In Min A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. In Max A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 100. Out Min A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 0. Out Max A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 1. Clamp On or off. Default: true.
The sine, cosine or tangent of an angle (degrees, or radians).
Inputs (1) Angle Number Angle: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (3) Angle A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 45. Do Pick one: Sin, Cos, Tan. Default: sin. Angles in Pick one: Degrees, Radians. Default: deg.
The angle of the direction X, Y (from the X axis, -180..180 degrees, or radians).
Inputs (2) Y Number Y: a number. Leave it empty to use the setting. X Number X: a number. Leave it empty to use the setting. Outputs (1) Angle Number Angle: a number. Settings (3) Y A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 1. X A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 1. Angles in Pick one: Degrees, Radians. Default: deg.
value math.angle_convert Copy link
Degrees to radians or radians to degrees.
Inputs (1) Angle Number Angle: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (2) Angle A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 180. Do Pick one: Degrees to radians, Radians to degrees. Default: to_rad.
value math.bitwise Copy link
Bits of whole numbers (the fractions are dropped): And, Or, Xor, Not (of A), or A shifted left or right by B bits. Exact up to 16,777,216.
Inputs (2) A Number A: a number. Leave it empty to use the setting. B Number B: a number. Leave it empty to use the setting. Outputs (1) Result Number Result: a number. Settings (3) A A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 6. B A number from -100000 to 100000. A wire into the pin of the same name is used instead. Default: 3. Do Pick one: And (&), Or (|), Xor (^), Not (~A), Shift left (<<), Shift right (>>). Default: and.
Made from the app's own catalog (nodes.json, nodehelp.json, limits.ts), so it matches the app.