NEW YORK - They stood in the middle infield, embracing under the lights in Queens much as they had many times before.

David Wright and Jose Reyes, once the two young cornerstones of an organization, weren’t celebrating a division title or a postseason victory or even any sort of regular season win, a victory in and of itself around these parts sometimes.

The two were embracing one final time Saturday to salute the end of Wright’s career. And with that comes the end of an era for the Mets, the team that drafted Wright in 2001. The longtime captain has surrendered to the back, neck and shoulder injuries that kept him out of action since 2016 and limited him so severely in the preceding years.

The final score was 1-0 and it took 13 innings to get there, but the 13th inning was meaningless compared to the fifth. Austin Jackson's double to left-center off Javy Guerra scored Michael Conforto from second base to give the Mets, and Wright, the walk-off win.

"Man, I'm glad we won," Wright joked to the fans in a postgame speech. "This is love, I can’t say anything else. This is love."

The fifth was when Mets manager Mickey Callaway came out of the dugout and the umpire gave Wright the signal: He was coming out of the game. He tipped his cap, saluted the sellout Citi Field crowd with tears in his eyes and embraced each and every teammate, coach and staffer before heading down the dugout tunnel and back to the clubhouse.

Years ago, Wright never could have known that at 35, he’d be coming out of the game forever. He had hit three home runs in each of his last three games before hitting the disabled list in 2016, which makes this seem even crueler. Wright’s last hit was a 424-foot homer off then-Los Angeles Dodger Chris Hatcher on May 27, 2016.

A player in his prime saw his career cut short by a series of debilitating injuries.

"We’ve had some pretty good times here and some rough years but you guys have always had my back and that means the world to me," he said in his postgame speech. "I wish I could thank everyone individually but all I can do is say thank you from the bottom of my heart.

"Thank you for letting me live out my dream here every single night."

Wright finished the final game of his career 0-for-1 with a walk and a putout. His final out was a foul pop-up to the first baseman.

Trevor Richards walked him on six pitches in his first at-bat and Peter O’Brien made the final out of his career in the third inning looking hesitant to catch what he knew was a career-ending out in foul territory. He was then the target of an entire fan base’s collective angst and booed wildly the rest of the game.

There wasn’t much action after Wright exited. Steven Matz turned in a dazzling performance with six shutout innings of three-hit ball. He struck out eight and walked one and the two teams battled through a scoreless duel.

Daniel Zamora earned his first career win with a scoreless 13th inning and Jarlin Garcia (3-3) took the loss.

Richards gave the Mets chances and it looked as though they might score one for the captain in the first inning. Reyes doubled down the right side and took third on a sacrifice bunt to bring up Wright, who was walked.

With the old guard on the corners, it seemed like 2006 again for a brief moment. Michael Conforto’s double-play ball ended that moment too soon, much the way Wright’s career is ending.