add event 'onPlayerRequestMods', restructure modloading

now every player has their own list of allowed client mods, this can be modified by lua upon joining and is later used as a whitelist to ensure only those files can be sent to each client
This commit is contained in:
20dka
2022-11-14 00:10:36 +01:00
committed by Lion Kortlepel
parent 056827546e
commit 468a6b340e
10 changed files with 140 additions and 50 deletions

View File

@@ -55,6 +55,7 @@ constexpr std::string_view StrLogChat = "LogChat";
constexpr std::string_view StrSendErrors = "Misc.SendErrors";
constexpr std::string_view StrSendErrorsMessageEnabled = "Misc.SendErrorsShowMessage";
constexpr std::string_view StrHideUpdateMessages = "Misc.ImScaredOfUpdates";
constexpr std::string_view StrIncludeSubdirectories = "Misc.IncludeSubdirectories";
// HTTP
constexpr std::string_view StrHTTPServerEnabled = "HTTP.HTTPServerEnabled";
@@ -79,6 +80,9 @@ struct Version {
template <typename T>
using SparseArray = std::unordered_map<size_t, T>;
template <typename K, typename V>
using HashMap = std::unordered_map<K, V>;
using boost::variant;
using boost::container::flat_map;