Component:StaticFont: Difference between revisions

From Resonite Wiki
m ProbablePrime moved page StaticFont (Component) to Component:StaticFont: Creating component Namespace
add some info
 
(One intermediate revision by one other user not shown)
Line 2: Line 2:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=StaticFontComponent.png
|Image=StaticFontComponent.png
|Name=Static Font
|Name=Static Font
}}
}}
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).


<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|URL|Uri|
|URL|Uri| The location of where to load the font from
|Padding|Int|
|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
|MipMapFiltering|Filtering|
|LODBias|Float| Whether to see lower res versions at smaller distances to save performance
}}
}}


<!--T:3-->
<!--T:3-->
== Usage ==
== 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 <code>URL</code> field filled with a valid font resource.


<!--T:4-->
<!--T:4-->
== Examples ==
== Examples ==
{{stub}}


<!--T:5-->
<!--T:5-->
== Related Components ==
== See Also ==
</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 15:47, 19 November 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
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