From bac750b24e673358ec55d3bf71c118a749fe5d0c Mon Sep 17 00:00:00 2001 From: daniel0916 Date: Sat, 25 Jan 2014 11:25:22 +0100 Subject: Added "player destroying" and "player destroyed" hooks Hooks: HOOK_PLAYER_DESTROYING HOOK_PLAYER_DESTROYED Idea from: https://github.com/mc-server/MCServer/issues/473 --- src/Bindings/PluginManager.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/Bindings/PluginManager.h') diff --git a/src/Bindings/PluginManager.h b/src/Bindings/PluginManager.h index 9936f5a35..38d5a8ca3 100644 --- a/src/Bindings/PluginManager.h +++ b/src/Bindings/PluginManager.h @@ -79,6 +79,8 @@ public: // tolua_export HOOK_LOGIN, HOOK_PLAYER_BREAKING_BLOCK, HOOK_PLAYER_BROKEN_BLOCK, + HOOK_PLAYER_DESTROYING, + HOOK_PLAYER_DESTROYED, HOOK_PLAYER_EATING, HOOK_PLAYER_FISHED, HOOK_PLAYER_FISHING, @@ -170,6 +172,8 @@ public: // tolua_export bool CallHookPlayerAnimation (cPlayer & a_Player, int a_Animation); bool CallHookPlayerBreakingBlock (cPlayer & a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta); bool CallHookPlayerBrokenBlock (cPlayer & a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta); + bool CallHookPlayerDestroying (cPlayer & a_Player); + bool CallHookPlayerDestroyed (cPlayer & a_Player); bool CallHookPlayerEating (cPlayer & a_Player); bool CallHookPlayerFished (cPlayer & a_Player, const cItems a_Reward); bool CallHookPlayerFishing (cPlayer & a_Player, cItems a_Reward); -- cgit v1.2.3 From dbbd47b96d3b3dd5ca0680eda8191808f30e3927 Mon Sep 17 00:00:00 2001 From: daniel0916 Date: Sat, 1 Feb 2014 13:27:44 +0100 Subject: Removed "player destroying" hook --- src/Bindings/PluginManager.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/Bindings/PluginManager.h') diff --git a/src/Bindings/PluginManager.h b/src/Bindings/PluginManager.h index 38d5a8ca3..a700ef6ce 100644 --- a/src/Bindings/PluginManager.h +++ b/src/Bindings/PluginManager.h @@ -79,7 +79,6 @@ public: // tolua_export HOOK_LOGIN, HOOK_PLAYER_BREAKING_BLOCK, HOOK_PLAYER_BROKEN_BLOCK, - HOOK_PLAYER_DESTROYING, HOOK_PLAYER_DESTROYED, HOOK_PLAYER_EATING, HOOK_PLAYER_FISHED, @@ -172,7 +171,6 @@ public: // tolua_export bool CallHookPlayerAnimation (cPlayer & a_Player, int a_Animation); bool CallHookPlayerBreakingBlock (cPlayer & a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta); bool CallHookPlayerBrokenBlock (cPlayer & a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta); - bool CallHookPlayerDestroying (cPlayer & a_Player); bool CallHookPlayerDestroyed (cPlayer & a_Player); bool CallHookPlayerEating (cPlayer & a_Player); bool CallHookPlayerFished (cPlayer & a_Player, const cItems a_Reward); -- cgit v1.2.3