mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-16 10:49:10 +00:00
InGamePacketHandler: do not handle inbound ActorEvents that are not for self
This commit is contained in:
parent
ea9bff6a65
commit
c9e8598510
@ -149,6 +149,10 @@ class InGamePacketHandler extends PacketHandler{
|
||||
}
|
||||
|
||||
public function handleActorEvent(ActorEventPacket $packet) : bool{
|
||||
if($packet->entityRuntimeId !== $this->player->getId()){
|
||||
//TODO HACK: EATING_ITEM is sent back to the server when the server sends it for other players (1.14 bug, maybe earlier)
|
||||
return $packet->event === ActorEventPacket::EATING_ITEM;
|
||||
}
|
||||
$this->player->doCloseInventory();
|
||||
|
||||
switch($packet->event){
|
||||
|
Loading…
x
Reference in New Issue
Block a user