“I was really sleepy because I had gone out drinking the night before.”
You're telling a story about something that happened to you at work one day when you were really tired. You are telling the setup for the story. You give this bit background information.
I was really sleepy because I had gone out drinking the night before.
When you are setting up a story, you start by describing the situation at the beginning, before the interesting events happened.
When you're telling a story, you describe the setting at a certain time in the past. If you then want to describe something that happened before the setting of the story, you use "I had ___". Here's an example:
I was almost at the train station when I realized that I had left my wallet in my other purse.
You can also talk about things that didn't happen before the setting of the story. In this sentence:
Believe it or not, I had never even traveled abroad when I moved here.
...the basic setting of the story is "when I moved here". The speaker didn't have any travel experience then, although she might have some now.
"Last night" is the phrase that you use to talk about something that happened on the most recent night when counting back from right now. But when you're counting back from some time in the past, you use the phrase "the night before". Here are some other time words that change depending on whether you're counting from now or from a time in the past or future:
- today > that day
- tomorrow > the day after / the next day
- last week > the previous week
- next month > the following month
To "go out drinking" means to go to a bar in order to drink. It's used when describing this. When you're inviting someone to do it, you say "go out for drinks" or "go out to a bar":
We went out drinking on Saturday night.
Would you like to go out for drinks with us?