All of the advice in here is really good. The most important piece being the communication with your roommate.
During my sophmore year in the dorms, I had one of the coolest roommates I've ever lived with, and we were so completely opposite. He was a freshly returned Mormon missionary who didn't smoke, drink, swear, or ever get with a woman. The reason we got on so well was the respect we had for each other and the communication. The first day we sat down and talked about living together, and at that point I was scared shitless of what the year was going to be like with this pious Mormon,I was honest about what I do, my drug use, all of it. We agreed that I wouldn't use anything in the room, no need to put my roommate at risk for my actions when he wants no part of them. That was easy enough for me to respect. Next, we worked out what to do if I had a girl in the room, but agreed it would be better to go to her room or somewhere else (it's a dormitory, there aren't many places it hasn't happened). The year went smoothly, and there were no problems between us. I seriously pissed off another neighbor so much that he tried to have me arrested, by telling the police I sell drugs out of my dorm room. When the police came searching, my roommate verified that he had never seen me selling drugs or bring them into the room (why not leave them in the car, I never drive anyway). He saved my ass from going to jail, all by his honesty and me living up to our agreements.
moral of this blabbing: talk to you roomate.