]> git.deb.at Git - rhonda/impostor.git/commitdiff
Fix recorder bug
authorAeonLucid <aeonlucid@outlook.com>
Sun, 25 Oct 2020 20:25:00 +0000 (21:25 +0100)
committerAeonLucid <aeonlucid@outlook.com>
Sun, 25 Oct 2020 20:25:00 +0000 (21:25 +0100)
src/.editorconfig
src/Impostor.Server/Net/Inner/Objects/InnerMeetingHud.cs
src/Impostor.Server/Recorder/ClientRecorder.cs
src/Impostor.Tools.ServerReplay/Impostor.Tools.ServerReplay.csproj

index 3e16c22566fa8483b221b189e0679e7c94fafb71..d88593122c01fdc5af914fea4fffecf478d85853 100644 (file)
@@ -79,16 +79,15 @@ dotnet_naming_symbols.constants.required_modifiers = const
 
 dotnet_naming_style.constant_style.capitalization = pascal_case
 
-# Static fields are camelCase and start with s_
+# Static readonly fields are PascalCase
 dotnet_naming_rule.static_fields_should_be_camel_case.severity = suggestion
 dotnet_naming_rule.static_fields_should_be_camel_case.symbols = static_fields
 dotnet_naming_rule.static_fields_should_be_camel_case.style = static_field_style
 
 dotnet_naming_symbols.static_fields.applicable_kinds = field
-dotnet_naming_symbols.static_fields.required_modifiers = static
+dotnet_naming_symbols.static_fields.required_modifiers = static, readonly
 
-dotnet_naming_style.static_field_style.capitalization = camel_case
-# dotnet_naming_style.static_field_style.required_prefix = s_
+dotnet_naming_style.static_field_style.capitalization = pascal_case
 
 # Instance fields are camelCase and start with _
 dotnet_naming_rule.instance_fields_should_be_camel_case.severity = suggestion
index 439a050ad30e3cacde7eac0b55e1f0600e701714..6a832277121fbbdcd01ca781f500f2a4fa3d0a28 100644 (file)
@@ -50,8 +50,6 @@ namespace Impostor.Server.Net.Inner.Objects
             {
                 case RpcCalls.Close:
                 {
-                    Console.WriteLine("CLOSEEEE MEETING");
-
                     if (!sender.IsHost)
                     {
                         throw new ImpostorCheatException($"Client sent {nameof(RpcCalls.Close)} but was not a host");
index 0917eb351f92e1e19ae8d631bb053456f93619d7..90d644ffb0c629fb2d6c59be29ad0b7d7b1a53d9 100644 (file)
@@ -63,6 +63,9 @@ namespace Impostor.Server.Recorder
                 }
 
                 _recordAfter = false;
+
+                // Trigger message event.
+                await _recorder.WriteMessageAsync(this, messageCopy, messageType);
             }
 
             if (_recordAfter)
index 53ce7bfc9401e9001ebc99cdd81a51133b2a1db9..98fa689f8f38e3b3cec9e035e503edf82d2e4cc5 100644 (file)
@@ -1,16 +1,16 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
-    <PropertyGroup>
-        <OutputType>Exe</OutputType>
-        <TargetFramework>net5.0</TargetFramework>
-    </PropertyGroup>
+  <PropertyGroup>
+    <OutputType>Exe</OutputType>
+    <TargetFramework>net5.0</TargetFramework>
+  </PropertyGroup>
 
-    <ItemGroup>
-      <ProjectReference Include="..\Impostor.Server\Impostor.Server.csproj" />
-    </ItemGroup>
+  <ItemGroup>
+    <ProjectReference Include="..\Impostor.Server\Impostor.Server.csproj"/>
+  </ItemGroup>
 
-    <ItemGroup>
-      <PackageReference Include="Serilog.Sinks.Console" Version="3.1.1" />
-    </ItemGroup>
+  <ItemGroup>
+    <PackageReference Include="Serilog.Sinks.Console" Version="3.1.1"/>
+  </ItemGroup>
 
 </Project>