font_get_uvs

This function returns an array with the UV coordinates for the font texture on the texture page, filling in the array with the following values:

This value can then be used in other draw functions, particularly in general drawing when using primitives as well as the Shader functions.

 

Syntax:

font_get_uvs(font);

ArgumentTypeDescription
fontFont AssetThe index of the font to use.

 

Returns:

Array

 

Example:

var tex = font_get_uvs(fnt_Main);
tex_left = tex[0];
tex_top = tex[1];
tex_right = tex[2];
tex_left = tex[3];

The above code will store the UV coordinates for the given background in a local array and then assign the values to instance variables.