PlayerStartTalking: Difference between revisions
(Created page with "{{ClientSide}} This event is called when the player starts talking == C# Syntax == {{CSharp}} <syntaxhighlight lang="C#"> public void OnPlayerStartTalking(player){} </syntaxh...") |
m (category) |
||
| (4 intermediate revisions by one other user not shown) | |||
| Line 1: | Line 1: | ||
This event is called when the player starts talking | This event is called when the player starts talking | ||
{{ClientsideCsJsEvent}} | |||
{{CSharpContainer| | |||
{{ | <syntaxhighlight lang="c#"> | ||
<syntaxhighlight lang=" | public delegate void OnPlayerStartTalkingDelegate(Player player); | ||
public void | |||
</syntaxhighlight> | </syntaxhighlight> | ||
{{Parameters}} | |||
* '''player''': The player talking, expects | * '''player''': The player talking, expects '''RAGE.Elements.Player''' type. | ||
{{Example}} | |||
The example below shows a message for a player when they begin talking. | The example below shows a message for a player when they begin talking. | ||
<syntaxhighlight lang="c#"> | <syntaxhighlight lang="c#"> | ||
RAGE.Events. | RAGE.Events.OnPlayerStartTalking += OnPlayerStartTalking; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<syntaxhighlight lang="c#"> | <syntaxhighlight lang="c#"> | ||
| Line 24: | Line 22: | ||
} | } | ||
</syntaxhighlight> | </syntaxhighlight> | ||
}} | |||
{{JSContainer| | |||
to do | |||
}} | |||
[[Category:Client-side Event]] | |||
Latest revision as of 13:30, 15 May 2019
This event is called when the player starts talking
Client-Side Event
C# Syntax
public delegate void OnPlayerStartTalkingDelegate(Player player);
Parameters
- player: The player talking, expects RAGE.Elements.Player type.
Example
The example below shows a message for a player when they begin talking.
RAGE.Events.OnPlayerStartTalking += OnPlayerStartTalking;
public void OnPlayerStartTalking(RAGE.Elements.Player player)
{
RAGE.Chat.Output($"Player {player.Name} started talking");
}
JavaScript Syntax
to do