GH-2000 translate 'required' from Flame pack manifests to '.disabled'

This commit is contained in:
Petr Mrázek 2017-09-25 08:06:23 +02:00
parent b5b16d0972
commit c82042dcfa

View File

@ -297,7 +297,12 @@ void InstanceImportTask::processFlame()
m_filesNetJob.reset(new NetJob(tr("Mod download")));
for(auto result: results.files)
{
auto path = FS::PathCombine(m_stagingPath ,"minecraft", result.targetFolder, result.fileName);
QString filename = result.fileName;
if(!result.required)
{
filename += ".disabled";
}
auto path = FS::PathCombine(m_stagingPath ,"minecraft", result.targetFolder, filename);
auto dl = Net::Download::makeFile(result.url, path);
m_filesNetJob->addNetAction(dl);
}