Exemplo n.º 1
0
 public DotaGame(DotaGameState state, DotaGameConnection connection)
 {
     this.state = state;
     this.connection = connection;
     entityUpdater = new EntityUpdater(state);
     stringTableUpdater = new StringTableUpdater();
 }
Exemplo n.º 2
0
 /// <summary>
 ///     Init a new game connect session.
 /// </summary>
 /// <param name="deets"></param>
 /// <param name="toArray"></param>
 /// <param name="poolBuilder">Pool builder</param>
 internal DotaGameSession(DOTAConnectDetails deets, IDotaGameController[] controllers, DotaEntityPool.Builder poolBuilder)
 {
     _details = deets;
     Running = false;
     _gameState = new DotaGameState(deets);
     _gameState.EntityPool = poolBuilder.Build(_gameState);
     _connection = null;
     Controllers = controllers;
 }
Exemplo n.º 3
0
 /// <summary>
 ///     Initialize the signon handler.
 /// </summary>
 /// <param name="state"></param>
 /// <param name="connection"></param>
 public DotaSignon(DotaGameState state, DotaGameConnection connection, DOTAConnectDetails details)
 {
     this.state = state;
     this.details = details;
     this.connection = connection;
     entityUpdater = new EntityUpdater(state);
     sendTableFlattener = new SendTableFlattener();
     stringTableUpdater = new StringTableUpdater();
 }
Exemplo n.º 4
0
 public DotaHandshake(
     DOTAConnectDetails details,
     DotaGameState state,
     DotaGameConnection connection)
 {
     this.details = details;
     this.connection = connection;
     this.state = state;
     client_challenge = (uint) new Random().Next();
 }
Exemplo n.º 5
0
        public UserCmdGenerator(DotaGameState state, DotaGameConnection connection)
        {
            this.state = state;
            this.connection = connection;

            backup = new List<UserCmd>();
            next = new List<UserCmd>();

            commandNumber = 0;
            orderNumber = 0;
        }
Exemplo n.º 6
0
 public EntityUpdater(DotaGameState state)
 {
     this.state = state;
     unpacker = new PropertyValueUnpacker();
 }
Exemplo n.º 7
0
 /// <summary>
 /// Initialize the controller as the client begins to connect.
 /// </summary>
 /// <param name="id">Steam ID</param>
 /// <param name="state">Emulated DOTA game client state</param>
 /// <param name="commander">Command generator</param>
 public void Initialize(ulong id, DotaGameState state, IDotaGameCommander commander)
 {
     _steamId = id;
     _state = state;
     _commander = commander;
 }