setDamageCooldownTicks

public void setDamageCooldownTicks(LivingEntity entity, int ticks)

Changes only the native hit cooldown; the previous hit amount and other immunity remain unchanged.