The Bug:
Hitting a mob (which is by default passive; or which does not see you because you are invisible) in Creative mode and then switching into Survival mode causes the mob to attack you.
How To Reproduce:
Spawn any mob (preferably neutral - you also can use hostile mobs for this, but you must be invisible) that can attack you (e.g. an Enderman, Polar Bear or Zombified Piglin)
Hit the mob in creative mode
Quickly switch to survival mode (you cannot take longer than 4 seconds)
→ ❌ The mob begins to pursue the player
Linked issues
is duplicated by 1
relates to 1
Attachments
Comments 18
Thanks for creating the separate report, I have slightly changed the summary and description. I hope you are alright with that.
The more edits, the better. Thank you for the edits as that can help me with making the best bug reports possible.
This is actually related to my old bug report MC-159532 which was marked as WAI by slicedlime
I'm not sure if the resolution is accurate though. I don't think it's a desirable outcome that when you change from creative to survival the mob attacks you.
I tried this and I can confirm that there's a small delay of 5-6 seconds until it doesn't agro you.