Exemple #1
0
 public GlobalTeamManager(LocalIDManager IDSupplier, ConnectionManager cm, RedisServer rs, IPlayerLocator pl, IDatabaseManager dbm)
 {
     _teamIDSupplier    = IDSupplier;
     _connectionManager = cm;
     _redisServer       = rs;
     _playerLocator     = pl;
     _databaseManager   = dbm;
 }
Exemple #2
0
        public PlayerManager(IDatabaseManager databaseManager, ConnectionManager cm, RedisServer rs, LocalIDManager idm, ClientUpdateManager cum) : base(databaseManager)
        {
            _usernameToPlayer  = new ConcurrentDictionary <string, Player>();
            connectionToPlayer = new ConcurrentDictionary <NetConnection, Player>();

            _clientUpdateManager = cum;
            _connectionManager   = cm;
            _redisServer         = rs;
            _playerIDManager     = idm;

            _redisServer.Subscribe(MessageTypes.Redis_PlayerRemoveTeam, _teamRemove_Handler);
        }
        public GalaxyRegistrationManager(GalaxyManager gm, ShipManager sm, CollisionManager cm, LocalIDManager idm, PlayerManager pm, AccountManager am, CargoSynchronizer cargoSynchronizer, StructureManager structureManager)
        {
            _galaxyManager     = gm;
            _shipManager       = sm;
            _collisionManager  = cm;
            _galaxyIDManager   = idm;
            _playerManager     = pm;
            _accountManager    = am;
            _cargoSynchronizer = cargoSynchronizer;
            _structureManager  = structureManager;

            if (idm.IDType != IDTypes.GalaxyID)
            {
                throw new Exception("Error: " + idm.GetType().ToString() + " must be of type " + IDTypes.GalaxyID + " in " + this.GetType().ToString());
            }
        }