Position Pain?

Hannah
Okay I feel so stupid and shy about asking this but here we go. 
My boyfriend and I have been together for a little over two years and he is the first person I have ever had sex with consensually. We are long distance and the last time he was here we had a lot more freedom to be sexual. We did a lot of stuff we'd always talked about, however, when I got on top to ride him, I felt a pain in my stomach every time him or I moved. I could see the look on my face and immediately stopped, asked me if I wanted to keep going, and when I said yes we just switched positions and it no longer hurt. 
I'm not too sure what the pain was or if it was normal. I'm right now thinking that considering I've only ever been with him, it's just that my body is getting use to everything and after time the pain will go away, or at least I hope. 
Any advice?