Matthew Perry fits his role in the new sitcom “Mr. Sunshine” quite well, in part because it’s based on himself.

“I like to say that this character is me, like, five years ago before any possible enlightenment 
could have come into my life,” he told reporters at press tour last year.

But it’s a role he knows well: “I’m very in touch with a selfish guy trying to have a better life and how confused a selfish person would get if he were told that the way to have a better life was to just be nicer to people and care about people.

“That’s a character that I thought would be fun to explore in a sea of sort of dysfunctional people and a fun arena in which for it to take place,” Perry says.

In some ways it’s a lot like his old Chandler Bing character on “Friends.”

“I don’t think people want to see a character that’s night-and-day different than Chandler, but we want to try to do something different things. So you want to take advantage of that something that worked before, but you also want to show something new.”

And the “fun arena” is an actual arena. His character plas the manager of a midsized sports arena called The Sunshine Center (though it’s actually shot at the Forum in Inglewood)

this guy named Lee, who does
this job at the Staples Center, I spent a day with
and asked — and will continue to bother this guy
throughout the process. You know, w

“What drove us to want to do a show at this place was, you know, if you have sort of a dysfunctional family working in such a huge venue, if we had cameras on, how crazy some of these people who are, but they have to get it together every night because 18,000
people are showing up. “

It’s something he knew as a child. “As a kid, I was just real excited and thrilled to go to any of those places,” Perry says. “I just had this feeling of excitement, and the people working  there must feel that, too.

“We were just trying to think of a place where kind of the most interesting, insane things can come in,” he says. “So one night there’s a Bruce Springsteen concert, but the next night, there’s a lingerie football game, and that’s actually an episode that I’m very much looking forward to shooting.”

“Mr. Sunshine” did well in its debut Wednesday, drawing 10.52 million viewers in the slot just after the hit “Modern Family.” It runs Wednesdays at 9:30 p.m. on ABC.