public async Task <Process> LaunchGame(GameLaunchMode launchMode, bool joinServer = false) { if (!_settingsProvider.GetCurrentSettings().AcceptedEula) { return(null); } if (IsLaunching) { return(null); } IsLaunching = true; if (!joinServer) { SetJoinServerAddress(null); } _logger.Write($"Launching game. ({launchMode})"); _notificationService.ShowNotification("Launching game...", Notification.ShortMessageDelay); _splashScreenProgressProvider.SetCurrentStep(SplashScreenProgressStep.Initializing); var gameProcess = launchMode == GameLaunchMode.Multiplayer ? await ExecuteGrandTheftMultiplayerLaunchSteps() : await ExecuteGtaLaunchSteps(); IsLaunching = false; return(gameProcess); }
public LaunchGameMessage(GameLaunchMode launchMode, string joinServerIp, int joinServerPort) : base(nameof(LaunchGameMessage)) { LaunchMode = launchMode; JoinServerIp = joinServerIp; JoinServerPort = joinServerPort; JoinServer = true; }
public LaunchGameMessage(GameLaunchMode launchMode) : base(nameof(LaunchGameMessage)) { LaunchMode = launchMode; }