Magnetic field and atomic order effect on the martensitic transformation of a metamagnetic alloy