Skip to content

Commit

Permalink
water movement fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
baguchi committed Nov 19, 2023
1 parent 0c08207 commit a6f1bda
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import baguchan.better_with_aquatic.api.ISwiming;
import net.minecraft.client.input.KeyboardInput;
import net.minecraft.client.option.GameSettings;
import net.minecraft.core.block.material.Material;
import net.minecraft.core.entity.player.EntityPlayer;
import org.spongepowered.asm.mixin.Final;
import org.spongepowered.asm.mixin.Mixin;
Expand All @@ -28,7 +29,7 @@ public class KeyboardInputMixin {
public void tick(EntityPlayer entityplayer, CallbackInfo ci) {

if (entityplayer instanceof ISwiming) {
if (entityplayer.isInWater() && !entityplayer.isSneaking()) {
if (entityplayer.isUnderLiquid(Material.water) && !entityplayer.isSneaking()) {
if (keys[0]) {
if (this.sprintTime < 9 && !this.pressedSprint) {
if (BetterWithAquatic.isEnableSwim()) {
Expand Down

0 comments on commit a6f1bda

Please sign in to comment.