public GameController(IGameDataService gameDataService, IPlayerRepository playerRepository, IGameHub gameHub, IGameService gameService) { this._gameDataService = gameDataService; this._playerRepository = playerRepository; this._gameHub = gameHub; this._gameService = gameService; }
public ChoosePresidentGameState(IChoiceRoundRepository choiceRoundRepository, IChoiceRepository choiceRepository, IGameDataService gameDataService, IGameHub gameHub) { this._choiceRoundRepository = choiceRoundRepository; this._choiceRepository = choiceRepository; this._gameDataService = gameDataService; this._gameHub = gameHub; }
public GameService(IPolicyRepository policyRepository, IPlayerRepository playerRepository, IGameDataService gameDataService, IGameHub gameHub) { this._policyRepository = policyRepository; this._playerRepository = playerRepository; this._gameDataService = gameDataService; this._gameHub = gameHub; }
void Init() { IdPlayer = -1; isJoin = false; isGameOver = false; panel.SetActive(true); var channel = new Channel(ipServer + ":12345", ChannelCredentials.Insecure); _gameHub = StreamingHubClient.Connect <IGameHub, IGameHubReceiver>(channel, this); JoinOrLeave(); InitBoard(); }
public async Task AddGameHandler(IGameHub gameHub) { lock (this.hubs) { if (gameHub != null) { this.hubs.Add(gameHub); } } await this.StartGameLoop(); }
public async Task RemoveGameHandler(IGameHub gameHub) { lock (this.hubs) { if (gameHub == null) { throw new ArgumentNullException("gameHub"); } this.hubs.Remove(gameHub); } if (this.hubs.Count == 0) { await this.Stop(); } }
public void ConnectChannel() { string target = $"{host.text}:{port.text}"; Debug.Log("接続先 " + target); channel = new Channel(target, ChannelCredentials.Insecure); try { gameHub = StreamingHubClient.Connect <IGameHub, IGameHubReceiver>(this.channel, this); JoinSelf(); } catch (System.Exception e) { Debug.Log("サーバーに接続できませんでした。"); Debug.LogError(e); } }
void IHubClient.ConnectHub(Channel channel) { _streamingHub = StreamingHubClient.Connect <IGameHub, IGameHubReceiver>(channel, _receiver); }
public MainWindow(IGameHub vm) { DataContext = vm; InitializeComponent(); }
public GamesController(IGameService gameService, IGameHub gameHub, IPlayerService playerService) { _gameService = gameService; _gameHub = gameHub; _playerService = playerService; }
public GameController(IGameHub gameHub, IGameService gameSvc) { _gameHub = gameHub; _gameSvc = gameSvc; }