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

Predicates no longer support unquoted booleans and numbers in blockstates

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Works As Intended
    • None
    • 23w32a
    • None
    • Confirmed
    • Data Packs
    • Important
    • Platform

      Steps to reproduce:

      • Download the first datapack, broken.zip, which contains a predicate with the following contents:
        {
          "condition": "minecraft:location_check",
          "predicate": {
            "block": {
              "blocks": [
                "minecraft:snow"
              ],
              "state": {
                "layers": 1
              }
            }
          }
        }
        
      • Note the unquoted 1 in the layers block state.
      • Install it into a world in 23w32a.
      • Note that the log errors on this file, noting that it is not a json array.
      • Download the second file, not_broken.zip, which contains the same file, with the 1 now quoted.
      • Replace the previous datapack
      • See the error has now disappeared
      • This is also the case for predicates containing unquoted booleans.
      • This error was not the case in previous versions, which supported unquoted booleans and numbers.

        1. not_broken.zip
          1.0 kB
        2. broken.zip
          1.0 kB

            Unassigned Unassigned
            CreeperMagnet_ CreeperMagnet_
            Votes:
            9 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: