SOUTH PORTLAND — Jacob Brown, South Portland High’s 2015 valedictorian, talked about the importance of keeping your friends close in his graduation speech.

Seems appropriate.

Brown and several of his teammates on the Red Riots’ baseball team have been friends since Little League. When they were 12 and playing for the South Portland National All-Stars, they lost to Bangor for the state championship.

Bangor High, the defending Class A state champion, plays for the Eastern Maine championship Wednesday night. A few hours earlier, the Red Riots play for the Western Class A title.

Oh, the possibilities.

“We still have a chip on our shoulders from losing that Little League title,” said Brown, a right fielder. “It’s motivated us.”

For third-seeded South Portland (14-4) to get a shot at the state championship, it will need to beat top-ranked Portland (14-4) at 3 p.m. Wednesday in the regional final at St. Joseph’s College in Standish.

The Riots beat Portland 1-0 on May 21 as left-hander Henry Curran threw a one-hitter and struck out 14. South Portland also beat Portland two weeks ago in the finals of the SMAA playoffs. Curran will pitch against Portland on Wednesday.

On Saturday, in a wild Western A semifinal, South Portland beat Marshwood 9-8. Brown had a two-run double in the top of the seventh that cut the Hawks’ lead to 4-3. The Riots scored eight runs in the inning and then held on as Marshwood scored four.

On this occasion, Brown was patient at the plate waiting for the right pitch. It hasn’t always been that way. Brown cited games against Bonny Eagle and Biddeford where he was at the plate in key situations and struck out.

“I’m a pretty aggressive hitter,” he said. “Sometimes I’m too anxious at the plate. This time, I tried to relax and see the ball out of his hand. I wanted to get a fastball, it was right down the middle. I didn’t realize how big a hit it was until I looked at the scoreboard.”

Brown also had a single and a double in the game. Not bad for a player who Coach Mike Owens calls “unsung.”

Because of the wind at Wainwright Field, the Riots’ home, playing the outfield is a challenge. Owens said that in the five years he has been the head coach at South Portland, Brown is the best outfielder he has coached when you count all the intangibles.

“Jacob is never out of position. He’s thrown out guys at first base. He plays hard,” said Owens.

Brown had a 1.000 fielding percentage during the season. He tied for second in batting average on the team at .318. Brown led the team with two triples and 19 total bases.

Brown said summer baseball, practicing during the winter at a local indoor facility and playing AAU ball made him a better player.

South Portland got a big confidence boost when it rebounded to beat Marshwood 5-2 in the opening round of the SMAA playoffs. The Riots lost to Marshwood 11-1 on May 12 in a game that ended in the fifth because of the 10-run rule.

“The good news is that the players have been in every situation this season,” Owens said. “When we were down 4-1 in the seventh (in the semifinal), the players were still calm.”

Brown said the Riots are a close team that has helped them in tight games. For the Riots, it wouldn’t be the playoffs if the games weren’t close. They beat Biddeford 4-3 in eight innings in the quarterfinals. Last year, South Portland beat Cheverus in eight innings before losing to Marshwood in 11 innings.

“Everyone on this team hates to lose and we don’t want the season to end,” said Brown.

Brown said Owens’ coaching style has been a big reason for the team’s success.

“He encourages everyone on the team and praises you for good plays,” Brown said. “He values your opinion.”

Brown has learned to make good use of his time. For someone who plays three sports (he also plays soccer and basketball) and maintained a 97 grade-point average in the classroom, time is key. He also volunteered at Brown Elementary School, helping the students with math and reading.

“Having practices forces you to do your homework in the allotted time,” said Brown. “If I didn’t do that, I don’t know when I would have the time.”

Matt Beecher is one of Brown’s classmates who has played with him since Little League.

“Jacob is the hardest worker on the team,” said Beecher.

Beecher said his friend is not as quiet as he appears.

“He’s pretty funny. He tells great jokes,” Beecher said.

Brown will attend Boston College and is interested in studying biology and chemistry.

“I think I would like to be a biomedical researcher, but that could change,” he said.

Asked if he plans to play baseball for the Eagles, who play in Atlantic Coast Conference, one of the top conferences in the country, Brown shook his head.

“I think I would have to try out for the club team.”