diff options
-rw-r--r-- | source/ClientHandle.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp index f32b6bec7..36a84ad41 100644 --- a/source/ClientHandle.cpp +++ b/source/ClientHandle.cpp @@ -666,6 +666,16 @@ void cClientHandle::HandleBlockPlace(int a_BlockX, int a_BlockY, int a_BlockZ, c } else if (ItemHandler->IsPlaceable()) { + if (cRoot::Get()->GetPluginManager()->CallHookBlockPlace(m_Player, a_BlockX, a_BlockY, a_BlockZ, a_BlockFace, Equipped)) + { + if (a_BlockFace > -1) + { + AddDirection(a_BlockX, a_BlockY, a_BlockZ, a_BlockFace); + m_Player->GetWorld()->SendBlockTo(a_BlockX, a_BlockY, a_BlockZ, m_Player); + } + return; + } + if (a_BlockFace < 0) { // clicked in air @@ -737,16 +747,6 @@ void cClientHandle::HandleBlockPlace(int a_BlockX, int a_BlockY, int a_BlockZ, c } } } - - if (cRoot::Get()->GetPluginManager()->CallHookBlockPlace(m_Player, a_BlockX, a_BlockY, a_BlockZ, a_BlockFace, Equipped)) - { - if (a_BlockFace > -1) - { - AddDirection(a_BlockX, a_BlockY, a_BlockZ, a_BlockFace); - m_Player->GetWorld()->SendBlockTo(a_BlockX, a_BlockY, a_BlockZ, m_Player); - } - return; - } } |