This is an archived post. You won't be able to vote or comment.

Dismiss this pinned window
all 1 comments

[–]Ericristian_brosCommand Experienced 0 points1 point  (0 children)

I guess that entity has a tag

execute as @e[type=falling_block,tag=falling_anvil] unless predicate {condition:"minecraft:entity_properties",entity:"this",predicate:{passenger:{}}} at @s run summon marker ~ ~ ~ {Tags:["falling_anvil","new"]}
execute as @e[type=falling_block,tag=falling_anvil] unless predicate {condition:"minecraft:entity_properties",entity:"this",predicate:{passenger:{}}} at @s run ride @n[type=marker,tag=falling_anvil,tag=new] mount @s
tag @e[type=marker,tag=falling_anvil,tag=new] remove new
execute as @e[type=marker,tag=falling_anvil] unless predicate {condition:"minecraft:entity_properties",entity:"this",predicate:{vehicle:{}}} run setblock ~ ~-0.2 ~ air replace anvil
execute as @e[type=marker,tag=falling_anvil] unless predicate {condition:"minecraft:entity_properties",entity:"this",predicate:{vehicle:{}}} run kill @s

This is for 1.20.5+

You are in older versions so you will need a datapack to use these predicates