Metformin and beer do not mix very well, be careful. You sound like an experienced drinker but the medicine intensifies the effect of alcohol and you can become drunk very fast. I'm type 1 but take Metformin for another hormone issue. I also have had my own history with drugs and alcohol, so no judgment here. Just know that there are other ways to cope.
Back to Metformin, when I first started taking it many years ago, one night I went out with some friends and we were at a bar drink, pretty normal. Well, I met a guy and my friends wanted to leave so I stayed. The next thing I remembered was waking up in the Police Station. Apparently, I became so drunk that the bartender started calling people in my phone to come pick me up. I wasn't causing a problem but was pretty much passed out. They finally go a hold of my friend who was out of town and he told them I was a diabetic and to make sure that my blood sugar didn't go too high or too low.
They panicked and called the police, who took me in for my own protection. I wasn't arrested nor did they give me a ticket but it was really embarrassing. Plus, I felt like shit for the next few days.
Keep working on trying to find healthier ways to cope and just be careful with the alcohol. The diet and exercise will help - don't give up on that, just try a little every day and if you fall off track that's o.k.- we all do.
Most important thing is to keep trying and don't judge yourself harshly.