Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Jesus prevents player from using a boat #4277

Merged
merged 2 commits into from
Dec 31, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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