From a4b6ddc8365fc2b4ab0101627b3cb8c48d6dda34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sat, 1 Nov 2014 07:48:35 +0100 Subject: [PATCH] StyleCop clean ReplayRecorderConnection --- .../Network/ReplayRecorderConnection.cs | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/OpenRA.Game/Network/ReplayRecorderConnection.cs b/OpenRA.Game/Network/ReplayRecorderConnection.cs index 10820a2c73..86ff1eadc4 100644 --- a/OpenRA.Game/Network/ReplayRecorderConnection.cs +++ b/OpenRA.Game/Network/ReplayRecorderConnection.cs @@ -25,6 +25,17 @@ namespace OpenRA.Network Func chooseFilename; MemoryStream preStartBuffer = new MemoryStream(); + static bool IsGameStart(byte[] data) + { + if (data.Length == 5 && data[4] == 0xbf) + return false; + if (data.Length >= 5 && data[4] == 0x65) + return false; + + var frame = BitConverter.ToInt32(data, 0); + return frame == 0 && data.ToOrderList(null).Any(o => o.OrderString == "StartGame"); + } + public ReplayRecorderConnection(IConnection inner, Func chooseFilename) { this.chooseFilename = chooseFilename; @@ -85,17 +96,6 @@ namespace OpenRA.Network }); } - static bool IsGameStart(byte[] data) - { - if (data.Length == 5 && data[4] == 0xbf) - return false; - if (data.Length >= 5 && data[4] == 0x65) - return false; - - var frame = BitConverter.ToInt32(data, 0); - return frame == 0 && data.ToOrderList(null).Any(o => o.OrderString == "StartGame"); - } - bool disposed; public void Dispose()