diff --git a/FactorioWrapper/MainLoop.cs b/FactorioWrapper/MainLoop.cs index 67e0760..722b7a0 100644 --- a/FactorioWrapper/MainLoop.cs +++ b/FactorioWrapper/MainLoop.cs @@ -25,12 +25,7 @@ public class MainLoop : IDisposable private readonly Settings settings; private readonly string serverId; private readonly string factorioFileName; - -#if WINDOWS private string factorioArguments; -#else - private readonly string factorioArguments; -#endif // This is to stop multiple threads writing to the factorio process concurrently. private readonly SemaphoreSlim factorioProcessLock = new SemaphoreSlim(1, 1); @@ -48,7 +43,6 @@ public class MainLoop : IDisposable private volatile FactorioServerStatus status = FactorioServerStatus.WrapperStarting; private readonly SingleConsumerQueue> messageQueue; -#if WINDOWS private volatile RconMessenger rcon; private int rconPort; private const string rconPassword = "no_one_will_guess_this_awesome_password."; @@ -86,7 +80,6 @@ private async Task ConnectRCON() factorioProcessLock.Release(); } } -#endif public MainLoop(Settings settings, string serverId, string factorioFileName, string factorioArguments) { @@ -95,9 +88,7 @@ public MainLoop(Settings settings, string serverId, string factorioFileName, str this.factorioFileName = factorioFileName; this.factorioArguments = factorioArguments; -#if WINDOWS PrependRconArguments(); -#endif messageQueue = new SingleConsumerQueue>(maxMessageQueueSize, async func => {