mirror of
https://github.com/sp-tarkov/launcher.git
synced 2025-02-13 02:30:43 -05:00
first launch asks to copy live settings, locale updates
This commit is contained in:
parent
5a13abf403
commit
f8be6c52a3
@ -14,8 +14,6 @@ using Newtonsoft.Json;
|
|||||||
using System;
|
using System;
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Runtime.InteropServices;
|
|
||||||
using Microsoft.Win32;
|
|
||||||
|
|
||||||
namespace Aki.Launcher.Helpers
|
namespace Aki.Launcher.Helpers
|
||||||
{
|
{
|
||||||
|
@ -177,6 +177,7 @@ namespace Aki.Launcher.Helpers
|
|||||||
englishLocale.profile_mods = "Profile Mods";
|
englishLocale.profile_mods = "Profile Mods";
|
||||||
englishLocale.author = "Author";
|
englishLocale.author = "Author";
|
||||||
englishLocale.wipe_on_start = "Wipe profile on game start";
|
englishLocale.wipe_on_start = "Wipe profile on game start";
|
||||||
|
englishLocale.copy_live_settings_question = "Would you like to copy your live game settings to spt";
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
Directory.CreateDirectory(LocalizationProvider.DefaultLocaleFolderPath);
|
Directory.CreateDirectory(LocalizationProvider.DefaultLocaleFolderPath);
|
||||||
@ -1622,6 +1623,22 @@ namespace Aki.Launcher.Helpers
|
|||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region copy_live_settings_question
|
||||||
|
private string _copy_live_settings_question;
|
||||||
|
public string copy_live_settings_question
|
||||||
|
{
|
||||||
|
get => _copy_live_settings_question;
|
||||||
|
set
|
||||||
|
{
|
||||||
|
if (_copy_live_settings_question != value)
|
||||||
|
{
|
||||||
|
_copy_live_settings_question = value;
|
||||||
|
RaisePropertyChanged(nameof(copy_live_settings_question));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
public event PropertyChangedEventHandler PropertyChanged;
|
public event PropertyChangedEventHandler PropertyChanged;
|
||||||
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
||||||
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Wczytaj ustawienia EFT",
|
"load_live_settings": "Wczytaj ustawienia EFT",
|
||||||
"load_live_settings_succeeded": "Ustawienia gry skopiowane z EFT",
|
"load_live_settings_succeeded": "Ustawienia gry skopiowane z EFT",
|
||||||
"load_live_settings_failed": "Nie udało się skopiować ustawień EFT",
|
"load_live_settings_failed": "Nie udało się skopiować ustawień EFT",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Загрузить настройкий онлайн-версии",
|
"load_live_settings": "Загрузить настройкий онлайн-версии",
|
||||||
"load_live_settings_succeeded": "Настройки игры скопированы из онлайн-версии",
|
"load_live_settings_succeeded": "Настройки игры скопированы из онлайн-версии",
|
||||||
"load_live_settings_failed": "Не удалось скопировать настройки онлайн-версии",
|
"load_live_settings_failed": "Не удалось скопировать настройки онлайн-версии",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -86,5 +86,6 @@
|
|||||||
"load_live_settings": "Load Live Settings",
|
"load_live_settings": "Load Live Settings",
|
||||||
"load_live_settings_succeeded": "Game settings copied from live",
|
"load_live_settings_succeeded": "Game settings copied from live",
|
||||||
"load_live_settings_failed": "Failed to copy live settings",
|
"load_live_settings_failed": "Failed to copy live settings",
|
||||||
"wipe_on_start": "Wipe profile on game start"
|
"wipe_on_start": "Wipe profile on game start",
|
||||||
|
"copy_live_settings_question": "Would you like to copy your live game settings to spt"
|
||||||
}
|
}
|
@ -64,9 +64,31 @@ namespace Aki.Launcher.ViewModels
|
|||||||
{
|
{
|
||||||
this.WhenActivated((CompositeDisposable disposables) =>
|
this.WhenActivated((CompositeDisposable disposables) =>
|
||||||
{
|
{
|
||||||
Task.Run(() =>
|
Task.Run(async () =>
|
||||||
{
|
{
|
||||||
GameVersionCheck();
|
await GameVersionCheck();
|
||||||
|
|
||||||
|
await Dispatcher.UIThread.InvokeAsync(async () =>
|
||||||
|
{
|
||||||
|
if (LauncherSettingsProvider.Instance.FirstRun)
|
||||||
|
{
|
||||||
|
LauncherSettingsProvider.Instance.FirstRun = false;
|
||||||
|
|
||||||
|
LauncherSettingsProvider.Instance.SaveSettings();
|
||||||
|
|
||||||
|
var confirmCopySettings = await ShowDialog(new ConfirmationDialogViewModel(Host,
|
||||||
|
LocalizationProvider.Instance.copy_live_settings_question,
|
||||||
|
LocalizationProvider.Instance.yes,
|
||||||
|
LocalizationProvider.Instance.no));
|
||||||
|
|
||||||
|
if (confirmCopySettings != null && confirmCopySettings is bool confirmed && confirmed)
|
||||||
|
{
|
||||||
|
var settingsVM = new SettingsViewModel(Host);
|
||||||
|
|
||||||
|
await settingsVM.ResetGameSettingsCommand();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user