feat(Core): CanAccountCreateCharacter hook (#13020)
This commit is contained in:
parent
f658c8ea0c
commit
7dc598f364
3 changed files with 25 additions and 0 deletions
|
|
@ -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;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue