From 04b921b33da9c5946d8bc862e6b5af4a14253903 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Straubmeier?= Date: Wed, 16 Feb 2022 11:55:24 +0100 Subject: [PATCH] More detailed debug levels in SteamNetworkingUtils --- Facepunch.Steamworks/SteamNetworkingUtils.cs | 54 ++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/Facepunch.Steamworks/SteamNetworkingUtils.cs b/Facepunch.Steamworks/SteamNetworkingUtils.cs index 5d80499..9833d2d 100644 --- a/Facepunch.Steamworks/SteamNetworkingUtils.cs +++ b/Facepunch.Steamworks/SteamNetworkingUtils.cs @@ -226,6 +226,60 @@ namespace Steamworks set => SetConfigInt( NetConfig.Unencrypted, value ); } + /// + /// Log RTT calculations for inline pings and replies. + /// + public static int DebugLevelAckRTT + { + get => GetConfigInt( NetConfig.LogLevel_AckRTT ); + set => SetConfigInt( NetConfig.LogLevel_AckRTT, value ); + } + + /// + /// Log SNP packets send. + /// + public static int DebugLevelPacketDecode + { + get => GetConfigInt( NetConfig.LogLevel_PacketDecode ); + set => SetConfigInt( NetConfig.LogLevel_PacketDecode, value ); + } + + /// + /// Log each message send/recv. + /// + public static int DebugLevelMessage + { + get => GetConfigInt( NetConfig.LogLevel_Message ); + set => SetConfigInt( NetConfig.LogLevel_Message, value ); + } + + /// + /// Log dropped packets. + /// + public static int DebugLevelPacketGaps + { + get => GetConfigInt( NetConfig.LogLevel_PacketGaps ); + set => SetConfigInt( NetConfig.LogLevel_PacketGaps, value ); + } + + /// + /// Log P2P rendezvous messages. + /// + public static int DebugLevelP2PRendezvous + { + get => GetConfigInt( NetConfig.LogLevel_P2PRendezvous ); + set => SetConfigInt( NetConfig.LogLevel_P2PRendezvous, value ); + } + + /// + /// Log ping relays. + /// + public static int DebugLevelSDRRelayPings + { + get => GetConfigInt( NetConfig.LogLevel_SDRRelayPings ); + set => SetConfigInt( NetConfig.LogLevel_SDRRelayPings, value ); + } + /// /// Get Debug Information via event. ///