From deeb3a15dc8914a3514685e8f79f543b00b2b908 Mon Sep 17 00:00:00 2001 From: madmaxoft Date: Sun, 11 Aug 2013 12:12:20 +0200 Subject: Added OnPlayerAnimation() hook. Initial patch by @STR_Warrior, updated to account for different animation packets. --- source/ClientHandle.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source/ClientHandle.cpp') diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp index 7605f5251..102153de1 100644 --- a/source/ClientHandle.cpp +++ b/source/ClientHandle.cpp @@ -997,6 +997,12 @@ void cClientHandle::HandlePlayerMoveLook(double a_PosX, double a_PosY, double a_ void cClientHandle::HandleAnimation(char a_Animation) { + if (cPluginManager::Get()->CallHookPlayerAnimation(*m_Player, a_Animation)) + { + // Plugin disagrees, bail out + return; + } + m_Player->GetWorld()->BroadcastPlayerAnimation(*m_Player, a_Animation, this); } -- cgit v1.2.3