Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add simple mod list generation #459

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ModAssistant/Localisation/de.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installiere Playlist: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Titel fehlgeschlagen: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} Fehler] Playlist Installation abgeschlossen: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Zeige OneClick Installations-Fenster</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Ja</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Schließen</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/en-DEBUG.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@
<sys:String x:Key="Options:InstallingPlaylist">{0} Options:InstallingPlaylist</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">{0} Options:FailedPlaylistSong</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">{0} {1} Options:FinishedPlaylist</sys:String>
<sys:String x:Key="Options:GenerateModList">Options:GenerateModList</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Options:ShowOCIWindow</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Options:OCIWindowYes</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Options:OCIWindowClose</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/en.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installing Playlist: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Failed song: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} fails] Finished Installing Playlist: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Show OneClick Installer Window</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Yes</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Close</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/es.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Instalar lista de reproducción: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Canción fallida: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} fails] Se terminó de instalar la lista de reproducción: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Mostar la ventana del instalador OneClick</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Sí</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Cerrar</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/fr.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installation de la playlist : {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Échec de la musique : {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} échecs] Installation de la playlist terminée : {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Afficher la fenêtre de l'installateur OneClick</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Oui</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Fermer</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/it.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installazione Playlist: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Installazione canzone fallita: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} fails] Installazione playlist terminata: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Mostra finestra di installazione OneClick</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Si</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Chiudi</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/ja.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@
<sys:String x:Key="Options:InstallingPlaylist">プレイリストをインストール中: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">曲のインストールに失敗: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} 失敗] プレイリストのインストールが完了しました: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">OneClick インストーラウィンドウを表示</sys:String>
<sys:String x:Key="Options:OCIWindowYes">はい</sys:String>
<sys:String x:Key="Options:OCIWindowClose">閉じる</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/ko.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@
<sys:String x:Key="Options:InstallingPlaylist">재생목록 설치 중 : {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">실패한 노래: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} 실패] 재생목록 설치 완료: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">OneClick™ 설치 윈도우 보기</sys:String>
<sys:String x:Key="Options:OCIWindowYes">예</sys:String>
<sys:String x:Key="Options:OCIWindowClose">닫기</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/nb.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installerer spillelisten: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Mislykket låt: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} feil] Ferdig med å installere spillelister: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Vis OneClick installasjonsvindu</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Ja</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Lukk</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/nl.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Afspeellijst installeren: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Mislukt nummer: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} mislukkingen] Afspeellijst geïnstalleerd: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Toon OneClick Installatie Scherm</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Ja</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Sluit</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/pl.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Instalowanie playlisty: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Błąd piosenki: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} błędów] Zakończono instalację playlisty: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Pokaż okno instalatora OneClick</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Tak</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Zamknij</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/ru.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Установка плейлиста: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Ошибка с песней: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} ошибок] Установка плейлиста окончена: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Показать окно установок OneClick™</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Да</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Закрывать</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/sv.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">Installerar spellista: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">Misslyckad låt: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} fails] Färdig med installation av spellistor: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">Visa OneClick-installationsfönstret</sys:String>
<sys:String x:Key="Options:OCIWindowYes">Ja</sys:String>
<sys:String x:Key="Options:OCIWindowClose">Stäng</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/th.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@
<sys:String x:Key="Options:InstallingPlaylist">กำลังติดตั้งเพลย์ลิสต์: {0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">เพลงล้มเหลว: {0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0} ล้มเหลว] การติดตั้งเพลย์ลิสต์เสร็จสิ้น: {1}</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">แสดงหน้าต้าง OneClick Installer</sys:String>
<sys:String x:Key="Options:OCIWindowYes">ใช่</sys:String>
<sys:String x:Key="Options:OCIWindowClose">ปิด</sys:String>
Expand Down
1 change: 1 addition & 0 deletions ModAssistant/Localisation/zh.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@
<sys:String x:Key="Options:InstallingPlaylist">正在添加歌单:{0}</sys:String>
<sys:String x:Key="Options:FailedPlaylistSong">失败歌曲:{0}</sys:String>
<sys:String x:Key="Options:FinishedPlaylist">[{0}失败]添加{1}完成</sys:String>
<sys:String x:Key="Options:GenerateModList">Generate Mod List</sys:String>
<sys:String x:Key="Options:ShowOCIWindow">OneClick窗口显示方式:</sys:String>
<sys:String x:Key="Options:OCIWindowYes">显示</sys:String>
<sys:String x:Key="Options:OCIWindowClose">完成后关闭</sys:String>
Expand Down
12 changes: 10 additions & 2 deletions ModAssistant/Pages/Options.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,11 @@
Title="{DynamicResource Options:Title}"
d:DesignHeight="629"
d:DesignWidth="1182"
mc:Ignorable="d">
<Page.Resources />
mc:Ignorable="d"
xmlns:System="clr-namespace:System;assembly=mscorlib">
<Page.Resources>
<System:String x:Key="GenerateModList">Install Playlist</System:String>
</Page.Resources>
<ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto">
<Grid HorizontalAlignment="Center" VerticalAlignment="Center">
<Grid.RowDefinitions>
Expand Down Expand Up @@ -329,6 +332,11 @@
Padding="5"
Click="InstallPlaylistButton_Click"
Content="{DynamicResource Options:InstallPlaylist}" />
<Button
Height="30"
Padding="5"
Click="GenerateModList_Click"
Content="{DynamicResource Options:GenerateModList}" />
</StackPanel>

<TextBlock
Expand Down
13 changes: 13 additions & 0 deletions ModAssistant/Pages/Options.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,19 @@ private void InstallPlaylistButton_Click(object sender, RoutedEventArgs e)
}
}

private void GenerateModList_Click(object sender, RoutedEventArgs e)
{
string[] modPath = System.IO.Directory.GetFiles(InstallDirectory + @"\Plugins", "*.dll");
string[] modNames = new string[modPath.Length];

for (int i = 0; i < modPath.Length; i++)
{
modNames[i] = Path.GetFileName(modPath[i].ToString());
}
System.IO.File.WriteAllLines(InstallDirectory + @"\user_mod_list.txt", modNames);
Process.Start("Explorer.exe", "/select," + InstallDirectory + @"\user_mod_list.txt");
}

private void ShowOCIWindowComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
ComboBox comboBox = sender as ComboBox;
Expand Down