Exemple #1
0
        public static void Server(string [] args)
        {
            if (args.Length != 2)
            {
                Console.WriteLine("Usage: LoadTest server <port>");
                return;
            }
            int port = int.Parse(args[1]);

            RunServer.StartServer(port);
        }
Exemple #2
0
        public static void Both()
        {
            Thread serverThread = new Thread(() =>
            {
                RunServer.StartServer(1337);
            });

            serverThread.IsBackground = false;
            serverThread.Start();


            RunClients.StartClients("127.0.0.1", 1337, 1000);
        }
Exemple #3
0
        public static void Both()
        {
            Thread serverThread = new Thread(() =>
            {
                RunServer.StartServer(1337);
            });

            serverThread.IsBackground = false;
            serverThread.Start();

            // test 500 clients, which means 500+500 = 1000 connections total.
            // this should be enough for any server or MMO.
            RunClients.StartClients("127.0.0.1", 1337, 500);
        }