mirror of
https://github.com/Wurst-Imperium/Wurst7.git
synced 2024-09-20 09:16:20 +02:00
Fix AutoEatHack.isClickable() using the wrong HitResult
This commit is contained in:
parent
6d32c37d3c
commit
bb35648933
@ -189,14 +189,14 @@ public final class AutoEatHack extends Hack implements UpdateListener
|
|||||||
|
|
||||||
if(hitResult instanceof EntityHitResult)
|
if(hitResult instanceof EntityHitResult)
|
||||||
{
|
{
|
||||||
Entity entity = ((EntityHitResult)MC.crosshairTarget).getEntity();
|
Entity entity = ((EntityHitResult)hitResult).getEntity();
|
||||||
return entity instanceof VillagerEntity
|
return entity instanceof VillagerEntity
|
||||||
|| entity instanceof TameableEntity;
|
|| entity instanceof TameableEntity;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hitResult instanceof BlockHitResult)
|
if(hitResult instanceof BlockHitResult)
|
||||||
{
|
{
|
||||||
BlockPos pos = ((BlockHitResult)MC.crosshairTarget).getBlockPos();
|
BlockPos pos = ((BlockHitResult)hitResult).getBlockPos();
|
||||||
if(pos == null)
|
if(pos == null)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user