1 mal:
/scoreboard objectives add damage minecraft.custom:minecraft.damage_taken
Im Repeat Comandsblock
execute as @a at @s if score @s damage matches 1.. run <befehl>
Im Chain comandblock auf conditional
execute as @a if score @s damage matches 1.. run scoreboard players set @s damage 0