Another tip I have to share, is how to use the default UI’s fonts in your mod projects.
All of the default UI’s fonts are embedded in Data/Gui/Default/Flash/gfxfontlib.swf
. By adding this SWF file as an asset in your mod project, you can reference the default UI’s fonts in ActionScript (for TextFormat
instances, etc.) using their symbol name.
The symbol name of a font is different from its actual name. You can see the symbol name of fonts contained in gfxfontlib.swf
after adding it to your project, by expanding the “gfxfontlib.swf” file in the project panel, and then expanding the “Symbols” folder.
I’ve put together a table which matches the symbol name of each font to its actual name…
Symbol Name | Font |
---|---|
_StandardFont | Futura Std Book Fix |
_StandardFont_bold | Futura Heavy Fix (Bold) |
_StandardFont_italic | Futura Std Book Fix (Italic) |
_Headline | Futura Heavy Fix (Bold) |
_TimerFont | Russel Square Std |
_ComputerTerminal | OCR A Std |