I found that when executing the script
Player.getComponent('health').setCurrentValue(16); // Of course the value 16 can be changed to others below 20.
and the affected player has yellow hearts, the yellow hearts will disappear visually, but still exist in fact.
In the video, the first time the player got 4 damage, it appeared that nothing had happened, which confirms the yellow hearts were indeed functioning.
Thank you for your report!
However, this issue has been temporarily closed as Awaiting Response.
Could you please attach an example addon showcasing the issue?
This ticket will automatically reopen when you reply.
Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📧 Suggestions – 📖 Minecraft Wiki