SayParameters: Difference between revisions

From Sven Co-op
Jump to navigation Jump to search
Outerbeast (talk | contribs)
mNo edit summary
Outerbeast (talk | contribs)
mNo edit summary
 
Line 13: Line 13:
|-
|-
| <code>ClientSayType GetSayType() const
| <code>ClientSayType GetSayType() const
| Gets the say type of this text.
| Gets the say type of this text:<br/>
* <code>CLIENTSAY_SAY</code> 0 Say
* <code>CLIENTSAY_SAYTEAM</code> 1 Say team
|-
|-
| <code>const string& GetCommand() const
| <code>const string& GetCommand() const
Line 21: Line 23:
| Gets the arguments in this command.
| Gets the arguments in this command.
|}
|}
[[Category:Scripting]]
[[Category:Scripting]]

Latest revision as of 16:51, 30 January 2026

The SayParameters class contains a player's text data when they say something in game chat. It can be used to interpret the text as though it were a command, and its visibility can be controlled. This is used for ClientSay hook.

It has a single property bool ShouldHide: Controls whether this text will be hidden or not. This is implemented as a property accessor and mutator. Default false.

Function Description
CBasePlayer@ GetPlayer() const Gets the player that is saying something.
ClientSayType GetSayType() const Gets the say type of this text:
  • CLIENTSAY_SAY 0 Say
  • CLIENTSAY_SAYTEAM 1 Say team
const string& GetCommand() const Gets the entire command string.
const CCommand@ GetArguments() const Gets the arguments in this command.