New version of the script using wmparc mask