From 86469a1031d0699017b244db5a747bf42f651cd9 Mon Sep 17 00:00:00 2001 From: Shoghi Cervantes Date: Wed, 12 Jun 2013 16:43:29 +0200 Subject: [PATCH] Fix --- src/Player.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Player.php b/src/Player.php index 16c5d3b6..e9119676 100644 --- a/src/Player.php +++ b/src/Player.php @@ -873,6 +873,9 @@ class Player{ if($p["counter"] > $this->receiveCount){ $this->receiveCount = $p["counter"]; }elseif($p["counter"] !== 0){ + if(($p["counter"] - $this->receiveCount) > 16){ + continue; + } switch($p["id"]){ case 0x01: case MC_PONG: @@ -883,8 +886,6 @@ class Player{ case MC_SET_HEALTH: continue; } - }elseif(($p["counter"] - $this->receiveCount) > 16){ - continue; } } $this->handleDataPacket($p["id"], $p);