  Galaxy cluster number counts are an important probe to constrain cosmological
parameters. One of the main ingredients of the analysis, along with accurate
estimates of the clusters' masses, is the selection function, and in particular
the completeness, associated to the cluster sample one is considering.
Incorrectly characterising this function can lead to biases in the cosmological
constraints. In this work, we want to study the completeness of the Planck
cluster catalog, estimating the clusters' probability of detection in a
realistic setting using hydrodynamical simulations. In particular, we probe the
case in which the cluster model assumed in the detection method differs from
the shape and profiles of true galaxy clusters. We create around 9000 images of
the Sunyaev-Zel'dovich effect from galaxy clusters from the IllustrisTNG
simulation, and use a Monte-Carlo injection method to estimate the completeness
function. We study the impact of having different cluster pressure profiles, as
well as that of complex cluster morphologies on the detection process. We find
that the cluster profile has a significant effect on the completeness, with
clusters with steeper profiles producing a higher completeness than ones with
flatter profiles. We also show that cluster morphologies have small impact on
the completeness, finding that elliptical clusters have slightly lower
probability of detection with respect to spherically symmetric ones. Finally,
we investigate the impact of a different completeness function on a
cosmological analysis with cluster number counts, showing a shift in the
constraints on $\Omega_m$ and $\sigma_8$ that lies in the same direction as the
one driven by the mass bias.
