From 3c43bad04a1732a1c4cdec925f07b38d2dd9e198 Mon Sep 17 00:00:00 2001 From: Luke Seers <16389426+LukeSeers@users.noreply.github.com> Date: Thu, 3 Feb 2022 09:56:30 +0100 Subject: [PATCH] Fix #16 prevent connecting to yourself(SteamId) --- FizzyFacepunch.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/FizzyFacepunch.cs b/FizzyFacepunch.cs index a233b01..e43b7eb 100644 --- a/FizzyFacepunch.cs +++ b/FizzyFacepunch.cs @@ -103,6 +103,12 @@ public override void ClientConnect(string address) OnClientDisconnected.Invoke(); return; } + + if (address == SteamUserID.ToString()) + { + Debug.Log("You can't connect to yourself."); + return; + } FetchSteamID();