From 84063b674c474581b5eec2e5f168a2d20e4a84a7 Mon Sep 17 00:00:00 2001 From: james7132 Date: Sun, 10 Nov 2019 17:03:21 -0800 Subject: [PATCH] Fix indentation --- Facepunch.Steamworks/SteamNetworking.cs | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/Facepunch.Steamworks/SteamNetworking.cs b/Facepunch.Steamworks/SteamNetworking.cs index 9b89755..41b592d 100644 --- a/Facepunch.Steamworks/SteamNetworking.cs +++ b/Facepunch.Steamworks/SteamNetworking.cs @@ -91,10 +91,10 @@ public static bool IsP2PPacketAvailable( int channel = 0 ) var buffer = Helpers.TakeBuffer( (int) size ); fixed ( byte* p = buffer ) - { - SteamId steamid = 1; - if ( !Internal.ReadP2PPacket( (IntPtr)p, (uint) buffer.Length, ref size, ref steamid, channel ) || size == 0 ) - return null; + { + SteamId steamid = 1; + if ( !Internal.ReadP2PPacket( (IntPtr)p, (uint) buffer.Length, ref size, ref steamid, channel ) || size == 0 ) + return null; var data = new byte[size]; Array.Copy( buffer, 0, data, 0, size ); @@ -104,7 +104,7 @@ public static bool IsP2PPacketAvailable( int channel = 0 ) SteamId = steamid, Data = data }; - } + } } /// @@ -112,9 +112,9 @@ public static bool IsP2PPacketAvailable( int channel = 0 ) /// public unsafe static bool ReadP2PPacket( byte[] buffer, ref uint size, ref SteamId steamid, int channel = 0 ) { - fixed (byte* p = buffer) { - return Internal.ReadP2PPacket( (IntPtr)p, (uint)buffer.Length, ref size, ref steamid, channel ); - } + fixed (byte* p = buffer) { + return Internal.ReadP2PPacket( (IntPtr)p, (uint)buffer.Length, ref size, ref steamid, channel ); + } } /// @@ -122,7 +122,7 @@ public unsafe static bool ReadP2PPacket( byte[] buffer, ref uint size, ref Steam /// public unsafe static bool ReadP2PPacket( byte* buffer, uint cbuf, ref uint size, ref SteamId steamid, int channel = 0 ) { - return Internal.ReadP2PPacket( (IntPtr)buffer, cbuf, ref size, ref steamid, channel ); + return Internal.ReadP2PPacket( (IntPtr)buffer, cbuf, ref size, ref steamid, channel ); } /// @@ -147,9 +147,9 @@ public static unsafe bool SendP2PPacket( SteamId steamid, byte[] data, int lengt /// NOTE: The first packet send may be delayed as the NAT-traversal code runs. /// public static unsafe bool SendP2PPacket( SteamId steamid, byte* data, uint length, int nChannel = 1, P2PSend sendType = P2PSend.Reliable ) - { - return Internal.SendP2PPacket( steamid, (IntPtr)data, (uint)length, (P2PSend)sendType, nChannel ); + { + return Internal.SendP2PPacket( steamid, (IntPtr)data, (uint)length, (P2PSend)sendType, nChannel ); } } -} \ No newline at end of file +}