This commit is contained in:
Sardelka 2022-08-01 07:14:24 +08:00
parent 4ed4e37604
commit fe5da3cf90

View File

@ -173,7 +173,7 @@ namespace RageCoop.Client.Scripting
/// <summary>
/// Get an <see cref="System.Net.IPEndPoint"/> that the player is currently connected to, or null if not connected to the server
/// </summary>
public static System.Net.IPEndPoint ServerEndPoint { get { return Networking.Client?.ServerConnection.RemoteEndPoint; } }
public static System.Net.IPEndPoint ServerEndPoint { get { return Networking.IsOnServer ? Networking.Client?.ServerConnection.RemoteEndPoint : null; } }
/// <summary>
/// Check if a RAGECOOP menu is visible