SetTextTagText

Parameters
t texttag

The text tag to modify.

s string

New text. Does not support color codes "|c" or "|n" for new line, these symbols are hidden.

To make a new line, you can use the literal "\n" new line character (0x0a LF; and "\r\n" counts as one line break).

height real

The new font size.

comment

Sets the text of a text tag.

note

The height is independent from the camera distance, relative to the screen.

note

Reasonable values for height are 0.02 to 0.1, but there is a limited space the text can be rendered into. The text will be wrapped (character-wise) and begin a new line, respectively be cut off when the vertical limit is exceeded as well or the character is wider than the whole width of the available area. Thus, with a large enough value for height, the text tag won't be visible at all.

"0.25" appears to be a common denominator for text size. See table below.

For example, with height=0.25/32: 32 lines of text can fit onto a single text tag and exactly 50 characters on a single line (repeating pattern: "1234567890", v2.0.3). For height=0.25/16 that's 16 lines of text and 41 digit characters wide.

Characters per line depend upon individual character with, the "@" character can only fit 23 times per line at height=0.25/16.

height chars per line max lines
0.25/1 2 1
0.25/2 5 2
0.25/4 10 4
0.25/8 21 8
0.25/16 41 16
0.25/32 50 32
note

Text tags are not rendered when the game is paused (e.g. Single player and F10 menu is open).

patch

1.07

Source
common.j (suggest an edit or discuss on Github)
return type
nothing
Source code
native SetTextTagText               takes texttag t, string s, real height returns nothing