mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-14 09:39:11 +00:00
feat(Core): CanAccountCreateCharacter hook (#13020)
This commit is contained in:
@@ -81,3 +81,18 @@ void ScriptMgr::OnFailedPasswordChange(uint32 accountId)
|
||||
script->OnFailedPasswordChange(accountId);
|
||||
});
|
||||
}
|
||||
|
||||
bool ScriptMgr::CanAccountCreateCharacter(std::shared_ptr<CharacterCreateInfo> createInfo, uint32 accountId)
|
||||
{
|
||||
auto ret = IsValidBoolScript<AccountScript>([&](AccountScript* script)
|
||||
{
|
||||
return !script->CanAccountCreateCharacter(createInfo, accountId);
|
||||
});
|
||||
|
||||
if (ret && *ret)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user