Util
The utility Module for the computer API!
Functions
positiveModulo
sm.scrapcomputers.util.positiveModulo( x, n )
Reimplementation of sm.util.positiveModule
Arguments:
- x [ integer ] The number.
- n [ integer ] The modulo value.
Returns:
- [ number ] The value.
generateNumberGradient
sm.scrapcomputers.util.generateNumberGradient( numbers, numNumbers )
This generates an interpolated gradient between the numbers provided and is dependent on the ammount of gradient specified.
Arguments:
- numbers [ number[] ] The table of numbers to generate the gradient from.
- numNumbers [ integer ] The ammount of blending each number gets in the gradient table.
Returns:
- [ number[] ] The generated gradient table.