Skip to main content

Sprites Prefabs

Sprites

This array contains sprite-based prefabs such as the hint.

Hint

Displays a text message on the screen.

Usage

"sprites": [
{
"hint": {
"text": "Simple Text!",
"font": "path/to/font/file",
"color": "1 0 0 1",
"size": "30 10",
"translation": "0 0",
"rotation": "0 0 0"
}
// ...
}
// ...
]
ParameterDescriptionOptionalDefault Value

text

The message to display.

++

font

Path to the font file. Supported formats are .otf, .otc, .ttf, and .ttc.

`${props.title} icon`

default font

color

Text color. When using multiple hints, set the color explicitly for each hint; each hint supports only one color.

`${props.title} icon`

"1 1 1 1"

size

Size of the text area, expressed as X Y percentages of the geometric mean of the screen dimensions. Each component is clamped to [0, 150].

`${props.title} icon`

"30 10"

translation

Translates the center of the hint relative to the center of the screen along the X and Y axes, as percentages of the screen dimensions.

`${props.title} icon`

"0 0"

rotation

Rotation angles in degrees. Only rotation around the Z axis is supported.

`${props.title} icon`

"0 0 0"

Preview

Right image compareLeft image compare
Drag