Hostile mobs not removed on teleport #818
Labels
Status: Done
This issue has been completed or answered. This pull request has been merged.
Type: Bug
Milestone
Description
Describe the bug
Hostile mobs are not always removed on teleporting
Steps to reproduce the behavior
Set the remove hostile mobs flag to true.
Go through a portal to the nether and mobs will not be removed around the player.
Expected behavior
Hostile mobs should be removed when teleporting if the flag is true.
Additional context
This is caused by the destination chunks not being loaded. Therefore, when a scan is done for entities in the area, none are detected because the chunks are unloaded. The fix is to do the scan 1 tick after teleporting and then clear the area.
The reason it works sometimes in the overworld is because the islands can be in an area where the chunks are always loaded, like near spawn.
The text was updated successfully, but these errors were encountered: