Lots of sensible advice based in experience here. I’ve been through this and did some things well and somethings badly so for my tuppence worth here goes.
Kids are the most important but you have to be strong for them. So try to get some stability in your life. A real routine so that you have less time to flounder or wallow no matter how grim you are. Ride, drink, socialise whatever but stick to it. Don’t cry in front of kids. They know you are hurting, but will be unsure about how to respond. Keep away from Facebook. Things will be/get distorted know matter what you say. Face to face contact asap or there will be a difficult gap to bridge when you do see them. Typing takes no effort, turning up does and that counts far more than you can imagine.
Talking to my kids 20 years on they said that the best thing that me and the ex did was never blame the other or make them choose between us. We got to the point of agreeing dates a year in advance! That helped them and me as it provided structure. They have turned out as great kids and even though me and ex never talk kids feel that they have had good input from both of us.
If you are not at fault don’t move out. Her choice so she has to back up her decision. Even if you have to her cash to go and set up with new man or on own. It also means you have the kids. That might be a really hard thing to sort when combined with school and work but its the best financial decision you’ll ever make. I left the house so that the ex could have some space and that sealed 10 years of being screwed financially and emotionally. Possession being 9/10ths etc.
As others say time heals and it does. Take care mate.