Update MSGenerator.m