No worries!
You could make three formation types (based on the number of living party members), which each have their own set of directions and movements, collisions, etc. But that would probably have taken ages to implement, so for a jam game, your method worked fine! Carrying around corpses definitely seems like it would be awkward, so you probably made the right call with your available solutions.