summaryrefslogtreecommitdiffstats
path: root/src/Bindings/PluginManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Bindings/PluginManager.cpp')
-rw-r--r--src/Bindings/PluginManager.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/Bindings/PluginManager.cpp b/src/Bindings/PluginManager.cpp
index 987b6a7cf..13039f834 100644
--- a/src/Bindings/PluginManager.cpp
+++ b/src/Bindings/PluginManager.cpp
@@ -794,11 +794,11 @@ bool cPluginManager::CallHookPlayerLeftClick(cPlayer & a_Player, int a_BlockX, i
-bool cPluginManager::CallHookPlayerMoving(cPlayer & a_Player, const Vector3d & a_OldPosition, const Vector3d & a_NewPosition)
+bool cPluginManager::CallHookPlayerMoving(cPlayer & a_Player, const Vector3d & a_OldPosition, const Vector3d & a_NewPosition, bool a_PreviousIsOnGround)
{
return GenericCallHook(HOOK_PLAYER_MOVING, [&](cPlugin * a_Plugin)
{
- return a_Plugin->OnPlayerMoving(a_Player, a_OldPosition, a_NewPosition);
+ return a_Plugin->OnPlayerMoving(a_Player, a_OldPosition, a_NewPosition, a_PreviousIsOnGround);
}
);
}
@@ -846,6 +846,19 @@ bool cPluginManager::CallHookPlayerPlacingBlock(cPlayer & a_Player, const sSetBl
+bool cPluginManager::CallHookPlayerCrouched(cPlayer & a_Player)
+{
+ return GenericCallHook(HOOK_PLAYER_CROUCHED, [&](cPlugin * a_Plugin)
+ {
+ return a_Plugin->OnPlayerCrouched(a_Player);
+ }
+ );
+}
+
+
+
+
+
bool cPluginManager::CallHookPlayerRightClick(cPlayer & a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, int a_CursorX, int a_CursorY, int a_CursorZ)
{
return GenericCallHook(HOOK_PLAYER_RIGHT_CLICK, [&](cPlugin * a_Plugin)