Simple solution I used.

Each shaman targets the next one in the group - if that one is dead the shaman targets himself. Ie:

/cast [target=nexttoon,nodead][target=player] Chain Heal

Works perfectly.