This is an old revision of the document!
⇐ Index
SetUnitDebugText(<-unit <-text)
Sets a text to appear above a unit.
This text can be used instead of, or in conjunction with SetObjText to display some text above a unit. It does not need to be attached to an object, but it cannot be re-positioned or colored. Despite being labelled a debug function, it can be used in non-editor gameplay. For example, the game uses it to display the out-of-ammo message for the Airship.
The text displayed by SetUnitDebugText is cleared upon game reload. If needed, it is recommended to re-apply the text display inside the :Awake function.
SetUnitDebugText(Self "text goes here")