Fix some bugs that got uncovered while trying to get liteloader 1.7 to work

This commit is contained in:
Jan Dalheimer 2014-02-01 19:42:47 +01:00
parent 8637cce433
commit 866d7029af

View File

@ -483,8 +483,15 @@ struct VersionFile
static std::shared_ptr<OneSixLibrary> createLibrary(const Library &lib) static std::shared_ptr<OneSixLibrary> createLibrary(const Library &lib)
{ {
std::shared_ptr<OneSixLibrary> out(new OneSixLibrary(lib.name)); std::shared_ptr<OneSixLibrary> out(new OneSixLibrary(lib.name));
if (!lib.url.isEmpty())
{
out->setBaseUrl(lib.url); out->setBaseUrl(lib.url);
}
out->setHint(lib.hint); out->setHint(lib.hint);
if (!lib.absoluteUrl.isEmpty())
{
out->setAbsoluteUrl(lib.absoluteUrl);
}
out->setAbsoluteUrl(lib.absoluteUrl); out->setAbsoluteUrl(lib.absoluteUrl);
out->extract_excludes = lib.excludes; out->extract_excludes = lib.excludes;
for (auto native : lib.natives) for (auto native : lib.natives)
@ -725,6 +732,10 @@ bool OneSixVersionBuilder::build(const bool excludeCustom)
{ {
return false; return false;
} }
file.name = "custom.json";
file.filename = "custom.json";
file.fileId = "org.multimc.custom.json";
file.version = QString();
bool isError = false; bool isError = false;
file.applyTo(m_version, isError); file.applyTo(m_version, isError);
if (isError) if (isError)