Component:StaticFont: Difference between revisions

From Resonite Wiki
add some info
adding see also and a field info
 
Line 11: Line 11:
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|URL|Uri| The location of where to load the font from
|URL|Uri| The location of where to load the font from.
|Padding|Int| How many pixels of padding should be used between letters in the font
|Padding|Int| How many pixels of padding should be used between letters in the font.
|PixelRange|Int|
|PixelRange|Int|
|GlyphEmSize|Int|
|GlyphEmSize|Int|
|MipMaps|Bool| Whether to display lower res versions of the font when it is further away to save on performance
|MipMaps|Bool| Whether to display lower res versions of the font when it is further away to save on performance.
|MipMapFiltering|Filtering|
|MipMapFiltering|Filtering| How to filter transitions between mipmaps when it is viewed at incremental distances further away.
|LODBias|Float| Whether to see lower res versions at smaller distances to save performance
|LODBias|Float| Whether to see lower res versions at smaller distances to save performance.
}}
}}


Line 30: Line 30:
<!--T:5-->
<!--T:5-->
== See Also ==
== See Also ==
* [[Component:FontChain]] for filling missing glyphs.
</translate>
</translate>
[[Category:ComponentStubs]]
[[Category:ComponentStubs]]
[[Category:Components{{#translation:}}|Static Font]]
[[Category:Components{{#translation:}}|Static Font]]
[[Category:Components:Assets{{#translation:}}|Static Font]]
[[Category:Components:Assets{{#translation:}}|Static Font]]

Latest revision as of 17:27, 22 December 2024

Component image 
Static Font component as seen in the Scene Inspector

The StaticFont component is used to store data on a font set like Avali Scratch, Times New Roman, Hieroglyphs, Arial, and Monospaced fonts (monospaced fonts help people with dyslexia).

Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled.
URL Uri The location of where to load the font from.
Padding Int How many pixels of padding should be used between letters in the font.
PixelRange Int
GlyphEmSize Int
MipMaps Bool Whether to display lower res versions of the font when it is further away to save on performance.
MipMapFiltering Filtering How to filter transitions between mipmaps when it is viewed at incremental distances further away.
LODBias Float Whether to see lower res versions at smaller distances to save performance.

Usage

This component is auto generated when importing new font files. Simply find a font file (.TTF or similar) and drop it into the Resonite game window or import through the file browser in the dash. The game will then generate this component on a font object, with the URL field filled with a valid font resource.

Examples

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


See Also