aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornea <romangraef@gmail.com>2022-04-28 20:12:26 +0200
committernea <romangraef@gmail.com>2022-04-28 20:12:26 +0200
commitc9898c7cf17d837678b1309bf38d882bf6b25edf (patch)
tree626795da40e85fb0563ed2244a8d06953ab6a6f0
parent4d61cbacd766e5c0e1dfedc26963bc104f6fc67d (diff)
downloadNotEnoughUpdates-fix/lava-fishing.tar.gz
NotEnoughUpdates-fix/lava-fishing.tar.bz2
NotEnoughUpdates-fix/lava-fishing.zip
stupid dojo fuck upfix/lava-fishing
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/FishingHelper.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/FishingHelper.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/FishingHelper.java
index 8fbd1185..b88eca99 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/FishingHelper.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/FishingHelper.java
@@ -268,9 +268,13 @@ public class FishingHelper {
double dY = particleY - hook.posY;
double tolerance = 0.5F;
if (hook.worldObj != null) {
- IBlockState state = hook.worldObj.getBlockState(new BlockPos(particleX, particleY-1, particleZ));
- if (state != null && (state.getBlock() == Blocks.flowing_lava || state.getBlock() == Blocks.flowing_water))
- tolerance = 2.0F;
+ for (int i = -2; i < 2; i++) {
+ IBlockState state = hook.worldObj.getBlockState(new BlockPos(particleX, particleY + i, particleZ));
+ if (state != null && (state.getBlock() == Blocks.flowing_lava
+ || state.getBlock() == Blocks.flowing_water
+ || state.getBlock() == Blocks.lava))
+ tolerance = 2.0F;
+ }
}
if (Math.abs(dY) > tolerance) {
return HookPossibleRet.NOT_POSSIBLE;