ROCKLAND, Maine — Every victory in the Kennebec Valley Athletic Conference is satisfying this winter given the game-to-game grind in which blowouts are much more the exception than the rule among the league’s Class B programs.

Road wins are even sweeter, to which Nokomis of Newport will attest after outlasting Oceanside 48-46 on Thursday evening.

“This was a real good win for us,” said Warriors’ senior point guard Ruel Libby. “We just had to work hard tonight. They’re a good team, but we did what we had to do to win.”

Spencer Hartsgrove and Devin Chambers each made two free throws in the final 34.3 seconds to provide the decisive offense as Nokomis rebounded from back-to-back losses to Gardiner and Leavitt of Turner Center — teams with a combined record of 23-5 — to improve its own record to 9-4 and move up to fifth place in Eastern Maine Class B.

Story continues below advertisement.

“Hard work and intensity in the second half is really what helped us,” said Nokomis sophomore forward Andrew Cartwright, who contributed 10 points, 11 rebounds and four blocked shots to the victory. “In the previous games we didn’t come out with the intensity we had tonight, and that kept us in it and got us the win.”

Oceanside, which had won seven of its last eight games, falls to 9-5 and ninth place.

Nokomis held a narrow lead for most of the game, but Oceanside rallied to take a 43-42 edge on a 3-pointer by Isaiah Stone-Patterson with 2:09 remaining.

Nokomis regained a one-point edge as Hartsgrove made two from the line with 1:51 left, and when the Warriors got the ball back after an Oceanside miss, the Mariners — with just three team fouls — were forced to foul repeatedly to stop the clock.

By the time Nokomis was forced into the one-and-one, just 38.8 seconds remained. Ethan Pearl missed the front end, but Cartwright grabbed the offensive rebound, setting up two more free throws by Hartsgrove to give the Warriors a 46-43 lead with 34.3 seconds to play.

Oceanside then worked the ball inside, with Tyler Gilson scoring and completing a three-point play after being fouled on the back end of a pick-and-roll with 24.1 seconds left.

Nokomis worked the ball into the frontcourt and called time with 8.3 seconds left. Chambers was fouled on the subsequent inbounding play and made both free throws to give the Warriors a two-point edge with 7.4 seconds left.

Oceanside had one final chance, but a 3-pointer from the right of the key by Shea Davenport bounced off the left side of the rim as time expired.

Hartsgrove led Nokomis offensively with 13 points, while junior center Will Cartwright joined his younger brother with 10 points, including two 3-pointers.

Davenport scored 19 points for Oceanside, 14 in the third quarter. Stone-Patterson added 11 points while Sam Meklin had 10 points, 12 rebounds and four assists.

Neither team shot well, with Nokomis 18 of 51 (35 percent) from the field while Oceanside made 16 of 57 attempts, or 28 percent.

“Andrew did a better job on the boards tonight and we blocked some shots that may have kept them from looking inside as much later on,” said Nokomis coach Carl Parker.

Oceanside was at its most effective from long range, as the Mariners made 6 of 16 3-pointers while hitting just 10 of 41 tries from inside the arc.

“We got some good looks, but we’ve been in a little funk shooting the ball the last couple of games,” said Oceanside coach Matt Breen. “We got a lot of what we wanted, we just didn’t hit the looks and they did a good job of taking some things away. It comes down to hitting shots.”

Nokomis took a 7-0 lead 44 seconds into the game as Will Cartwright made a 3-pointer, Andrew Cartwright blocked a shot at one end and scored on a drive at the other end, and Will Cartwright converted a hook shot from the lane.

The game then settled into a defensive battle, with Oceanside taking brief leads of 12-11 and 14-13 early in the second quarter before Nokomis gained a 21-18 halftime edge.

The Warriors matched their biggest lead three times during the third quarter, the final time at 30-23 on a jumper from the lane by Ethan Pearl with 5:26 left.

But again Oceanside — the combination of the former Rockland and Georges Valley of Thomaston programs — rallied, this time behind Davenport, a junior guard who scored 12 straight points for the Mariners during one stretch, including a 3-pointer that pulled his team within 32-30 with 2:40 left in the period.

Nokomis rebuilt its lead to 40-34 when Libby and Chambers scored the first two baskets of the fourth quarter, but Oceanside countered with six straight — a free throw by Gilson, a 15-foot jumper by Meklin and a 3-pointer by Davenport — to forge a 40-40 tie with 2:59 left.