The MBTA Communities Act was meant to boost housing, but Marblehead shows how easily localities can game the system.