AMHERST — It’s really quite funny, and I guess also a little sad, that there were a few people out there who believed pro basketball player Jason Collins should just keep it to himself that he’s gay.

They said the same thing about college football player Michael Sam.

“OK, so you’re gay. Why do you need to broadcast it?”

But though neither Collins nor Sam knew it at the time, they were sending instant messages to a scared, lonely, confused kid named Derrick Gordon. The rest of us were allowed to glance at those messages, and to talk about them, and to re-frame them as historic news bulletins, but understand this: They were meant for Derrick Gordon. And for people like him.

Collins and Sam were telling Derrick Gordon, in so many words, not to be afraid, that you’re not alone, that it’s OK to open up to people about who you are . . . and that crying yourself to sleep is no way to end the day.

And so tonight at 7 at the Mullins Center, when the UMass men’s basketball team takes on Siena in its 2014-15 season opener, a new Derrick Gordon will emerge. Yes, the 6-foot-3 junior guard worked all summer to improve his jump shot and his consistency from outside the 3-point circle, and he expects the results from all that toil to be on display, but the fans will also be seeing the debut of the nation’s first publicly out player in Division 1 men’s basketball.

What’s amazing about all this is that just a couple of years ago Gordon was so worried about his sexual orientation he considered walking away from “the game I’ve loved all my life.”

What’s even more amazing is that, even now, there’s that peanut gallery out there that wants these gay folks to keep it to themselves.

“Some people don’t understand what it’s like to feel like you’re by yourself,” Gordon said. “To be crying every night and to have nobody to go to and talk to. I had been crying every night for the past four years, and that’s not easy.

“And to want to quit basketball like I almost did? It’s easy for anybody who’s not going through it to say, ‘Why’s he doing this?’ If you go through it, you’ll understand the reason why I did it.”

Gordon did not tip-toe out of the closet. Instead, he busted down the door like Chris Farley in the airplane restroom scene in “Tommy Boy.” He now has a boyfriend in Los Angeles, gay friends on campus and a Twitter feed that’s festooned with rainbow colors. He’s gay. Deal with it.

“I like being gay,” he said.

And it all began with Jason Collins, the now-retired NBA journeyman who came out after the 2012-13 season.

“Everything leads to the NBA for me, and I didn’t want my dreams to be shattered because of my sexuality,” Gordon said. “So when I saw him come out, that inspired me.

“I said, ‘If he’s in the NBA and he’s openly gay then maybe I can be the same way,’ ” Gordon said. “And when he played for Brooklyn, I saw a YouTube video of him coming into the game and the whole crowd stood up and applauded. It was, like, man, he has a lot of people supporting him. That did it for me.”

And then, this past February, Michael Sam came out.

“He’s in a different sport but I looked up to him as well,” Gordon said. “Both of them are like my big brothers. I’ve gotten to know them and I always ask them for advice because they’ve been there before me.”

And the cycle continues. When Gordon came out this past spring — “April 9,” he keeps saying, as though it’s his own personal national holiday — that’s when the letters and emails began pouring in. As Collins and Sam changed Gordon’s life, now Gordon was changing the lives of others.

“I’ve heard from so many people who want to come out,” he said. “Not just here, but all over the world. France. Germany. China. Kids who came out to their coaches. Adults who came out and want to start over, saying they’re doing it because they were inspired by me.”

He has also heard from athletes from other colleges who have yet to come out.

“They’ve reached out and said I’ve helped them out a lot,” Gordon said. “A lot of them are waiting to see what happens to me, I guess.”

As to “what may happen,” Gordon doesn’t seem to care. He expects to be embraced by the fans tonight at the Minutemen’s home opener, but there will be big games on the road, and big crowds, and, maybe, some nasty words.

“If I’m at the free throw line and someone says something, I’ll either laugh or I’ll smile,” he said. “I’m not going to get mad or say anything. I’ve been called much worse, honestly. If someone calls me gay or (expletive), whatever, that’s nothing. I know that I’m gay. The whole word knows I’m gay.

“Besides,” he said, “it’s not like I’m going to be the only gay person in the building. In the closet or out, I won’t be the only one. So I can just smile.”

He’s doing a lot of smiling these days. He’s out. His game is better. And his family life has improved to the degree that his twin brother Darryl, who served time in prison for attempted murder, plans to be at the Mullins Center. Though the two have talked on the phone, they haven’t seen each other since Derrick came out and Darryl got out.

“He’s more excited than me for (tonight),” Gordon said of his brother. “And the way everything is happening — my family accepting me, Darryl starting over, my game, everything.”

Happy now?

“Beyond happy,” he said.