mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
feat: add PLAYER_EVENT_ON_CAN_INIT_TRADE (#83)
This commit is contained in:
@@ -584,7 +584,6 @@ void Eluna::OnAchiComplete(Player* player, AchievementEntry const* achievement)
|
||||
CallAllFunctions(PlayerEventBindings, key);
|
||||
}
|
||||
|
||||
|
||||
void Eluna::OnFfaPvpStateUpdate(Player* player, bool hasFfaPvp)
|
||||
{
|
||||
START_HOOK(PLAYER_EVENT_ON_FFAPVP_CHANGE);
|
||||
@@ -592,3 +591,11 @@ void Eluna::OnFfaPvpStateUpdate(Player* player, bool hasFfaPvp)
|
||||
Push(hasFfaPvp);
|
||||
CallAllFunctions(PlayerEventBindings, key);
|
||||
}
|
||||
|
||||
bool Eluna::OnCanInitTrade(Player* player, Player* target)
|
||||
{
|
||||
START_HOOK_WITH_RETVAL(PLAYER_EVENT_ON_CAN_INIT_TRADE, true);
|
||||
Push(player);
|
||||
Push(target);
|
||||
return CallAllFunctionsBool(PlayerEventBindings, key);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user