ANAHEIM, Calif. (AP) — For the second time in three days, the Los Angeles Angels took an early lead with a homer by Shohei Ohtani, only to give away the advantage when their pitchers faltered against Baltimore.

And for the second time in three days, the Angels got a walk-off hit that set off a celebration for a bunch that's determined to get more team success out of Ohtani's daily brilliance.

Ohtani hit his major league-leading 31st homer in the third, and Juan Lagares ended it with a two-run double in the ninth inning of the Angels' 6-5 comeback victory over the Orioles on Sunday.

Cedric Mullins hit a tiebreaking homer for Baltimore in the ninth after making his first All-Star team, but the Angels jumped all over Cole Sulser (2-1) without making an out in the bottom half.

After Los Angeles loaded the bases on a walk and two short singles, Lagares bounced a drive off the wall in right-center for his first career walk-off hit, putting the Angels back above .500 (42-41) with their sixth victory in seven.

“It’s becoming a common thing,” Angels manager Joe Maddon said. “I love it. There is no quit in this group. They’re always alive in the dugout. They’re always talking to each other. ... It’s just a wonderful vibe we’ve got going on. Just another game that we have that to-the-very-end kind of an attitude. It’s wonderful to be around.”

Ohtani tied the MLB record for the most homers in a season by a Japanese-born player when he drove a 459-foot solo shot to straightaway center off a low slider from Thomas Eshelman. It was Ohtani's 14th homer in 17 games overall.

With his drive over the ficus trees beyond the center-field fence, Ohtani matched Hideki Matsui’s major league record for homers by a Japanese slugger. Matsui did it over 159 games with the Yankees in 2004, while Ohtani only needed 81 games while also making 12 mound starts.

“I'm really excited to be at the same level with somebody I looked up to since I was young,” Ohtani said through his translator. “However, it's still the first half, so like I've said before, I want to continue to build up one hit at a time.”

Less than an hour later, Ohtani became the first player in major league history to be picked for an All-Star Game as both a hitter and a pitcher. He will also participate in the Home Run Derby.

“He’s definitely a special player in this league right now,” said Eshelman, who yielded seven hits over four innings and left trailing 4-0. “He’s doing things that have never been done before. For me to face a player like him is fun, but at the same time, I wish I would have buried that pitch."

Mullins delivered the tying RBI single as a pinch hitter in the sixth while Baltimore erased a four-run deficit, and he cracked a solo shot off the videoboard above the right-field fence in the ninth off Raisel Iglesias (6-3).

DJ Stewart had a two-run double for the AL-worst Orioles, who went 4-6 on their road trip.

“It’s a game we should have won,” Orioles manager Brandon Hyde said. “Really proud of our guys, how we battled back with some hitters. ... Pretty irritated right now. When we have the lead, with our record the way it is, it’s nice to win.”

Anthony Rendon also homered for Los Angeles in the third before leaving with left hamstring tightness.

Jared Walsh hit an RBI double shortly before he was named to his first All-Star team — part of a milestone-filled for the Angels in their first home game on July 4 in seven years.

Patrick Sandoval pitched two-hit ball into the sixth inning with seven strikeouts for the Angels, but he yielded five walks and faltered along with two relievers when Baltimore tied it in the sixth.

FLETCH'S FLOW

David Fletcher extended his hitting streak to a career-high 18 games with a double on Eshelman's first pitch. Fletcher’s streak is the Angels’ longest since Torii Hunter went 18 straight in August 2011.

HOLIDAY HOME

The Angels hadn't been at home on the Fourth of July since 2014 — also the year of their last playoff appearance. The Dodgers, who play 35 miles away, had been at home on this holiday every year from 2015-19, and MLB typically alternates homestands between the LA area's two teams.

TRAINER'S ROOM

Orioles: RHP César Valdez came off the injured list. He had been out since June 21 with a strained lower back ... LHP John Means allowed one hit — a homer — and had two strikeouts in two innings during his first rehab start for High-A Aberdeen.

Angels: The oft-injured Rendon left during a pitching change in the sixth. OF Taylor Ward then left for a pinch hitter to get his right index finger examined. Maddon said both players aren't seriously hurt, but are likely to sit Monday.

UP NEXT

Orioles: The Toronto Blue Jays visit Camden Yards on Tuesday. Baltimore hasn't announced a starter.

Angels: José Suarez (3-1, 1.98 ERA) returns to the rotation when LA opens a three-game series Monday at home against the AL-leading Boston Red Sox.

___

More AP MLB: https://apnews.com/hub/MLB and https://twitter.com/AP_Sports