mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-06-29 01:54:20 +03:00
refactor: abstract metadata handling and clarify names
This commit is contained in:
parent
092d2f8917
commit
fab4a7a602
11 changed files with 82 additions and 31 deletions
|
|
@ -1,7 +1,7 @@
|
|||
#include "ModFolderLoadTask.h"
|
||||
#include <QDebug>
|
||||
|
||||
#include "modplatform/packwiz/Packwiz.h"
|
||||
#include "minecraft/mod/MetadataHandler.h"
|
||||
|
||||
ModFolderLoadTask::ModFolderLoadTask(QDir& mods_dir, QDir& index_dir)
|
||||
: m_mods_dir(mods_dir), m_index_dir(index_dir), m_result(new Result())
|
||||
|
|
@ -17,7 +17,7 @@ void ModFolderLoadTask::run()
|
|||
continue;
|
||||
|
||||
entry.chop(5); // Remove .toml at the end
|
||||
Mod mod(m_mods_dir, Packwiz::getIndexForMod(m_index_dir, entry));
|
||||
Mod mod(m_mods_dir, Metadata::get(m_index_dir, entry));
|
||||
m_result->mods[mod.internal_id()] = mod;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue