diff options
author | Jamie Mansfield <jmansfield@cadixdev.org> | 2021-02-25 14:43:04 +0000 |
---|---|---|
committer | Jamie Mansfield <jmansfield@cadixdev.org> | 2021-02-25 14:43:04 +0000 |
commit | 9c69b0cddee5445e315a063761c1a4ae7dfbfacf (patch) | |
tree | 15f79e3e53a5a009738fbd8b2abbb5f74a73b544 /api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp | |
parent | 9d91cd496f6c43ae0098632fe1ba8bf29ac0ba4b (diff) | |
download | PrismLauncher-9c69b0cddee5445e315a063761c1a4ae7dfbfacf.tar.gz PrismLauncher-9c69b0cddee5445e315a063761c1a4ae7dfbfacf.tar.bz2 PrismLauncher-9c69b0cddee5445e315a063761c1a4ae7dfbfacf.zip |
NOISSUE Install jarmods for modpacks.ch
This patch will now install any jarmods from modpacks.ch packs,
searching the 'jarmods' directory to find them.
Diffstat (limited to 'api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp')
-rw-r--r-- | api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp b/api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp index bbf60912..59546b00 100644 --- a/api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp +++ b/api/logic/modplatform/modpacksch/FTBPackInstallTask.cpp @@ -156,6 +156,18 @@ void PackInstallTask::install() } } + // install any jar mods + QDir jarModsDir(FS::PathCombine(m_stagingPath, "minecraft", "jarmods")); + if (jarModsDir.exists()) { + QStringList jarMods; + + for (const auto& info : jarModsDir.entryInfoList(QDir::NoDotAndDotDot | QDir::Files)) { + jarMods.push_back(info.absoluteFilePath()); + } + + components->installJarMods(jarMods); + } + components->saveNow(); instance.setName(m_instName); |