We consider an out-of-equilibrium lattice model consisting of 2D discrete rotators, in contact with heat reservoirs at different temperatures. The equilibrium counterpart of such model, the clock-model, exhibits three phases; a low-temperature ordered phase, a quasi-liquid phase, and a high-temperature disordered phase, with two corresponding phase transitions. In the out-of-equilibrium model the simultaneous breaking of spatial symmetry and thermal equilibrium give rise to directed rotation of the spin variables. In this regime the system behaves as a thermal machine converting heat currents into motion. In order to quantify the susceptibility of the machine to the thermodynamic force driving it out-of-equilibrium, we introduce and study a dynamical response function. We show that the optimal operational regime for such a thermal machine occurs when the out-of-equilibrium disturbance is applied around the critical temperature at the boundary between the first two phases, namely where the system is mostly susceptible to external thermodynamic forces and exhibits a sharper transition. We thus argue that critical fluctuations in a system of interacting motors can be exploited to enhance the machine overall dynamic and thermodynamic performances.