My parents divorced at 10, the rest is a long, sad story.
Regardless! I'm here to help!
It sounds like you stay away because he's acting irrationally. Your grades may be a result of your inner conflict of, "should I see him? He's my dad, but he's not in a state of mind is like to see him." Trust me, that can drop your morale big time. I don't know the full story, and these are my speculations. Please PM me if you would like to talk.