## Ender Dragon flies down in the void when the exit portal is destroyed

XMLWordPrintable
• Bug
• Resolution: Unresolved
• None
• Minecraft 15w37a, Minecraft 15w42a, Minecraft 15w44a, Minecraft 15w46a, Minecraft 1.9.1, Minecraft 1.9.2, Minecraft 16w14a, Minecraft 1.9.3 Pre-Release 3, Minecraft 18w02a, Minecraft 1.13.1, Minecraft 1.13.2-pre1, Minecraft 1.13.2-pre2, Minecraft 1.13.2, Minecraft 18w43b, Minecraft 18w43c, Minecraft 18w44a, Minecraft 18w45a, Minecraft 18w47a, Minecraft 18w47b, Minecraft 19w04b, Minecraft 19w05a, Minecraft 19w06a, Minecraft 19w07a, Minecraft 19w11b, Minecraft 19w12b, Minecraft 1.14, Minecraft 1.14.3, Minecraft 1.14.4 Pre-Release 5, 1.14.4, 19w41a, 1.15.1, 1.16.4 Release Candidate 1, 1.16.4, 20w49a, 20w51a, 21w03a, 21w05b, 21w06a, 21w07a, 21w11a, 1.17 Pre-release 1, 1.17, 1.18.2, 22w13a, 22w14a, 22w15a, 22w16b, 22w19a, 1.19 Pre-release 4, 1.19, 1.19.4, 23w13a, 1.20 Pre-release 1, 23w43b, 1.20.4, 24w12a, 1.20.5
• Mob behaviour
• Low
• Gameplay

### The bug

If the exit portal is removed and the ender dragon tries to perch, it will fly to y=0. Doesn't matter if it's a hole or not, it will go through blocks tho.

### How to reproduce

1. Enter the end.
```/execute in minecraft:the_end run tp @s 0 100 0
```
2. Remove the exit portal (make sure the enderdragon is alive).
```Stand on top of the exit portal and run:
/fill ~-10 ~ ~10 ~10 ~-60 ~-10 air
```

The ender dragon flies to y=0, if it wants to perch.

### Code analysis

Code analysis by TriWonder81 can be found in this comment.

1. MC-88371.png
1.83 MB
2. MC-88371.mp4
6.55 MB
3. 2022-04-18_14.52.34.png
1.22 MB
4. 2018-01-13_07.54.12.png
3.66 MB
5. 2015-09-10_17.05.14.png
428 kB
6. 2015-09-10_17.04.26.png
488 kB
Unassigned
iliketra1ns