[MC-2930] Heart bar doesn't show how much damage is dealt to the player Created: 13/Nov/12  Updated: 05/May/15  Resolved: 31/Jul/14

Status: Resolved
Project: Minecraft: Java Edition
Component/s: None
Affects Version/s: Minecraft 1.4.2, Minecraft 1.4.4, Minecraft 1.4.7, Minecraft 1.5, Minecraft 1.6.2, Minecraft 1.6.4, Minecraft 13w36a, Minecraft 13w36b, Minecraft 13w37a, Minecraft 1.7.1, Minecraft 1.7.2, Minecraft 13w48a, Minecraft 13w48b, Minecraft 13w49a, Minecraft 1.7.3, Minecraft 1.7.4, Minecraft 14w08a, Minecraft 1.7.5, Minecraft 14w10b, Minecraft 14w10c, Minecraft 14w11b, Minecraft 1.7.9, Minecraft 14w20b, Minecraft 14w21a, Minecraft 14w21b, Minecraft 1.7.10, Minecraft 14w29a, Minecraft 14w29b
Fix Version/s: Minecraft 14w32a

Type: Bug
Reporter: Daniel Garcia Assignee: [Mojang] Nathan Adams
Resolution: Fixed Votes: 25
Labels: GUI
Environment:

Windows 7
Java 1.7.0_09


Attachments: PNG File 2012-11-13_16.28.27.png     PNG File 2012-11-13_17.03.36.png    
Issue Links:
Duplicate
is duplicated by MC-4539 Textures not loaded after 1.2.5 Resolved
CHK:
Confirmation Status: Confirmed
Game Mode: Survival

 Description   

In versions prior to the singleplayer/multiplayer merge (before 1.3), the heart bar would briefly flash faint hearts depending on how many of them were lost when taking damage. This is gone since version 1.3, with no mention in the change logs. Here's a video comparison of the health bar between 1.2.5 and 1.4.2.

What I expected to happen was...
Blinking faint bright hearts showing how much health I had before taking damage. If I had 10 hearts, and I took 2 hearts of damage, I'd expect those 2 hearts to blink briefly before dissapearing completely.

What actually happened was...
No sign of how much hearts were lost. The hearts completely dissappear just after taking any damage.

Note:
This is not about regeneration, which works as expected. User Vincent Lee has found a relevant part of the code related to the bug.

Steps to reproduce:
1. Load a world on survival mode.
2. Take damage from any source.
3. Observe the heart bar. It should flash the hearts that were lost, but it does not.



 Comments   
Comment by insomniac_lemon [ 08/Aug/14 ]

I can see why it was done that way, because you are still receiving damage, this allows you to easily see how much damage you have received just before stopping the damage. For instance, if you are underwater with 9 hearts, if you start drowning you can clearly see you started with 9 and lost 3.

However, "saturation" hearts are the only heath that do not have these transition icons, and food points have the textures but they never worked in the first place.

Comment by [Mod] Torabi [ 07/Aug/14 ]

That's part of the improvements. Did you watch the video demonstrating the new behavior?

Comment by williewillus [ 07/Aug/14 ]

Whatever Mojang tried in 14w32a/b does not work fully.

Test case:
Setup cactus. Hug cactus and stay there.
Expected outcome: Only the lost half heart increments flash each time.
Real outcome: All hearts lost from the cactus hug flash.
If you hug the cactus for ~10 secs about 5 of the hearts will flash.

This is incorrect as it does not show that 0.5 heart of damage was taken each time.

Please check and reopen.

Devs: Look at how it worked in 1.2.5. Replicate that.

Comment by insomniac_lemon [ 31/Jul/14 ]

Confirmed for 14w31a.

Comment by agentpaint [ 31/Jul/14 ]

I cannot confirm if this is still in 14w31a. I can't see the heart bar fast enough.

Comment by williewillus [ 05/Jun/14 ]

Update on bug hunting -
Turns out this problem can be solved by adding ONE LINE to the code.

Mojangsters: Using MCP names

In EntityClientPlayerMP 's attackEntityFrom() method.
Before the return false statement, insert this.prevHealth = getHealth() + par2;
this sets the correct clientsided prevHealth value so the gui can render the flashing hearts appropriately.

Comment by Daniel Garcia [ 01/Jun/14 ]

I reworded almost everything in hopes to get attention more easily from Mojang. Sorry for making several small edits instead of just one large edit.

Comment by Itouch2 [ 01/Jun/14 ]

Confirmed for 14w21b.

Comment by Itouch2 [ 15/Mar/14 ]

Confirmed for 14w11b

Comment by Itouch2 [ 11/Mar/14 ]

Confirmed for 1.7.5 and 14w10c

Comment by Itouch2 [ 23/Feb/14 ]

Still in 08a

Comment by Itouch2 [ 14/Feb/14 ]

Still present in 07

Comment by Itouch2 [ 09/Feb/14 ]

Also affects 1.8 snapshots (06a/b)

Comment by insomniac_lemon [ 04/Jan/14 ]

Still broken up to 1.7.4.

Comment by williewillus [ 18/Sep/13 ]

Did some testing.
This bug has been in multiplayer ever since release 1.0 (it was fine in multiplayer beta 1.8)
With the conversion of singleplayer into multiplayer in 1.3 this bug was carried into singleplayer as well.

Comment by Daniel Garcia [ 12/Sep/13 ]

Bug hasn't been fixed yet neither in latest release or snapshot at the time of writing.

Comment by insomniac_lemon [ 07/Aug/13 ]

Yes, still not fixed, even though they added new GUI icons that included new transition icons. Also, pack.png is once again broken.

Comment by Tails [ 15/Mar/13 ]

Is this still a concern in the current Minecraft version? If so, please update the affected versions in order to best aid Mojang ensuring bugs are still valid in the latest releases/pre-releases.

Comment by [Mod] CubeTheThird [ 15/Nov/12 ]

Can confirm.

Comment by Daniel Garcia [ 15/Nov/12 ]

I've made the description and summary a little clearer.

Comment by stephen locke [ 15/Nov/12 ]

Oh my mistake, I misread your complaint. You could be a little clearer in you description of the problem, but I see what you mean now.

Comment by Daniel Garcia [ 15/Nov/12 ]

It is not about the regeneration, regeneration works completely as expected.
It's about the bright hearts that blink when taking damage, which indicates how much health you had before taking damage. It is gone since Minecraft 1.3, with no mention in the change logs.

Comment by stephen locke [ 15/Nov/12 ]

It looks the same in 1.4.2 you are gaining health from your food, I see no problem.

Comment by Daniel Garcia [ 15/Nov/12 ]

Added example/comparison video.
I noticed YouTube messed up a little up with the video's "lighting", shouldn't be a problem though.

Comment by Daniel Garcia [ 15/Nov/12 ]

I'm uploading a video right now, but internet is slow at the moment. Expect a link in an hour or two.

Comment by [Mod] CubeTheThird [ 15/Nov/12 ]

Based on your screenshots, I fail to see the problem here.

Comment by Jack [ 13/Nov/12 ]

It actually flashes on the 2nd picture

Generated at Sun Jan 12 11:59:31 UTC 2025 using Jira 9.12.2#9120002-sha1:301bf498dd45d800842af0b84230f1bb58606c13.