YORK — Plan A for the York High football team – Cullen McCarty running between the tackles – wasn’t working well. Falmouth’s big, physical defensive line was seeing to that.

No problem, said York Coach Randy Small. The Wildcats have multiple plans.

“If McCarty’s going to be taken away, we’ve got to go some other route,” Small said. “Offensively, we have that versatility that we can do that.”

Second-seeded York rallied three times Friday night, and senior quarterback Cole Merritt was a very credible Plan B, rushing for 177 yards and four touchdowns on 15 carries as the Wildcats earned a 34-19 win in a Western Class B semifinal.

“This is the most I’ve run by far,” Merritt said. “It was cool. That’s not usually my job. It’s up to Cullen and Jack (Neary), but it was cool doing that today.”

York (9-1) will travel to top-seeded Marshwood (10-0) for the regional final at 12:30 p.m. next Saturday. Marshwood beat York 41-12 in the final week of the regular season.

“And we’re excited,” Small said. “Just having the opportunity to get to go back over and play them, they’re a phenomenal team. They were that good beating us the first time, but I don’t think we’re that bad. They did everything right and we did nothing. We never got off the bus.”

Falmouth finished its best season with an 8-2 record. Connor Aube rushed for 180 yards and three touchdowns on 26 carries but was held in check after his 2-yard TD put Falmouth ahead 19-14 on its first drive of the third quarter. Noah Nelson completed 10 of 19 passes for 119 yards.

“With a good team like York, you have to choose your poison and last time McCarty really hurt us,” Falmouth Coach John Fitzsimmons said. “I thought we did a good job shutting him down.”

Merritt’s first score was a 1-yard sneak set up by his 28-yard run. His second touchdown was a 63-yard burst on a first-down draw play out of an empty backfield, giving York a 14-13 lead late in the first half.

Merritt added second-half scores of 6 and 18 yards, the latter sewing up the win with 3:41 to play. He also directed a nearly mistake-free offense (two penalties, no turnovers), completed 7 of 11 passes to help keep Falmouth honest, and used a hard snap to get Falmouth to jump offsides three times.

“When you’re a new program you make some of those mistakes, and those three offsides cost us dearly,” Fitzsimmons said.

Trailing 20-19, Falmouth moved 47 yards to the York 30 as the third quarter wound down, with Nelson completing three passes over the middle for a total of 43 yards. On third-and-1, he and Aube fumbled an exchange to lose a precious foot. On fourth down, Nelson bobbled the snap and was stopped short.

Aided by one of Falmouth’s offsides penalties, York went 70 yards in eight plays. With Falmouth’s defense focusing more on Merritt, McCarty (18 carries, 67 yards) sliced through a large crease over left tackle and sprinted for a 26-yard score.

York’s defense then came up with a rare three-and-out, and after a short punt the Wildcats drove 52 yards for the clinching score. Another offsides penalty on fourth-and-1 kept the drive going, and Merritt finished it with runs of 13 and 18 yards.