Exemplo n.º 1
0
 public CoCRemoteClient(CoCServer server, Socket connection)
 {
     Connection = connection;
     Server = server;
     NetworkManager = new NetworkManagerAsync(connection, HandlePacketReceived, HandleReceicedPacketFailed);
     PacketHandlers = new Dictionary<ushort, PacketHandler>();
 }
Exemplo n.º 2
0
 public CoCRemoteClient(CoCServer server, Socket connection)
 {
     Connection     = connection;
     Server         = server;
     NetworkManager = new NetworkManagerAsync(connection, HandlePacketReceived, HandleReceicedPacketFailed);
     PacketHandlers = new Dictionary <ushort, PacketHandler>();
 }
Exemplo n.º 3
0
 public CoCRemoteClient(CoCServer server, Socket connection, NetworkManagerAsyncSettings settings)
 {
     _server = server;
     Connection = connection;
     Avatar = new Avatar();
     NetworkManager = new NetworkManagerAsync(connection, settings);
     NetworkManager.MessageReceived += OnMessageReceived;
 }
Exemplo n.º 4
0
        public static void Main(string[] args)
        {
            Console.Title = "CoC# Server";

            Server = new CoCServer();
            Server.Start(new IPEndPoint(IPAddress.Any, 9339));
            Console.WriteLine("CoC# Server listening on port *:9339");
            Thread.Sleep(-1);
        }
Exemplo n.º 5
0
        public static void Main(string[] args)
        {
            Console.Title = "CoC# Server";

            Server = new CoCServer();
            Server.Start(new IPEndPoint(IPAddress.Any, 9339));
            Console.WriteLine("CoC# Server listening on port *:9339");
            Thread.Sleep(-1);
        }
Exemplo n.º 6
0
 public CoCRemoteClient(CoCServer server, Socket connection)
 {
     Connection     = connection;
     Server         = server;
     NetworkManager = new NetworkManagerAsync(connection);
     NetworkManager.PacketReceived += OnPacketReceived;
     PacketHandlers = new Dictionary <ushort, PacketHandler>();
     Avatar         = new Avatar();
     Home           = new Village();
 }
Exemplo n.º 7
0
 public CoCRemoteClient(CoCServer server, Socket connection)
 {
     Connection = connection;
     Server = server;
     NetworkManager = new NetworkManagerAsync(connection);
     NetworkManager.PacketReceived += OnPacketReceived;
     PacketHandlers = new Dictionary<ushort, PacketHandler>();
     Avatar = new Avatar();
     Home = new Village();
 }
Exemplo n.º 8
0
        public static void m(string[] args)
        {
            Console.Title = "CoC# - Server";
            var stopwatch = new Stopwatch();
            stopwatch.Start();

            Server = new CoCServer();
            Server.Start();

            stopwatch.Stop();

            Console.WriteLine("Done({0}ms)! Listening on *:9339", stopwatch.Elapsed.TotalMilliseconds);
            Thread.Sleep(Timeout.Infinite);
        }
Exemplo n.º 9
0
 public AvatarManager(CoCServer server)
 {
     NextPlayerID = 1;
     Server = server;
     Avatars = new List<Avatar>();
 }
Exemplo n.º 10
0
 public AvatarManager(CoCServer server)
 {
     NextPlayerID = 1;
     Server       = server;
     Avatars      = new List <Avatar>();
 }