Exemplo n.º 1
0
        private void StartMatchSearchButton_Click()
        {
            if (!PlayerIdStorage.TryGetServiceId(out string playerServiceId))
            {
                log.Error($"{nameof(StartMatchSearchButton_Click)} {nameof(playerServiceId)} is null");
                return;
            }


            if (playerServiceId == null)
            {
                throw new Exception($"{nameof(playerServiceId)} is null");
            }

            int currentWarshipId = lobbyEcsController.GetCurrentWarshipId();

            log.Info($"Данные для входа в бой: {nameof(playerServiceId)} {playerServiceId}," +
                     $" {nameof(currentWarshipId)} {currentWarshipId}");

            matchLoader.StartBattleLoading(playerServiceId, currentWarshipId);
            lobbyEcsController.Button_Start_Click();
        }