BOSTON -- The Boston Bruins rode high on the emotions of an extra-passionate crowd at TD Garden in the first major sporting event here since the Boston Marathon bombings of Monday, and for 59 minutes looked destined for an emotional victory.

The Buffalo Sabres' drive for the Stanley Cup Playoffs, however, prevailed in the closing seconds of regulation.

Buffalo's Cody Hodgson scored a power-play goal with 27 seconds remaining to tie the game during a 6-on-4, and Drew Stafford scored the only goal in the shootout for a 3-2 Sabres win.

After the game, the teams congregated at center ice and saluted the fans of Boston, who responded with chants of "U-S-A!"

Though the Bruins didn't get two points, the one clinched a playoff spot and tied the Montreal Canadiens for first place in the Northeast Division. And more than anything, the Bruins started the healing process for a city shocked by the tragic events of Monday.

"It's one of those games that you really wanted to get not only for the team, but for the city," Bruins center Patrice Bergeron said. "It's really disappointing but we've got to bounce back. Plain and simple, we've got to find ways."

Despite a tumultuous season in Buffalo that's featured a coaching change and the trade of several veteran players out of town, the Sabres have won three in a row and six of eight to pull within two points of the New York Rangers and the Winnipeg Jets for eighth place in the Eastern Conference. The Sabres have four games remaining.

"We're hanging around," Hodgson said. "Right from the start I don't think anybody really gave us a chance. Instead we're right in the race."

The Sabres' comeback was a dramatic end to an emotional night. The feeling in the building revealed itself early, as many more hundreds of people were already at their seats or near the glass than usual for pregame warm-ups 30 minutes before the puck dropped. The Bruins took the ice to a rousing ovation.

When it came time for the game, the Bruins heard a playoff-caliber cheer, and after a moment of silence and video tribute to the victims, longtime Bruins anthem singer Rene Rancourt came out to play his usual role. But after a couple verses he quieted down, waved his arms and led the crowd in "The Star-Spangled Banner" with the 17,565 on hand providing the majority of the vocals.

"It was a pretty emotional start," Ference said. "I think me and [Dennis Seidenberg] were over besides each other, especially during the anthem, I think just trying to hold it together a bit. It was pretty awesome hearing everybody sing like that. And obviously the emotions were pretty high.

"We all knew that tonight was more than just another game. It meant a lot to people as another step [in the healing process] and it was no different for us on the ice trying to have some remembrance of the last couple days but also move on as well to getting back to business in this city.

"It was tough. It was really tough. The first shift I think everybody was pretty choked up. I can't remember being that emotional on the ice except for the last few seconds when we won the Cup (in 2011). I think that was the only equal as far as emotions."

The Bruins didn't immediately feed off the added energy; it took them 4:58 to put their first shot on Sabres goalie Ryan Miller, who finished with 41 saves. But with "Let's Go Boston!" chants replacing the usual "Let's Go Bruins!" roars throughout the first several minutes of the period, the home team finally gave its fans a reason to really yell.

Boston's Chris Kelly won a battle in the corner of the Buffalo zone and fed the front of the goal, where Daniel Paille one-timed a puck past Miller for a 1-0 lead at 5:45.

Boston outshot Buffalo, 12-9, in the first period. However, a late penalty against Zdeno Chara cost the Bruins the lead. With 1:40 remaining, Vanek tipped a power-play goal past Khudobin after a wrist shot from the blue line by Christian Ehrhoff.

The Bruins broke the tie with 5:12 left in the second period. Kelly and Paille again hooked up, this time with Paille feeding the puck across the slot to Kelly. After he stopped the puck with his skate, he worked it to his blade for a flip over Miller's pad and a 2-1 lead.

However, the Bruins weren't able to hang on long enough for the two points.

"We wanted to go out there and win that hockey game," Kelly said. "I'm disappointed that we didn't. We wanted to give the city something to be happy about. We went out and battled hard, I'm not taking that away from the guys. But we really wanted to get the two points, and hopefully we put a smile on someone's face. So we're pretty upset that we didn't [win]."