mirror of
https://github.com/UltimMC/Launcher.git
synced 2025-10-04 17:09:25 +00:00
NOISSUE refactor pack import (extraction and paths)
It now: * Doesn't extract until it knows the content format is good. * Extracts in a predictable location, not requiring to use a second path for the actual pack root.
This commit is contained in:
@@ -20,14 +20,6 @@ InstanceCreationTask::InstanceCreationTask(SettingsObjectPtr settings, BaseInsta
|
||||
void InstanceCreationTask::executeTask()
|
||||
{
|
||||
setStatus(tr("Creating instance from version %1").arg(m_version->name()));
|
||||
/*
|
||||
auto minecraftVersion = std::dynamic_pointer_cast<MinecraftVersion>(m_version);
|
||||
if(!minecraftVersion)
|
||||
{
|
||||
emitFailed(tr("The supplied version is not a Minecraft version."));
|
||||
return ;
|
||||
}
|
||||
*/
|
||||
|
||||
QString stagingPath = m_target->getStagedInstancePath();
|
||||
QDir rootDir(stagingPath);
|
||||
@@ -41,6 +33,6 @@ void InstanceCreationTask::executeTask()
|
||||
inst->setName(m_instName);
|
||||
inst->setIconKey(m_instIcon);
|
||||
inst->init();
|
||||
m_target->commitStagedInstance(stagingPath, stagingPath, m_instName, m_instGroup);
|
||||
m_target->commitStagedInstance(stagingPath, m_instName, m_instGroup);
|
||||
emitSucceeded();
|
||||
}
|
||||
|
Reference in New Issue
Block a user