diff options
| author | Magnus Auvinen <magnus.auvinen@gmail.com> | 2007-05-22 15:03:32 +0000 |
|---|---|---|
| committer | Magnus Auvinen <magnus.auvinen@gmail.com> | 2007-05-22 15:03:32 +0000 |
| commit | 73aa9b71c1d8b5c5065d1e474f13601da3ca6b20 (patch) | |
| tree | 88b6a0a4a2ebdd33a88f4a25682581d329d33f6b /masterserver/src/main.cpp | |
| download | zcatch-73aa9b71c1d8b5c5065d1e474f13601da3ca6b20.tar.gz zcatch-73aa9b71c1d8b5c5065d1e474f13601da3ca6b20.zip | |
started the major restructure of svn
Diffstat (limited to 'masterserver/src/main.cpp')
| -rw-r--r-- | masterserver/src/main.cpp | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/masterserver/src/main.cpp b/masterserver/src/main.cpp new file mode 100644 index 00000000..380830ad --- /dev/null +++ b/masterserver/src/main.cpp @@ -0,0 +1,29 @@ +#include <cstdio> +#include <cstdlib> + +#include "masterserver.h" + +int main(int argc, char *argv[]) +{ + if (argc != 2) + { + puts("Usage: masterserver <port> (this will bind the server to the port specified (both udp and tcp)."); + return -1; + } + + int port = atoi(argv[1]); + + CMasterServer masterServer; + masterServer.Init(port); + + while (1) + { + masterServer.Tick(); + + thread_sleep(10); + } + + masterServer.Shutdown(); + + return 0; +} |