Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            var console = Console.Out;

            Tracer.LinePart("");
            Console.SetOut(console);
            DebugTextWriter.Register(false);
            RemotingConfiguration.RegisterWellKnownServiceType
                (typeof(ManageModsAndSavefiles), "", WellKnownObjectMode.Singleton);

            using (var server = new FileBasedServer("Mmasf"))
            {
                var instance = new ManageModsAndSavefiles
                {
                    FactorioInformation = "FactorioInformation Test",
                    UserConfigurations  = new[]
                    {
                        new UserConfiguration
                        {
                            Path = "Test path"
                        }
                    }
                };
                server.Register(instance);
                "(Server)Press any key:".WriteLine();
                var k = Console.ReadKey();
            }
        }
Ejemplo n.º 2
0
        static void Main(string[] args)
        {
            var console = Console.Out;

            Tracer.LinePart("");
            Console.SetOut(console);
            DebugTextWriter.Register(false);

            1.Seconds().Sleep();

            var client = new FileBasedClient("Mmasf");

            var data = client.Get <ManageModsAndSavefiles>();

            "Response to FactorioInformation: ".WriteLine();
            data.FactorioInformation.WriteLine();

            "Response to TestFunction: ".WriteLine();
            data.UserConfigurations[0].Path.WriteLine();

            "(End)Press any key:".WriteLine();
            var k = Console.ReadKey();
        }