mirror of
https://github.com/EQEmu/Server.git
synced 2026-01-08 07:13:51 +00:00
[Quest API] Reload content flags globally when a content flag is set (#3564)
This commit is contained in:
parent
c47644ea46
commit
7122ac33b2
@ -2746,6 +2746,7 @@ bool Perl__IsContentFlagEnabled(std::string flag_name)
|
||||
void Perl__SetContentFlag(std::string flag_name, bool enabled)
|
||||
{
|
||||
content_service.SetContentFlag(flag_name, enabled);
|
||||
zone->ReloadContentFlags();
|
||||
}
|
||||
|
||||
Expedition* Perl__get_expedition()
|
||||
|
||||
@ -1812,6 +1812,7 @@ bool lua_is_content_flag_enabled(std::string content_flag){
|
||||
|
||||
void lua_set_content_flag(std::string flag_name, bool enabled){
|
||||
content_service.SetContentFlag(flag_name, enabled);
|
||||
zone->ReloadContentFlags();
|
||||
}
|
||||
|
||||
Lua_Expedition lua_get_expedition() {
|
||||
|
||||
@ -3136,3 +3136,13 @@ bool Zone::CompareDataBucket(uint8 bucket_comparison, const std::string& bucket_
|
||||
|
||||
return passes;
|
||||
}
|
||||
|
||||
void Zone::ReloadContentFlags()
|
||||
{
|
||||
auto pack = new ServerPacket(ServerOP_ReloadContentFlags, 0);
|
||||
if (pack) {
|
||||
worldserver.SendPacket(pack);
|
||||
}
|
||||
|
||||
safe_delete(pack);
|
||||
}
|
||||
|
||||
@ -395,6 +395,8 @@ public:
|
||||
|
||||
void SetIsHotzone(bool is_hotzone);
|
||||
|
||||
void ReloadContentFlags();
|
||||
|
||||
private:
|
||||
bool allow_mercs;
|
||||
bool can_bind;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user