From 3374bbcc9ec7b2a61da27a8125d6664911ca53f9 Mon Sep 17 00:00:00 2001 From: Shoghi Cervantes Date: Tue, 20 Aug 2013 00:26:37 +0200 Subject: [PATCH] Chest animations for everyone! Woo! --- src/Player.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Player.php b/src/Player.php index 173591f29..ee5c632cc 100644 --- a/src/Player.php +++ b/src/Player.php @@ -1609,7 +1609,17 @@ class Player{ } $this->craftingItems = array(); $this->toCraft = array(); + if(isset($this->windows[$data["windowid"]]) and $this->windows[$data["windowid"]]->class === TILE_CHEST){ + $this->server->api->player->broadcastPacket($this->server->api->player->getAll($this->level), MC_TILE_EVENT, array( + "x" => $this->windows[$data["windowid"]]->x, + "y" => $this->windows[$data["windowid"]]->y, + "z" => $this->windows[$data["windowid"]]->z, + "case1" => 1, + "case2" => 0, + )); + } unset($this->windows[$data["windowid"]]); + $this->dataPacket(MC_CONTAINER_CLOSE, array( "windowid" => $data["windowid"], ));