I think (it is well-known that) $r(M) = \dim \mathrm{Soc}(H^t_{\mathfrak{m}}(M)) = \ell (\mathrm{Hom}(R/\mathfrak{m}, H^t_{\mathfrak{m}}(M)))$.
Indeed, choose an $M$-regular sequence $x_1, \ldots, x_t$ of $M$. We have
$$\mathrm{Ext}^t_R(R/\mathfrak{m}, M) \cong \mathrm{Hom}(R/\mathfrak{m}, M/(x_1, \ldots, x_t)M).$$
We proceed by induction on $t$ that $\mathrm{Hom}(R/\mathfrak{m}, H^t_{\mathfrak{m}}(M)) \cong \mathrm{Hom}(R/\mathfrak{m}, M/(x_1, \ldots, x_t)M)$. The case $t = 0$ follows from $\mathrm{Hom}(R/\mathfrak{m}, H^0_{\mathfrak{m}}(M)) \cong 0:_M \mathfrak{m} \cong \mathrm{Hom}(R/\mathfrak{m}, M)$. For $t>0$, consider the short exact sequence
$$0 \to M \overset{x_1}{\to} M \to M/x_1M \to 0.$$
Apply local cohomology functor we have the exact sequence with note that $\mathrm{depth} M = t$ and $\mathrm{depth} M/x_1M = t-1$
$$0 \to H^{t-1}_{\mathfrak{m}}(M/x_1M) \to H^t_{\mathfrak{m}}(M) \overset{x_1}{\to} H^t_{\mathfrak{m}}(M) \to \cdots.$$
Thus $H^{t-1}_{\mathfrak{m}}(M/x_1M) \cong 0:_{H^t_{\mathfrak{m}}(M)}x_1$. Therefore
$$\mathrm{Hom}(R/\mathfrak{m}, H^{t-1}_{\mathfrak{m}}(M/x_1M)) \cong (0:_{H^t_{\mathfrak{m}}(M)}x_1) : \mathfrak{m} = 0:_{H^t_{\mathfrak{m}}(M)} \mathfrak{m} \cong \mathrm{Hom}(R/\mathfrak{m}, H^t_{\mathfrak{m}}(M)).$$
Now the claim follows from the inductive hypothesis.