Mojira Archive
MC-272701

Mobs that can be ridden and are equipped with an elytra do not sustain damage when gliding against a wall while under player control

Let's first clarify what controlling an entity means. Utilizing

/execute on controller

enables the identification of the entity's controller. You are the controller of a mob under the following conditions:

  • For horses, donkeys, mules, zombie horses, skeleton horses, and camels, you become the controller if you ride it, the entity is tamed, and has a saddle.
  • For pigs, you become the controller if you ride it while it's saddled and hold a carrot on a stick.
  • For striders, you become the controller if you ride it while it's saddled and hold a warped fungus on a stick.

When you control these mobs, they are not affected by the damage type "minecraft:fly_into_wall." However, if they are not under your control, they will incur the expected damage from such collisions.

Steps to reproduce with horse

  1. Play in a flat world for easier reproduction
  2. /fill ~1 ~ ~ ~10 ~40 ~ minecraft:netherite_block
  3. Start flying in creative mode if you haven't already
  4. /tp ~5 ~30 ~30
  5. /summon horse ~ ~ ~ {FallFlying:1b,Tame:1b,Rotation:[180F,0F],ArmorItems:[{},{},{id:"minecraft:elytra",Count:1b},{}],SaddleItem:{id:"minecraft:saddle",Count:1b}}
  6. Mount the horse
  7. Control the horse to glide against the wall
  8. Notice that the horse does not take damage upon collision with the wall
  9. Go back to where you executed step 5
  10. /summon horse ~ ~ ~ {FallFlying:1b,Tame:1b,Rotation:[180F,0F],ArmorItems:[{},{},{id:"minecraft:elytra",Count:1b},{}]}
  11. Mount the horse
  12. Wait for the horse to glide against the wall

Observed behavior: When you control the horse with a saddle, it does not sustain damage upon colliding with a wall. Conversely, when not under your control, the horse incurs the expected damage from such collisions.
Expected behavior: Even when controlled by the player, the horse should be susceptible to damage when colliding with a wall.

Steps to reproduce with pig

  1. Play in a flat world for easier reproduction
  2. /fill ~1 ~ ~ ~10 ~40 ~ minecraft:netherite_block
  3. Start flying in creative mode if you haven't already
  4. /tp ~5 ~30 ~30
  5. /summon minecraft:pig ~ ~ ~ {Saddle:1b,FallFlying:1b,Rotation:[180F,0F],ArmorItems:[{},{},{id:"minecraft:elytra",Count:1b},{}]}
  6. Mount the pig
  7. Hold a carrot on a stick
  8. Control the pig to fly against the wall
  9. Notice that it doesn't take damage when colliding with the wall
  10. Go back to where you executed step 5
  11. Run the following command (same as step 5):
    /summon minecraft:pig ~ ~ ~ {Saddle:1b,FallFlying:1b,Rotation:[180F,0F],ArmorItems:[{},{},{id:"minecraft:elytra",Count:1b},{}]}
  12. Mount the pig
  13. Wait for the pig to fly against the wall and don't hold a carrot on a stick

Observed behavior: When controlled with a carrot on a stick, the pig does not incur damage upon colliding with a wall. However, when not controlled with a carrot on a stick, it does sustain the expected damage from such collisions.
Expected behavior: Even when controlled with a carrot on a stick, the pig should still take damage when colliding with a wall.

Unresolved

No User

The grandpa of minecraft

2024-05-30, 09:38 PM

2024-07-12, 07:13 AM

0

0

Plausible

Low

Platform

Items, Mob behaviour

1.20.6, 1.21 Pre-Release 1

-