Skip to content

OnMessagePlayer

Usage

  • Return a non-null value to override default behavior

Example Autogenerated

csharp
private void OnMessagePlayer( string msg, BasePlayer instance )
{
    Puts( "OnMessagePlayer works!" );
}

Location

  • BasePlayer::ChatMessage(string msg)
csharp
//---
{
	if (!base.isServer)
	{
		return;
	}
	if (Interface.CallHook("OnMessagePlayer", msg, this) != null)
	{
		return;
	}
	this.SendConsoleCommand("chat.add", new object[]
	{
//---

Released under the MIT License.