Rooney is third on the list of United's all-time leading goalscorers after his strike against Swansea City on Saturday took his tally to 217 in all competitions.
|MAN UTD LATEST|
|9/1||Wayne Rooney is 9/1 with bet365 to be Premier League top scorer|
"You have to live like a top player," Hamann told Perform. "If you want to be the best, you have to live like the best.
"And if you like to party on the weekends and drink beer or a glass of wine too much that could be negative for your performance and I think that's the big difference between Rooney and Cristiano Ronaldo.
"Rooney always knocked on the door to be world class but never did the final step. And Ronaldo overtook him because he's obsessed. He's a real hard worker. The way he shoots his free kicks is the result of years of training. That doesn't come overnight.
"As I said, often the really talented players tend to do a little bit less because they can get away with it and the others are not as talented as they are. But if you have the talent, the morale and work really hard then you'll become a Ronaldo or a [Lionel] Messi."
Hamann, however, feels new United manager Louis van Gaal could go a long way in helping Rooney perform at his best, having appointed the England international as skipper.
"Van Gaal made him the captain. He knows that it's his last chance - he is 28 or 29," the German added. "Rooney needs to perform now, he has three or four years left to play at the highest level. Van Gaal is a coach who gets the best out of players - or he sends them away.
"He made him captain, the relationship seems to be good, and that is good for Manchester United and for Wayne Rooney. I am expecting a lot from him this season, but we have to wait to see whether the team is good enough."