From 2a63699dcce5af9740dd9f513847d63299e0b81b Mon Sep 17 00:00:00 2001 From: Shoghi Cervantes Pueyo Date: Sat, 26 Jan 2013 12:59:22 +0100 Subject: [PATCH] Updated Entity::touchingBlock() --- src/classes/world/Entity.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/classes/world/Entity.php b/src/classes/world/Entity.php index 9f65a51d..6700f4e8 100644 --- a/src/classes/world/Entity.php +++ b/src/classes/world/Entity.php @@ -287,7 +287,7 @@ class Entity extends stdClass{ public function touchingBlock($x, $y, $z, $radius = 0.9){ $block = new Vector3($x, $y, $z); $me = new Vector3($this->x - 0.5, $this->y, $this->z - 0.5); - if(($y == (((int) $this->y) - 1) or $y == ((int) $this->y)) and $block->maxPlainDistance($me) < $radius){ + if(($y == (((int) $this->y) - 1) or $y == ((int) $this->y) or $y == (((int) $this->y) + 1)) and $block->maxPlainDistance($me) < $radius){ return true; } return false;