Mojira Archive
MC-257528

Horses don't trigger "player_interacted_with_entity" advancement criteria

When coding a datapack with the advancement "player_interacted_with_entity" trigger, the advancement doesn't trigger if the horse has a passenger but still allows you to right click (interact) with it.

The advancement:

{
  "criteria": {
    "requirement": {
      "trigger": "minecraft:player_interacted_with_entity",
      "conditions": {
        "entity": [
          {
            "condition": "minecraft:entity_properties",
            "entity": "this",
            "predicate": {
              "type": "minecraft:horse",
              "passenger":
{                 "type": "minecraft:marker"               }
            }
          }
        ]
      }
    }
  },
  "rewards": {
    "function": "placeholder:placeholder"
  }
}

This also applies to the skeleton horse, zombie horse, llama, trader llama, donkey, mule, and boats.

 

Edit: Run the command 
/summon horse ~ ~ ~ {Passengers:[

{id:"minecraft:marker"}

],ArmorItem:{}} to summon the horse that fit's the advancement's criteria.

Unresolved

ISamAtlas

2022-11-13, 08:13 AM

2023-03-28, 07:24 AM

2

3

Community Consensus

Low

Platform

Advancements, Data Packs

advancement-trigger, datapack, horse

1.19.2, 22w45a, 1.19.3, 23w05a

-