BUFFALO — There is no denying the fact that Devin Cannady always dreamed of a moment just like this: A Notre Dame game in the NCAA Tournament on the line in the final seconds and he takes the last shot . . .

Except that he always had envisioned himself playing for Notre Dame, having grown up six miles from campus in Mishawaka, Indiana, and of course he pictured himself making that shot. So it was “horrible,” he said, when his long three-point attempt with three seconds left hit off the back of the rim and sent Princeton to a 60-58 first-round loss Thursday.

“You’re at the biggest stage, you have a chance to knock off a team and go ahead in this tournament, and you have to go home now. It’s a horrible feeling,” said the sophomore guard, who could have earned a place forever in March Madness lore. “I got my feet set, the ball came in my shot pocket. I looked at the rim, and when the ball left my hand, I thought it was good.”

He was not the only one. Notre Dame’s V.J. Beachem, a good friend of Cannady’s from playing summer ball in South Bend, said, “It looked on line, and I’m thinking wow, the hometown kid put up a shot to beat his hometown team. But it came off.”

Fact is, it was not just a matter of one shot. Notre Dame (26-9) actually led most of the way, going up six at the half by dominating inside and continuing to go to Bonzie Colson, who had 18 points despite a sore ankle.

It took a huge effort by the Ivy League champion Tigers (23-7) to rebound from an 11-point deficit. Perhaps the run’s most significant moment was a four-point play by Cannady with 8:35 left that cut it to five.

advertisement | advertise on newsday

Fans at KeyBank Center responded, having adopted the 12th seed against the fifth in the West Regional. “When there’s an upset at stake, neutral fans tend to go with the lower-seeded team,’’ Beachem said. “We’ve been in those situations before.”

Experience was the biggest factor overall, according to players and coaches on both sides. Defensive savvy helped the Irish hold Princeton to 8-for-31 shooting on three-pointers. Not even when Matt Farrell (16 points) missed a free throw with 10.6 seconds left and Notre Dame up by one did the Irish get rattled.

“We’ve been through a lot of those game situations. We’ve worked on it since summertime,’’ Colson said. Farrell added, “We’ve got a lot of guys that are poised.”

One of them, Steve Vasturia, rebounded Cannady’s last shot and hit a free throw. Then it was off to the handshake line, where Notre Dame players consoled their friend Cannady, who never was offered a scholarship by his hometown school. He got over that disappointment, and he promised to get over Thursday’s.

“I know my teammates and my coaching staff would have confidence in me taking that shot. I would as well. It was just unfortunate this time,” Cannady said. “We know we can play at this level and we will, next year.”