fix vanilla technic modpacks
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
(cherry picked from commit f4f0a61bf2
)
This commit is contained in:
parent
0a27d3859c
commit
e475f4ed36
@ -83,8 +83,10 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings,
|
|||||||
data = file.readAll();
|
data = file.readAll();
|
||||||
file.close();
|
file.close();
|
||||||
} else {
|
} else {
|
||||||
if (minecraftVersion.isEmpty())
|
if (minecraftVersion.isEmpty()) {
|
||||||
emit failed(tr("Could not find \"version.json\" inside \"bin/modpack.jar\", but Minecraft version is unknown"));
|
emit failed(tr("Could not find \"version.json\" inside \"bin/modpack.jar\", but Minecraft version is unknown"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
components->setComponentVersion("net.minecraft", minecraftVersion, true);
|
components->setComponentVersion("net.minecraft", minecraftVersion, true);
|
||||||
components->installJarMods({ modpackJar });
|
components->installJarMods({ modpackJar });
|
||||||
|
|
||||||
@ -131,7 +133,9 @@ void Technic::TechnicPackProcessor::run(SettingsObjectPtr globalSettings,
|
|||||||
file.close();
|
file.close();
|
||||||
} else {
|
} else {
|
||||||
// This is the "Vanilla" modpack, excluded by the search code
|
// This is the "Vanilla" modpack, excluded by the search code
|
||||||
emit failed(tr("Unable to find a \"version.json\"!"));
|
components->setComponentVersion("net.minecraft", minecraftVersion, true);
|
||||||
|
components->saveNow();
|
||||||
|
emit succeeded();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user