using System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using Microsoft.CodeAnalysis; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: AssemblyCompany("Reso360Spout2.Patcher")] [assembly: AssemblyConfiguration("Release")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+ee8c8eae18fcaddcd0802f601407b6587a92c31c")] [assembly: AssemblyProduct("Reso360Spout2.Patcher")] [assembly: AssemblyTitle("Reso360Spout2.Patcher")] [assembly: AssemblyVersion("1.0.0.0")] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)] internal sealed class NullableAttribute : Attribute { public readonly byte[] NullableFlags; public NullableAttribute(byte P_0) { NullableFlags = new byte[1] { P_0 }; } public NullableAttribute(byte[] P_0) { NullableFlags = P_0; } } [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)] internal sealed class NullableContextAttribute : Attribute { public readonly byte Flag; public NullableContextAttribute(byte P_0) { Flag = P_0; } } } namespace Reso360Spout2Patcher { public static class Patcher { public static IEnumerable TargetDLLs { get; } = Enumerable.Empty(); public static void Initialize() { try { string text = Path.Combine(Path.GetDirectoryName(typeof(Patcher).Assembly.Location), "KlakSpout_send.dll"); if (!File.Exists(text)) { Console.WriteLine("[Reso360Spout2.Patcher] KlakSpout_send.dll not found at: " + text); return; } string text2 = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Renderite.Renderer_Data", "Plugins", "x86_64"); if (!Directory.Exists(text2)) { Console.WriteLine("[Reso360Spout2.Patcher] Unity plugins folder not found: " + text2); return; } string text3 = Path.Combine(text2, "KlakSpout_send.dll"); if (File.Exists(text3) && new FileInfo(text).Length == new FileInfo(text3).Length && File.GetLastWriteTimeUtc(text) <= File.GetLastWriteTimeUtc(text3)) { Console.WriteLine("[Reso360Spout2.Patcher] KlakSpout_send.dll is already up to date."); return; } File.Copy(text, text3, overwrite: true); Console.WriteLine("[Reso360Spout2.Patcher] Copied KlakSpout_send.dll to: " + text3); } catch (Exception arg) { Console.WriteLine($"[Reso360Spout2.Patcher] Error: {arg}"); } } public static void Finish() { } } }