Skip to content

OnTeamInvite

Usage

  • Return a non-null value to override default behavior

Example Autogenerated

csharp
private void OnTeamInvite( BasePlayer basePlayer, BasePlayer basePlayer2 )
{
    Puts( "OnTeamInvite works!" );
}

Location

  • RelationshipManager::sendinvite(ConsoleSystem/Arg arg)
csharp
//---
		float num = 7f;
		if (Vector3.Distance(basePlayer2.transform.position, basePlayer.transform.position) > num)
		{
			return;
		}
		if (Interface.CallHook("OnTeamInvite", basePlayer, basePlayer2) != null)
		{
			return;
		}
		playerTeam.SendInvite(basePlayer2);
	}
//---

Released under the MIT License.