Hi there, and congratulations on starting over! Honestly, don't beat yourself about regaining or where you "once were" - just forget about it and start today. Starting when you're in a better place is always a good idea, so you build that foundation for when something happens - when you're able to stay on track through those bad times - your confidence is going to burst through the roof!
I spent half of my 20s and all of my 30s overweight - and finally had enough the year I turned 40. I just turned 44 and, literally, one of my greatest regrets so far is that I lived like that for so long. It wasn't just about being overweight, for me, it was also about serious long-term depression, crazy binges, losing all my friends, stopping all things I enjoyed doing and hating my job. I wish I could erase that, not only for myself, but for every person alive.
You are 31 and starting afresh. Be proud! I wish I could've done it at 31 - oh! The fun I would've had all those years!