Slimes have no attack cooldown, resulting in the player taking numerous hits repeatedly depleting their health far quicker than other mobs with normal attack cooldowns.
Steps to Reproduce:
Modify the player's knockback resistance:
/attribute @p minecraft:generic.knockback_resistance base set 100
Give the player regeneration:
/effect give @p minecraft:regeneration infinite 255 true
Summon a slime with a size large enough to attack you
/summon minecraft:slime ~ ~ ~ {Size:3}
Walk up next to the slime
Observed Behavior:
The player is attacked in rapid succession, with no delay in between each attack.
Expected Behavior:
The player would be some invulnerability before taking damage again, like other mobs.
Screenshots/Videos:
[media]
Notes:
Related issues
Attachments
Comments


Confirmed for 1.13.1.

Confirmed in 1.15.2. Gnembon explains why this occurs from 11:00 to 13:00 in this video https://youtu.be/42QvewJqKF0 Essentially slimes deal damage whenever their hitbox intersects with a player, rather than actively attacking.

It's not a bug, it's just how slimes work. Magma cubes do it too.
Can confirm in 20w48a.
Can confirm in 21w06a. Closely relates to MC-169167.
Can confirm in 1.16.5 and 21w08b.
Can confirm in 1.17.1.

This isn't just exclusive to big slimes. Medium sized slimes and all sizes of magma cubes also have this issue. It's only noticeable from big slimes due to their hitbox.
Can confirm in 1.19.
Can confirm in 1.19.2.
Can confirm in 1.20.5 Pre-Release 1. Considering the original reporter has not been active since the creation of this issue, I'd like to request ownership of it.

Can confirm in 24w19b. This is immediately apparent when blocking with a shield.

As affects magma cubes. I was in snapshot 25w06a & I had a magma cube get stuck in a tunnel with me and it basically killed me before I could even react even with 2 pieces of protection armor on.