aboutsummaryrefslogtreecommitdiff
path: root/launcher/minecraft/mod/DataPack.cpp
diff options
context:
space:
mode:
authorTrial97 <alexandru.tripon97@gmail.com>2023-08-05 18:21:09 +0300
committerTrial97 <alexandru.tripon97@gmail.com>2023-08-05 18:21:09 +0300
commit939a2d67ed75be714e9f3b1b918250d006b3860a (patch)
treec5700ba93652e26fc1f86235b1a278d90fd0ce91 /launcher/minecraft/mod/DataPack.cpp
parent6f7d901a1f5c02e0629e4bae9172c04bb81ce0d9 (diff)
parentae793f6cf11658c9abc5111e82d5ba7b3e6af127 (diff)
downloadPrismLauncher-939a2d67ed75be714e9f3b1b918250d006b3860a.tar.gz
PrismLauncher-939a2d67ed75be714e9f3b1b918250d006b3860a.tar.bz2
PrismLauncher-939a2d67ed75be714e9f3b1b918250d006b3860a.zip
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop12
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
Diffstat (limited to 'launcher/minecraft/mod/DataPack.cpp')
-rw-r--r--launcher/minecraft/mod/DataPack.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/launcher/minecraft/mod/DataPack.cpp b/launcher/minecraft/mod/DataPack.cpp
index ca75cd2a..7bf5a311 100644
--- a/launcher/minecraft/mod/DataPack.cpp
+++ b/launcher/minecraft/mod/DataPack.cpp
@@ -30,10 +30,10 @@
// Values taken from:
// https://minecraft.fandom.com/wiki/Tutorials/Creating_a_data_pack#%22pack_format%22
static const QMap<int, std::pair<Version, Version>> s_pack_format_versions = {
- { 4, { Version("1.13"), Version("1.14.4") } }, { 5, { Version("1.15"), Version("1.16.1") } },
- { 6, { Version("1.16.2"), Version("1.16.5") } }, { 7, { Version("1.17"), Version("1.17.1") } },
- { 8, { Version("1.18"), Version("1.18.1") } }, { 9, { Version("1.18.2"), Version("1.18.2") } },
- { 10, { Version("1.19"), Version("1.19.3") } }, { 11, { Version("23w03a"), Version("23w05a") } },
+ { 4, { Version("1.13"), Version("1.14.4") } }, { 5, { Version("1.15"), Version("1.16.1") } },
+ { 6, { Version("1.16.2"), Version("1.16.5") } }, { 7, { Version("1.17"), Version("1.17.1") } },
+ { 8, { Version("1.18"), Version("1.18.1") } }, { 9, { Version("1.18.2"), Version("1.18.2") } },
+ { 10, { Version("1.19"), Version("1.19.3") } }, { 11, { Version("23w03a"), Version("23w05a") } },
{ 12, { Version("1.19.4"), Version("1.19.4") } }, { 13, { Version("23w12a"), Version("23w14a") } },
{ 14, { Version("23w16a"), Version("23w17a") } }, { 15, { Version("1.20"), Version("1.20") } },
};
@@ -74,6 +74,7 @@ std::pair<int, bool> DataPack::compare(const Resource& other, SortType type) con
auto res = Resource::compare(other, type);
if (res.first != 0)
return res;
+ break;
}
case SortType::PACK_FORMAT: {
auto this_ver = packFormat();
@@ -83,6 +84,7 @@ std::pair<int, bool> DataPack::compare(const Resource& other, SortType type) con
return { 1, type == SortType::PACK_FORMAT };
if (this_ver < other_ver)
return { -1, type == SortType::PACK_FORMAT };
+ break;
}
}
return { 0, false };