aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorMy-Name-Is-Jeff <37018278+My-Name-Is-Jeff@users.noreply.github.com>2021-09-25 17:13:19 -0400
committerMy-Name-Is-Jeff <37018278+My-Name-Is-Jeff@users.noreply.github.com>2021-09-25 17:13:19 -0400
commita97207bfb26b2f00b8551c5984122c8c4a150601 (patch)
tree325764a17b19f4df2eba6eaf4f769c208bb977a9 /src/main
parent02f8dda075988e578c03e6a82d73d237c9eefa11 (diff)
downloadSkytilsMod-a97207bfb26b2f00b8551c5984122c8c4a150601.tar.gz
SkytilsMod-a97207bfb26b2f00b8551c5984122c8c4a150601.tar.bz2
SkytilsMod-a97207bfb26b2f00b8551c5984122c8c4a150601.zip
allow teleporting to blocks with liquid above them
Diffstat (limited to 'src/main')
-rw-r--r--src/main/kotlin/skytils/skytilsmod/features/impl/misc/ItemFeatures.kt6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/kotlin/skytils/skytilsmod/features/impl/misc/ItemFeatures.kt b/src/main/kotlin/skytils/skytilsmod/features/impl/misc/ItemFeatures.kt
index 12f05793..658e1ac6 100644
--- a/src/main/kotlin/skytils/skytilsmod/features/impl/misc/ItemFeatures.kt
+++ b/src/main/kotlin/skytils/skytilsmod/features/impl/misc/ItemFeatures.kt
@@ -568,14 +568,14 @@ class ItemFeatures {
return mc.theWorld.getBlockState(pos).block.material.isSolid && (1..2).all {
val newPos = pos.up(it)
val newBlock = mc.theWorld.getBlockState(newPos)
- if (sideHit === EnumFacing.UP && Utils.equalsOneOf(
+ if (sideHit === EnumFacing.UP && (Utils.equalsOneOf(
newBlock.block,
Blocks.fire,
Blocks.skull
- )
+ ) || newBlock.block is BlockLiquid)
) return@all false
if (sideHit !== EnumFacing.UP && newBlock.block is BlockSign) return@all false
- if (newBlock.block is BlockLadder || newBlock.block is BlockDoor || newBlock.block is BlockLiquid) return@all false
+ if (newBlock.block is BlockLadder || newBlock.block is BlockDoor) return@all false
return@all newBlock.block.isPassable(mc.theWorld, newPos)
}
}