Morphogenesis in biological systems is controlled by the parameters encoded in the genomes and rules of interaction between different components of the system and environment. Several methods are proposed for developing morphology of artificial structures. Some of them are inspired by embryogenesis in biological organisms. Others use more abstract generative encodings such as variances of L-systems. Our approach to morphogenesis is based on the distribution of a common resource between competing components of a growing system. The novel distributed controller called Vascular Morphogenesis Controller (VMC) is inspired by the growth process of plants and more specifically the competition between different branches for developing vessels and thus for further growth. The initial algorithm is introduced for modular robots. Here we use it to solve a maze.