User Tools

Site Tools


4rpl:commands:setunitdebugtext

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
4rpl:commands:setunitdebugtext [2022/04/01 01:43] – [Description] DebugText has access to all CW4 formatting Vertu4rpl:commands:setunitdebugtext [2025/02/14 14:57] (current) – external edit 127.0.0.1
Line 9: Line 9:
  
 This text can be used instead of, or in conjunction with [[SetObjText]] to display some text above a unit. It is directly attached to the unit and cannot be re-positioned. Although being labeled as "debug", it can be used in non-editor gameplay. For example, the game uses it to display the out-of-ammo message for the Airship.\\ This text can be used instead of, or in conjunction with [[SetObjText]] to display some text above a unit. It is directly attached to the unit and cannot be re-positioned. Although being labeled as "debug", it can be used in non-editor gameplay. For example, the game uses it to display the out-of-ammo message for the Airship.\\
-Both this API and [[SetObjText]] have access to all compatible formats in CW4. If you plan to resize the text, you will need to use the format "<color #8BDFFF><line-height=[Insert number]></color>" as this type of text will not scale it's line-spacing correctly with the change in text size. Typically; "<color #8BDFFF><line-height=100%></color>" solves this problem very reliably for using "<color #8BDFFF><size=8></color>" which is a neat sizeJust be sure to either limit the line-width by adding "<color #8BDFFF><br></color>" to create new lines or limit the left line-margin using "<color #8BDFFF><margin-right=[Insert number]></color>".\\+Both this API and [[SetObjText]] have access to all compatible formats in CW4. If you plan to resize the text, you will need to use the format "<color #8BDFFF><line-height=[Insert number]></color>" after resizing as the changed size of text will not scale it's line-height correctly without intervention. Typically; "<color #8BDFFF><size=[SOME NUMBER]><line-height=100%></color>" solves this problem entirelyUnlike [[SetObjText]], new lines will be created so you won't need to manually add formats like "<color #8BDFFF><br></color>".\\
 The full list of formats in CW4 can be found in the [[cw4:a.d.a_syntax_syntax_guide|A.D.A. Message editor format]] guide. The full list of formats in CW4 can be found in the [[cw4:a.d.a_syntax_syntax_guide|A.D.A. Message editor format]] guide.
  
4rpl/commands/setunitdebugtext.1648777417.txt.gz · Last modified: 2025/02/14 14:56 (external edit)