We propose a novel method for evolving adaptive locomotive strategies for virtual limbless creatures that addresses both functional and non-functional requirements, respectively the ability to avoid obstacles and to minimise spent energy. We describe an approach inspired by artificial immune systems, based on a dual-layer idiotypic network that results in a completely decentralised controller. Starting from a system initialised with five non-adaptive locomotion strategies, we show that an adaptive controller can evolve that both minimises energy requirements and maximises distance covered when compared to the initial strategies.