Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-124820

Boats inside non full level water raise / sink with NoGravity set

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • Minecraft 1.12.2, 20w07a, 20w51a, 21w03a, 1.16.5, 21w05b, 21w06a, 21w08b, 1.17, 1.17.1, 1.18 Pre-release 5, 1.18.2, 22w16b, 1.19, 1.19.2, 1.19.3, 1.20.1, 24w35a
    • Confirmed
    • Commands, Entities

      The bug

      Boats inside non full level water (see MC-124819) sink even if NoGravity is set to 1b.

      How to reproduce

      1. Create a straight waterfall
      2. Summon a boat with NoGravity:1b
        /summon boat ~ ~ ~ {NoGravity:1b}
        
      3. Push or steer the boat into the water
        It floats or sinks

      Code analysis

      Based on 1.12.2 decompiled using MCP 9.40

      It looks like the reason could be that when a boat has the status EntityBoat.Status.UNDER_FLOWING_WATER, the method net.minecraft.entity.item.EntityBoat.updateMotion() modifies d1 which is added to the y-motion instead of modifying d2.

        1. MC-124820.mp4
          6.72 MB
          [Mod] Avoma
        2. MC-124820.png
          1.64 MB
          [Mod] Avoma
        3. Rise.png
          1.05 MB
          Aaron Rhodes

            Unassigned Unassigned
            marcono1234 Marcono1234
            Votes:
            7 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              CHK: