dbg_add_font_glyphs

This function adds a range of characters from a TTF font to be used for text rendering in The Debug Overlay. You supply a font name as a string, which must be present in the Included Files.

IMPORTANT The glyphs that you want to add must be present in the given TTF font.

The following values can be used to specify the range:

Font Range Constant
 RangeDescription
-1Default Latin range
0Greek
1Korean
2Japanese
3Chinese Full
4Chinese Simplified Common
5Cyrillic
6Thai
7Vietnamese

 

Syntax:

dbg_add_font_glyphs(filename, [size], [font_range]);

ArgumentTypeDescription
filenameStringThe filename of the TTF file to use
sizeRealOPTIONAL The size of the font in pixels (default is 13)
font_rangeRealOPTIONAL The range of characters to add (default is -1 for the Latin range)

 

Returns:

N/A

 

Example:

dbg_add_font_glyphs("korean_font.ttf", 24, 1);

The above code adds the glyphs of the Korean character range from the TTF font file "korean_font.ttf". The used font size is 24.