Concerned,
I'm so sorry you and your friend are involved in this.
Unfortunately, there is nothing you can do for your friend except to be there for him when he needs someone to talk to, a sounding board, just somebody sane to be with.
Hard as it is to face, this is not your affair. This is HIS relationship with the woman he is/was married to, HIS relationship with his children, and HIS relationship with the courts, and there is no intervention you can do that would be helpful.
But you can be his friend. That's what he seems to need the most of all right now. Someone whose presence will remind him that he's not crazy. That's what a lot of us here find we need.
Wishing him luck.
GL