BOSTON (TNS) — With the sun beating down on an 86-degree Wednesday afternoon in Boston, the Royals all stood with their backs to home plate as they watched a replay of Mookie Betts' second home run of the game soaring over Fenway Park's left-field wall.

All, anyway, but Royals left-handed pitcher Danny Duffy, who watched it live, muttering to himself and shaking his head.

As the ball cut through the air at 98 mph, it hugged the third-base line. It had the launch angle for a home run — 31 degrees — but it almost didn't seem Betts got enough of the pitch to drive it fair into the Green Monster seats.

After 5.1 seconds, it avoided hooking foul of the left-field pole. As Betts rounded the bases, the tie-breaking homer gave the Red Sox a fifth-inning advantage in what became a 5-4 Royals loss in the rubber match of a three-game series.

And the irony of this 22nd loss of the Royals season: Duffy should have been the Red Sox's kryptonite.

"Like I told Danny after the game, this is a tough club to make mistakes on," manager Ned Yost said. "Because they're going to make you pay. And Danny didn't make a lot of them. I thought he threw the ball really well. But just the two change-ups that he pulled back into the middle of the zone, they just hit it pretty good."

Duffy had things going for him. He was up against one of the best teams in baseball but the Red Sox had one flaw in their game. They entered Wednesday with baseball's worst batting average against left-handed pitchers. They had only clubbed four homers against lefties.

For three innings, Duffy played the part. He held the Red Sox to one hit and faced the minimum while tossing 31 pitches. The Royals offense, meanwhile, built a 3-0 lead despite Jorge Soler losing track of the number of outs in the first inning and the Royals batting 2 for 6 with runners in scoring position.

But in the fourth, Betts drilled his first home run of the game 452 feet to left field. Hanley Ramirez drew a walk two batters later, and scored when J.D. Martinez launched his own homer over the Green Monster. The Red Sox went 4 for 7 with three runs and two homers in the inning, and wound up adding five more hits against Duffy.

Betts set a Red Sox record while his team improved their worst stat. His 440-foot homer off Duffy in the seventh marked his fourth three-homer game in his career. In his fifth major-league season, he surpassed Ted Williams for most three-homer games in club history.

After Betts made his curtain call, Yost removed Duffy with two outs in the seventh. The ace of the Royals rotation remained winless for the season. The Royals, still searching for their first series victory of the year, fell to 8-22.

As Yost reflected on this convoluted beginning to his Opening Day starter's eighth major-league season, he didn't hesitate to praise Duffy's progress. Duffy may have the second-highest ERA (5.63) in the rotation but he's racked up a team-leading 34 strikeouts in 381/3 innings spanning seven starts. The chase rate on Duffy's slider has gradually improved, up 2.6 percent from last season's 30.7 rate through his first six starts of the season. In the same span, he'd mixed in his curveball 2.6 percent of the time, compared to just 0.9 in 2017.

The signs for a better outcome, Yost believes, are there.

"Today I thought it was the best stuff that he's had," he said. "He made a couple mistakes."

Duffy just needs the outs.

"That's all I'm searching for," Duffy said. "My stuff has been great. I've been busting my (butt) every freaking game. I'm tired of going out there and getting my (butt) kicked with great stuff. I don't know what else to say. It's nothing between the ears that's detrimental. There's nothing going on physically. I'm just not making pitches to get guys out. I'm sick of it."