| /proc/SolveQuadratic | The quadratic formula. Returns a list with the solutions, or an empty list if they are imaginary. |
|---|
| /proc/closer_angle_difference | Finds the shortest angle that angle A has to change to get to angle B. Aka, whether to move clock or counterclockwise. |
|---|
| /proc/gaussian | Converts a uniformly distributed random number into a normally distributed one using the Box-Muller transform
Since this method produces two random numbers, one is saved for subsequent calls (making the cost negligible for every second call)
This will return +/- decimals, situated about mean with standard deviation stddev
68% chance that the number is within 1stddev
95% chance that the number is within 2stddev
98% chance that the number is within 3stddev...etc |
|---|
| /proc/get_overlap | Returns a list where [1] is all x values and [2] is all y values that overlap between the given pair of rectangles |
|---|
| /proc/directional_bounded_sum | Adjusts a value by a given amount while respecting specified bounds
Prevents inadvertently increasing the value in the wrong direction when at bounds |
|---|
| /proc/sqrtor0 | Calculates the square root of a number, returning 0 for negative inputs to avoid runtime errors |
|---|
| /proc/round_down | MARK: THIS DONT WORK! |
|---|
| /proc/get_angle | Calculate the angle between two movables and the west|east coordinate |
|---|
| /proc/delta_to_angle | Calculate the angle produced by a pair of x and y deltas |
|---|
| /proc/get_angle_raw | Angle between two arbitrary points and horizontal line same as /proc/get_angle |
|---|
| /proc/normalize_angle | Get normalized angle (for fix rotation animation bug near 90 and -90 degrees) |
|---|
| /proc/get_line | Get a list of turfs in a line from starting_atom to ending_atom. |
|---|
| /proc/display_joules | Format an energy value in J, kJ, MJ, or GJ. 1W = 1J/s. |
|---|
| /proc/display_power | Formats a power value in W, kW, MW, or GW. |
|---|
| /proc/make_bit_triplet | Generates a bit triplet by selecting three unique numbers from 1 to 9 and setting corresponding bits
Returns a number with three bits set based on the selected numbers |
|---|
| /proc/between | Ensures a value is between a minimum and maximum, clamping it if necessary |
|---|
| /proc/dd_range | Clamps a number to the specified range |
|---|