Despite being one of the most notable actors of his generation for his wit and talent in the hit comedy series "Drake & Josh" during his time in Nickelodeon, the actor revealed he didn't feel happy most of the time because of his struggles.

In an interview with People Magazine, the 35-year-old star, who weighed almost 300 pounds during his teenage years, revealed he used his comedic skills as a "natural defense mechanism."

Peck then wanted to be "typical," but he grew up as an overweight teenager, a musical theatre kid who "had no social status."

A post shared by instagram

After years of changing his physical appearance, the "How I Met Your Father" star finally lost a shocking 120 pounds, but despite reaching his goal, Peck said there was something else he looked for, so he decided to turn to drugs and alcohol.

At the time, the actor had a realization, saying after he lost weight, he was "the same head in a new body."

"I discovered drugs and alcohol," he said before admitting that it became his next chapter.

Peck also revealed he turned into drugs and food to "numb" his feelings. (via E! Online)

He claims that unknown substances he took felt like a "buffet" that helped him overcome his insecurities throughout his early years.

READ NOW: Jennifer Lawrence Shares Biggest Wish After Giving Birth, Names Fave TikTok User

The drugs also gave him confidence and the feeling of attractiveness when he was partaking.

"I was trying to quiet that voice that woke me up every morning and told me I wasn't enough," he revealed.

It wasn't long until the drugs took a toll on his thriving career, which made him almost fade into the background as he started becoming the "unstable and erratic" actor in Hollywood.

The experience motivated him to stop his wrongdoings, so he finally entered a treatment facility to help him with his problems and get sober.

Looking back, Peck said it took him a while to love and accept his younger self, and he realized how strong he was.

Today, Josh Peck is expected to release his "candid memoir" titled "Happy People Are Annoying" on March 15.

According to the publisher Harper Collins' website, the book will contain life lessons for people who are trying to accept their past and make peace with their present.

READ ALSO: 'Black Panther' Director Ryan Coogler Wrongly Arrested For Bank Robbery While Filming In Atlanta Georgia