From 3bf4130e3fc05f84cf7be7e33656f3e29f0fe12c Mon Sep 17 00:00:00 2001 From: madmaxoft Date: Sun, 28 Jul 2013 22:55:09 +0200 Subject: Player eating is now properly broadcast to other players. Also fixed the API relating to food, determining player gamemode, and removed several unneeded API functions. --- source/ClientHandle.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/ClientHandle.cpp') diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp index a15facc6e..d66e47d32 100644 --- a/source/ClientHandle.cpp +++ b/source/ClientHandle.cpp @@ -801,6 +801,11 @@ void cClientHandle::HandleRightClick(int a_BlockX, int a_BlockY, int a_BlockZ, c } else if (ItemHandler->IsFood()) { + if (m_Player->IsSatiated()) + { + // The player is satiated, they cannot eat + return; + } m_Player->StartEating(); if (PlgMgr->CallHookPlayerEating(*m_Player)) { -- cgit v1.2.3