Exemplo n.º 1
0
        public HttpServer(string gameModeFolder, string host, string port)
        {
            CheckSupported();

            string url = string.Format(FORMAT_URL, host, port, SERVER_API);
            _listener.Prefixes.Add(url);

            // setup request handler:
            _requestHandler = new FileRequestHandler(gameModeFolder);

            // start http listener:
            _listener.Start();
        }
Exemplo n.º 2
0
        public HttpServer(string gameModeFolder, string host, string port)
        {
            CheckSupported();

            string url = string.Format(FORMAT_URL, host, port, SERVER_API);

            _listener.Prefixes.Add(url);

            // setup request handler:
            _requestHandler = new FileRequestHandler(gameModeFolder);

            // start http listener:
            _listener.Start();
        }