Merge pull request #1658 from Trial97/neoforge_version
Added version check for neoforge filter
This commit is contained in:
commit
6150908025
@ -1018,8 +1018,7 @@ std::optional<ModPlatform::ModLoaderTypes> PackProfile::getSupportedModLoaders()
|
||||
// TODO: remove this or add version condition once Quilt drops official Fabric support
|
||||
if (loaders & ModPlatform::Quilt)
|
||||
loaders |= ModPlatform::Fabric;
|
||||
// TODO: remove this or add version condition once NeoForge drops official Forge support
|
||||
if (loaders & ModPlatform::NeoForge)
|
||||
if (getComponentVersion("net.minecraft") == "1.20.1" && (loaders & ModPlatform::NeoForge))
|
||||
loaders |= ModPlatform::Forge;
|
||||
return loaders;
|
||||
}
|
||||
|
@ -55,6 +55,8 @@ class VersionTest : public QObject {
|
||||
<< "2.2.0" << true << false;
|
||||
QTest::newRow("lessThan, two-digit") << "1.41"
|
||||
<< "1.42" << true << false;
|
||||
QTest::newRow("lessThan, snapshot") << "1.20.0-rc2"
|
||||
<< "1.20.1" << true << false;
|
||||
|
||||
QTest::newRow("greaterThan, explicit 1") << "1.2.1"
|
||||
<< "1.2.0" << false << false;
|
||||
@ -72,6 +74,8 @@ class VersionTest : public QObject {
|
||||
<< "1.2" << false << false;
|
||||
QTest::newRow("greaterThan, two-digit") << "1.42"
|
||||
<< "1.41" << false << false;
|
||||
QTest::newRow("greaterThan, snapshot") << "1.20.2-rc2"
|
||||
<< "1.20.1" << false << false;
|
||||
}
|
||||
|
||||
private slots:
|
||||
|
Loading…
Reference in New Issue
Block a user