In this paper, we propose a feasible scheme for generating the Schrödinger-cat-like states of a macroscopic mechanical resonator in pulsed cavity optomechanics via photon detection. Starting with cooling the mechanical oscillator to its ground state, a red pulse and a blue pulse with different powers are simultaneously employed to dissipatively generate squeezed mechanical states. Subsequently, a second red pulse is utilized to achieve large-amplitude mechanical catlike states with high fidelities, conditioned on the multiphoton detection of c...