Adapted network controller to work with rectangular polygons.