  Galaxy clusters are luminous tracers of the most massive dark matter haloes
in the Universe. To use them as a cosmological probe, a detailed description of
the properties of dark matter haloes is required. We characterize how the
dynamical state of haloes impacts the halo mass function at the high-mass end.
We used the dark matter-only MultiDark suite of simulations and the high-mass
objects M > 2.7e13 M/h therein. We measured mean relations of concentration,
offset, and spin as a function of halo mass and redshift. We investigated the
distributions around the mean relations. We measured the halo mass function as
a function of offset, spin, and redshift. We formulated a generalized mass
function framework that accounts for the dynamical state of the dark matter
haloes. We confirm the discovery of the concentration upturn at high masses and
provide a model that predicts the concentration for different values of mass
and redshift with one single equation. We model the distributions around the
mean concentration, offset, and spin with modified Schechter functions. The
concentration of low-mass haloes shows a faster redshift evolution compared to
high-mass haloes, especially in the high-concentration regime. The offset
parameter is smaller at low redshift, in agreement with the relaxation of
structures at recent times. The peak of its distribution shifts by a factor of
1.5 from z = 1.4 to z = 0. The individual models are combined into a
comprehensive mass function model, as a function of spin and offset. Our model
recovers the fiducial mass function with 3% accuracy at redshift 0 and accounts
for redshift evolution up to z = 1.5. This approach accounts for the dynamical
state of the halo when measuring the halo mass function. It offers a connection
with dynamical selection effects in galaxy cluster observations. This is key
toward precision cosmology using cluster counts as a probe.
