SetPlayerTextOverride
One player’s own text for a key - theirs alone, over the server’s.
For a text that differs from player to player: a place their character named, a Codex page written for them. It holds
whatever their language and lasts their visit. nil or "" takes it away (the server’s text, or the game’s, again).
Syntax
Section titled “Syntax”SetPlayerTextOverride(pid, key, text)| Parameter | Type | |
|---|---|---|
pid |
number | the player |
key |
string | the game’s key |
text |
string|nil | the text; nil or "" = no text of their own |
Returns
Section titled “Returns”boolean - false for an unknown player, a bad key, a text over 16 KB or past their 256 KB
Example
Section titled “Example”function OnPlayerSpawn(pid) local home = GetPlayerData(pid, "home_name") if home then SetPlayerTextOverride(pid, "location_suchdol", home) endendSee also
Section titled “See also”GetPlayerTextOverride · SetTextOverride · the The game’s texts group of the index
