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

Berry bushes don't grow if there is a block above them

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • 1.14.4, 19w36a, 1.15.1, 1.15.2, 1.16 Pre-release 5, 1.16, 1.16.2, 1.16.3, 20w49a, 20w51a, 21w03a, 1.16.5, 21w05b, 21w06a, 21w07a, 21w08b, 1.17 Release Candidate 2, 1.17, 1.17.1, 1.18.1, 1.18.2, 1.19, 1.19.2, 1.19.3, 23w05a, 1.19.4, 23w18a, 1.20.1
    • Confirmed
    • Block states
    • Low

    Description

      The bug

      Sweet berry bushes / sweet berries do not grow if they have a (solid?) block above them.

      To reproduce

      1. Plant a sweet berry bush
      2. Place a solid block above
      3. Run /gamerule randomTickSpeed 10000 or just wait a while
        The bush will not grow

      Code analysis

      TriWonder81 - The following is based on 1.17 Release Candidate 1 yarn mappings.
      This is caused by the following statement of net.minecraft.block.SweetBerryBushBlock in which the light level of the position directly above the block is checked. This is why only solid blocks stop the growth, as transparent blocks allow light through

      net.minecraft.block.SweetBerryBushBlock
      if (i < 3 && random.nextInt(5) == 0 && world.getBaseLightLevel(pos.up(), 0) >= 9) {
                  world.setBlockState(pos, (BlockState)state.with(AGE, i + 1), Block.NOTIFY_LISTENERS);
              }
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            violine1101 [Mod] violine1101
            Votes:
            9 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              CHK: