summaryrefslogtreecommitdiffstats
path: root/MCServer
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-01-27 04:45:40 +0100
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-01-27 04:45:40 +0100
commit67048ee057d0db912b383601c0fd39412e77e836 (patch)
tree1350906976566c15adb392bdb1e4c09506e0f958 /MCServer
parentDebuggers: added some filtering to the API output, but still not good enough. (diff)
downloadcuberite-67048ee057d0db912b383601c0fd39412e77e836.tar
cuberite-67048ee057d0db912b383601c0fd39412e77e836.tar.gz
cuberite-67048ee057d0db912b383601c0fd39412e77e836.tar.bz2
cuberite-67048ee057d0db912b383601c0fd39412e77e836.tar.lz
cuberite-67048ee057d0db912b383601c0fd39412e77e836.tar.xz
cuberite-67048ee057d0db912b383601c0fd39412e77e836.tar.zst
cuberite-67048ee057d0db912b383601c0fd39412e77e836.zip
Diffstat (limited to 'MCServer')
-rw-r--r--MCServer/Plugins/HookNotify/HookNotify.lua12
1 files changed, 10 insertions, 2 deletions
diff --git a/MCServer/Plugins/HookNotify/HookNotify.lua b/MCServer/Plugins/HookNotify/HookNotify.lua
index 519d837fe..9bae91d3c 100644
--- a/MCServer/Plugins/HookNotify/HookNotify.lua
+++ b/MCServer/Plugins/HookNotify/HookNotify.lua
@@ -74,9 +74,17 @@ end
function OnBlockToPickups(...)
- LOG("************************");
LogHook("OnBlockToPickups", unpack(arg));
- LOG("========================");
+ local World, Digger, BlockX, BlockY, BlockZ, BlockType, BlockMeta, Pickups = unpack(arg);
+ if (Pickups ~= nil) then
+ local Name = "NULL";
+ if (Digger ~= nil) then
+ Name = Digger:GetName()
+ end
+ LOG("Got cItems from " .. Name .. ", trying to manipulate them.");
+ Pickups:Add(cItem:new(E_ITEM_DIAMOND_SHOVEL, 1));
+ LOG("Current size: " .. Pickups:Size());
+ end;
end;