PHILADELPHIA — The scoresheet will show the Rangers edged the Flyers, 3-2, in a shootout Saturday afternoon, but the win resonated on much deeper levels with the players.

Henrik Lundqvist said the comeback from being down 1-0 in the third period and without captain Ryan McDonagh, who left early with a possible concussion after a sucker punch from Flyers forward Wayne Simmonds, “shows ourselves what type of mentality you need to win games. You need to believe that you can go after a team and create chances rather than wait-and-see.”

Keith Yandle, who played a season-high 27:33 with McDonagh out, and whose top-shelf rocket with 12.9 seconds left forged a 2-2 tie and forced overtime, said coming away with two points after facing the very real prospect of leaving with none, “was huge . . . there were a lot of emotions in the locker room.”

After a game marred by questionable officiating, Derick Brassard simply said: “It wasn’t pretty. But when we’re desperate, we’re good.”

To be sure, it was an uphill climb for the Rangers to win consecutive games for only the second time since Nov. 25. After a scoreless first period that was punctuated by the McDonagh-Simmonds incident, coach Alain Vigneault said: “They totally dominated us in the second, if it wasn’t for Hank, it would have been over. In the third it was our turn to dominate.”

Lundqvist made 19 saves in the second period, allowing a lone goal on the Flyers third power play of the period, when Shayne Gostisbehere’s sliding shot from the point snuck past a screen at 7:16. “We knew it was going to be a tough task to turn this around, but we had a good talk after the second,” said Lundqvist.

In the third, Chris Kreider’s tip of Mats Zuccarello’s shot at 3:16 tied the score at 1. The Rangers continued to press, but Zuccarello lost the puck in the neutral zone and Ryan White, off the rush, beat Lundqvist with a stoppable shot at 5:46 to restore the lead. With Lundqvist pulled for an extra attacker, Yandle’s blast from the point sent the teams into their third overtime at Wells Fargo Center this season.

“It was a good example of fighting until the last second,” said J.T. Miller. Actually that was just the first step, securing a point. The second came in the shootout. After Flyers forward Sam Gagner shot wide, Zuccarello deked and beat goaltender Steve Mason in the first round gave the Rangers an edge. Lundqvist’s pokecheck denied Claude Giroux’s try and Derek Stepan ended it with a wrister, giving the Blueshirts their 29th win and 63 points.

The major concern was McDonagh. “He was held out for precautionary reasons, and was being treated and evaluated,” said a team spokesman, who did not specify the nature of the injury.

At 10:36, McDonagh tried to protect himself from a Simmonds check by raising his stick, which caught the back of his helmet. The pair grappled; McDonagh followed with a slash. Simmonds turned and landed a gloved left to McDonagh’s right jaw, which dropped him. With McDonagh face down, Kevin Klein grabbed Simmonds, as McDonagh was examined by trainer Jim Ramsay. Simmonds was ejected and given a five-minute match penalty and game misconduct. McDonagh received four minutes for slashing and cross-checking.

“Ryan’s a big part of our team, but you’ve got to keep playing,” said Vigneault.

It took will and resolve, but that’s what the Rangers did.