Exemplo n.º 1
0
Arquivo: Core.cs Projeto: sopindm/bjeb
        public override void OnStart(StartState state)
        {
            base.OnStart(state);

            var client = new Client("127.0.0.1", 4400, onConnectionSetup);
            _protocol = new ClientProtocol(client);
            _universe = new game.Universe();
        }
Exemplo n.º 2
0
        public ClientProtocol(Client client)
        {
            _client = client;

            _settings = new DebugSettings();
            _guiUpdateHandler = new UpdateHandler(_settings.guiUpdateRate);
            _stateUpdateHandler = new UpdateHandler(_settings.stateUpdateRate);

            _windows = null;

            _background = new Task(_requestGui);
        }
Exemplo n.º 3
0
Arquivo: Main.cs Projeto: sopindm/bjeb
        public static void Main(string[] args)
        {
            Client client = new Client("127.0.0.1", 4400);
            TestPlugin plugin = new TestPlugin(client);

            client.onSetup = plugin.setup;

            while (true)
            {
                plugin.update();

                if(!client.connected)
                {
                    Console.WriteLine("No connection");
                    System.Threading.Thread.Sleep(1000);
                }
            }
        }
Exemplo n.º 4
0
Arquivo: Main.cs Projeto: sopindm/bjeb
 public TestPlugin(Client client)
 {
     _protocol = new ClientProtocol(client);
     universe = new Universe();
 }