Mojira Archive
MC-272689

Falling blocks can't harm players in creative mode if the associated damage type is included in the #minecraft:bypasses_invulnerability tag

The damage types minecraft:falling_anvil, minecraft:falling_block, and minecraft:falling_stalactite are employed by falling block entities for inflicting damage. By incorporating these damage types into the #minecraft:bypasses_invulnerability tag, falling blocks can inflict damage on entities bearing the Invulnerable NBT tag as anticipated. However, unlike other damage scenarios, this adjustment doesn't enable them to harm players in creative mode.

Steps to reproduce

  1. Install the attached datapack
  2. Be in creative mode
  3. /summon falling_block ~ ~5 ~ {BlockState:{Name:"minecraft:hay_block"},Time:1,HurtEntities:1b,FallHurtMax:999,FallHurtAmount:999f}
  4. /setblock ~ ~5 ~ minecraft:anvil
  5. /setblock ~ ~5 ~ minecraft:pointed_dripstone[vertical_direction=down]
  6. Note that the falling blocks didn't cause any damage while you were in creative mode
  7. /summon minecraft:husk ~ ~ ~ {Invulnerable:1b}
  8. /execute at @e[type=minecraft:husk,distance=..10] run summon falling_block ~ ~5 ~ {BlockState:{Name:"minecraft:hay_block"},Time:1,HurtEntities:1b,FallHurtMax:999,FallHurtAmount:999f}
  9. /summon minecraft:husk ~ ~ ~ {Invulnerable:1b}
  10. /execute at @e[type=minecraft:husk,distance=..10] run setblock ~ ~5 ~ minecraft:anvil
  11. /execute at @e[type=minecraft:husk,distance=..10] run setblock ~ ~5 ~ minecraft:pointed_dripstone[vertical_direction=down]

Observed behavior: While you were in creative mode, the falling blocks did not inflict any damage on you. However, they did cause damage to the invulnerable husk as anticipated.

Expected behavior:

  • As minecraft:falling_block is included in the #minecraft:bypasses_invulnerability tag, the hay bale should cause damage to you even in creative mode.
  • Given that minecraft:falling_anvil is within the #minecraft:bypasses_invulnerability tag, the anvil should inflict damage on you while in creative mode.
  • Because minecraft:falling_stalactite is listed in the #minecraft:bypasses_invulnerability tag, the pointed dripstone should cause damage to you even while in creative mode.

Invalid

No User

The grandpa of minecraft

2024-05-30, 09:37 PM

2024-06-21, 02:56 PM

2024-06-21, 02:56 PM

0

0

Unconfirmed

(Unassigned)

1.20.6, 1.21 Pre-Release 1

-