Point worldtext: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (typo)
m (removed note)
Line 1: Line 1:
{{csgo point | point_worldtext}}
{{csgo point | point_worldtext}} It is also available in {{tf2|4}}.
{{Note| This entity has also been ported to {{tf2|4}} as of 12/1/2022.}}


[[File:Point worldtext csgo example.jpg|thumb|right|Example text generated by two point_worldtext entities]] It is an entity that displays a text message oriented in the world, at its origin.
[[File:Point worldtext csgo example.jpg|thumb|right|Example text generated by two point_worldtext entities]] It is an entity that displays a text message oriented in the world, at its origin.

Revision as of 17:26, 2 December 2022

point_worldtext is a point entity available in Counter-Strike: Global Offensive Counter-Strike: Global Offensive. It is also available in Team Fortress 2 Team Fortress 2.

Example text generated by two point_worldtext entities

It is an entity that displays a text message oriented in the world, at its origin.

Usage

point_worldtext displays a specified text message in a set position in the world. It can be of any size and color, but the text outline cannot be changed. You can change the text message in-game by firing AddOutput with the parameter "message" and then the message you want to display. One downside of this text type is that it's stationary in the world and it is not part of the HUD, so you can't ensure that all players see it at all times. If you want to display important information that the player(s) must be constantly aware of, then it is better to use a game_text.

Tip.pngTip:The texture sheet has a bone icon assigned to the "~" character.
Note.pngNote: Text, size and color can be edited real time via AddOutput, making this entity very flexible and useful.

Keyvalues

Text Options:
Entity Message (message) <string>
Text that should be displayed.
Text Size (textsize) <float>
Size of the text. Setting this to 0 will display nothing. Negative values will flip the text upside down.
Color (color) <color255>
Color of the text.
Font (font) <material> (only in Portal 2: Community Edition) (also in Team Fortress 2)
Path to the font material sheet
Todo: Add font gallery for Team Fortress 2. Accepts integer values 0 - 11
Orientation (orientation) <integer> (only in Team Fortress 2)
  • 0: stationary text
  • 1: always face the player.
  • 2: ignores pitch (looking up/down)
Text Spacing X (textspacingx) <float> (only in Team Fortress 2)
Spacing between each letter along the X axis. Negative values will invert the text.

Flags

  • 1: Start Disabled
Icon-Bug.pngBug:Team Fortress 2Enable/Disable inputs do not affect text visibility. Setting this flag means the text will never display  [todo tested in ?]
PlacementTip.pngWorkaround:set the textsize keyvalue to 0 and use the SetTextSize input to toggle visibility, or leave message empty and use the SetText input.

Inputs

point_worldtext:
Enable
Start displaying the message text.
Disable
Stop displaying the message text.
Icon-Bug.pngBug:Team Fortress 2Enable/Disable inputs do not affect text visibility. Use the SetTextSize or SetText inputs instead.  [todo tested in ?]
SetMessage <stringRedirectInput/string>
Set the message text.
Icon-Bug.pngBug:Does not work, use AddOutput Message <string> instead.  [todo tested in ?]
SetText <stringRedirectInput/string> (only in Team Fortress 2)
Set the message text.
SetTextSize <floatRedirectInput/float> (only in Team Fortress 2)
Set the message text size. Setting this to 0 will hide the text. Negative values will flip the text upside down.
SetTextSpacingX <floatRedirectInput/float> (only in Team Fortress 2)
Set the spacing between letters along the X axis. Negative values will invert the text.
SetColor <color255RedirectInput/color32> (only in Team Fortress 2)
Set the message color.
SetFont <integerRedirectInput/integer> (only in Team Fortress 2)
Set the message font. Accepts values 0 - 11
SetOrientation <integerRedirectInput/integer> (only in Team Fortress 2)
Set the message orientation

Outputs

See also

  • point_message - A similar entity which displays a small custom message at a specific position in the game world.