NZ military to buy five Hercules planes