GameMaker Touhou Engine   Home   Downloads   Documentation

_DRAW_DIGIT_DECIMAL()


A script that draws an unsigned real number with the given amount of decimal places using a given sprite.


Returns: Void


Syntax:


_DRAW_DIGIT_DECIMAL(dx, dy, dg, dw, ds, n, _pi, ci, mx, dec)

Arguments:


Name Value Significance
dx <integer> The X-coordinate to draw the digit at the leftmost decimal place at.
dy <integer> The Y-coordinate to draw the number at.
dg* <sprite> The sprite to use.
dw <integer> The width of a single digit in dg.
ds <integer> The space between each digit in dg.
n <real(0-)> The number to draw.
_pi <integer> The index of the point in dg. (counted from 0)
ci <integer> The index of the comma in dg. (counted from 0)
mx <integer> The maximum number to draw. The final number displayed will be n modulo mx.
dec <integer> The amount of decimal places to draw.

*Must be in the same format as the _DIGITS... sprites.


Actions:


Draw each digit behind the decimal point one by one using _DRAW_DIGIT_SINGLE(). Do the same for every digit before it. Draw the decimal point.