Scott Hartnell's gritty and productive effort paved the way for Vincent Lecavalier to break out of his slump, ending the Flyers' two-game losing spell with a 4-3 comeback win in Buffalo on Tuesday night.

Hours after calling his team's recent play "soft," Hartnell posted a goal and two assists, playing through a blocked shot that had him limping off the ice during the second period. He received X-rays on his left ankle after the game.

"Sometimes you've gotta get hurt or whatever, but we showed a lot of character, especially late there, coming back," Hartnell said.

The Flyers trailed 1-0 and 2-1, but scored three third-period goals to bury a bottom-dwelling Buffalo Sabres team that came into the game 6-0-2 in their last eight home games.

"Never give up," Hartnell said. "That's probably the biggest thing. You gotta believe. You've gotta play the system. You've gotta skate like we did in that third period and you win battles and you work hard, you're gonna get chances."

That's the ethos Lecavalier was forced to focus on during a recent slump that ended, hopefully, with Tuesday night's game-winner with 14.8 seconds left.

"It felt good," Lecavalier said. "They've been hard to come by since I got back from my injury. Sometimes a goal like that will kinda, I don't want to say jumpstart, but get more confidence and keep going."

Lecavalier had recorded just three assists in 11 games since coming back from a non-displaced fracture in his back that caused him to miss just under a month of hockey.

"The last four games I've been feeling really good, my legs," he said. "It's good for the confidence any time you get out of the slump and hopefully that'll get me going and create more with my linemates. Hopefully that starts a streak."

Both players and head coach Craig Berube hailed the team's comeback spirit, as they admitted frustration with a first period that saw them go down 1-0 on a Cody Hodgson tally.