When do i give up

Me and my ex are having a baby, but we’re not together. He’s decided to get back with another old ex. I still have feelings for him and was hoping we could work things out, but whenever he’s around her he becomes super distant/cold towards me. To the point where i texted him last night around 7pm letting him know my grandpa passed so i might have to reschedule my appointment & he didn’t respond until this morning. Or he has to “step outside” to talk to ME (the mother of his kid) in his own home or he just won’t answer my calls when he’s around her. Let alone go out of his way to call me. I just feel like at this point it’ll be impossible for us to work things out so that we can raise our child together. I didn’t want to have to worry about the weekends or splitting our time or his ex playing house with my kid. But it’s feeling like that’s the only option.

Like i said i still do love him, but it seems one sided. I feel like I’m the only one making an effort. I just want to get over him but i don’t know how to do that with his child inside me. It’s so hard. If i wasn’t pregnant i would just never speak to him again, but i can’t do that. When do i pick myself ? I feel like I’ve been so accommodating to his happiness but what about mine ? I just wanna feel happy & secure again, i want to love myself again. I want to find someone who will love me & my child more than anything. I just don’t know how to move on, it’s so much harder with a child involved.