Skip to content

Commit

Permalink
Fix Jesus preventing players from using a boat (#4277)
Browse files Browse the repository at this point in the history
  • Loading branch information
crazycat256 authored Dec 31, 2023
1 parent d22bc73 commit 1d56555
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.enchantment.ProtectionEnchantment;
import net.minecraft.entity.EntityType;
import net.minecraft.entity.effect.StatusEffects;
import net.minecraft.fluid.Fluids;
import net.minecraft.network.packet.Packet;
Expand Down Expand Up @@ -270,8 +271,15 @@ private void onSendPacket(PacketEvent.Send event) {
private boolean waterShouldBeSolid() {
if (EntityUtils.getGameMode(mc.player) == GameMode.SPECTATOR || mc.player.getAbilities().flying) return false;


if (mc.player.getVehicle() != null) {
EntityType<?> vehicle = mc.player.getVehicle().getType();
if (vehicle == EntityType.BOAT || vehicle == EntityType.CHEST_BOAT) return false;
}

if (Modules.get().get(Flight.class).isActive()) return false;


if (dipIfBurning.get() && mc.player.isOnFire()) return false;

if (dipOnSneakWater.get() && mc.options.sneakKey.isPressed()) return false;
Expand Down

1 comment on commit 1d56555

@RealmKebab
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jesus himself?!?

Please sign in to comment.