diff options
author | Mattes D <github@xoft.cz> | 2020-04-09 22:25:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-09 22:25:20 +0200 |
commit | bdedab15c94956cbc74045ab242fd300d25f39e7 (patch) | |
tree | 900c4e7f662388e29405ccf059fcab767bbd8046 /Server/Plugins/Debuggers/Debuggers.lua | |
parent | Wolves and mooshrooms are passive mobs (diff) | |
download | cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar.gz cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar.bz2 cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar.lz cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar.xz cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.tar.zst cuberite-bdedab15c94956cbc74045ab242fd300d25f39e7.zip |
Diffstat (limited to 'Server/Plugins/Debuggers/Debuggers.lua')
-rw-r--r-- | Server/Plugins/Debuggers/Debuggers.lua | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/Server/Plugins/Debuggers/Debuggers.lua b/Server/Plugins/Debuggers/Debuggers.lua index 7d12e130a..4cf825f12 100644 --- a/Server/Plugins/Debuggers/Debuggers.lua +++ b/Server/Plugins/Debuggers/Debuggers.lua @@ -1567,6 +1567,25 @@ end +function HandleCakeCmd(a_Split, a_Player) + local lookVector = a_Player:GetLookVector() + local pos = a_Player:GetEyePosition() + lookVector + local world = a_Player:GetWorld() + local speed = lookVector * 10 + local cakeID = world:SpawnFallingBlock(pos, E_BLOCK_CAKE, 0) + world:DoWithEntityByID(cakeID, + function(a_CBCake) + a_CBCake:SetSpeed(speed) + end + ) + a_Player:SendMessage("Your cake is served") + return true +end + + + + + function HandleClientVersionCmd(a_Split, a_Player) a_Player:SendMessage("Your client version number is " .. a_Player:GetClientHandle():GetProtocolVersion() ..".") return true |