From 523f13c430404d2f2910f6ecd0dca7595d9e969f Mon Sep 17 00:00:00 2001 From: RealIndrit <32206640+RealIndrit@users.noreply.github.com> Date: Tue, 18 Aug 2020 12:36:10 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A5=20Get=20yeeted=20unused=20code?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Removed an unused function that can't be used anyways, because RayTraceUtils cant detect entity hit... --- src/api/java/baritone/api/utils/IPlayerContext.java | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/api/java/baritone/api/utils/IPlayerContext.java b/src/api/java/baritone/api/utils/IPlayerContext.java index 8ce3271b..f746110e 100644 --- a/src/api/java/baritone/api/utils/IPlayerContext.java +++ b/src/api/java/baritone/api/utils/IPlayerContext.java @@ -97,17 +97,4 @@ public interface IPlayerContext { default boolean isLookingAt(BlockPos pos) { return getSelectedBlock().equals(Optional.of(pos)); } - - /** - * Returns the entity that the crosshair is currently placed over. Updated once per tick. - * - * @return The entity - */ - default Optional getSelectedEntity() { - RayTraceResult result = objectMouseOver(); - if (result != null && result.typeOfHit == RayTraceResult.Type.ENTITY) { - return Optional.of(result.entityHit); - } - return Optional.empty(); - } }