diff options
author | Sefa Eyeoglu <contact@scrumplex.net> | 2022-05-22 13:17:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-22 13:17:53 +0200 |
commit | 29ef1e2c4b46c762e79a2bbe9f4a5a0033bc92ca (patch) | |
tree | 68bb97277b95d5f23626577825ab803252558244 /launcher/modplatform/ModAPI.h | |
parent | fbe84f9e4799596a41802489085f6d9067cdd745 (diff) | |
parent | 36045a8b0aa5c99e8520a39e6cc372ab9b549668 (diff) | |
download | PrismLauncher-29ef1e2c4b46c762e79a2bbe9f4a5a0033bc92ca.tar.gz PrismLauncher-29ef1e2c4b46c762e79a2bbe9f4a5a0033bc92ca.tar.bz2 PrismLauncher-29ef1e2c4b46c762e79a2bbe9f4a5a0033bc92ca.zip |
Merge pull request #597 from Scrumplex/refactor-modloader-modapi
Diffstat (limited to 'launcher/modplatform/ModAPI.h')
-rw-r--r-- | launcher/modplatform/ModAPI.h | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/launcher/modplatform/ModAPI.h b/launcher/modplatform/ModAPI.h index 8e6cd45c..4230df0b 100644 --- a/launcher/modplatform/ModAPI.h +++ b/launcher/modplatform/ModAPI.h @@ -16,14 +16,21 @@ class ModAPI { public: virtual ~ModAPI() = default; - // https://docs.curseforge.com/?http#tocS_ModLoaderType - enum ModLoaderType { Unspecified = 0, Forge = 1, Cauldron = 2, LiteLoader = 3, Fabric = 4, Quilt = 5 }; + enum ModLoaderType { + Unspecified = 0, + Forge = 1 << 0, + Cauldron = 1 << 1, + LiteLoader = 1 << 2, + Fabric = 1 << 3, + Quilt = 1 << 4 + }; + Q_DECLARE_FLAGS(ModLoaderTypes, ModLoaderType) struct SearchArgs { int offset; QString search; QString sorting; - ModLoaderType mod_loader; + ModLoaderTypes loaders; std::list<Version> versions; }; @@ -33,7 +40,7 @@ class ModAPI { struct VersionSearchArgs { QString addonId; std::list<Version> mcVersions; - ModLoaderType loader; + ModLoaderTypes loaders; }; virtual void getVersions(CallerType* caller, VersionSearchArgs&& args) const = 0; |