The effect of ion mass and target temperature on the energy distribution of sputtered atoms