Dev - Lua Libraries

Lua Command: s3sprite.loadFont

Parameters

Return Values

Signature

int fontID = s3sprite.loadFont(string fontPath)

Description

Loads a font from an Angle Font FNT font definition file and returns its fontID for use with font commands like s3sprite.getFontWidth and s3sprite.createText.

fontPath must be relative to the folder of the current mod and point to an Angle Font FNT ASCII file.

Note:

fontID will be -1 if the font could not be loaded.