If there is such a thing in baseball as a team forging an identity, a group spirit, as opposed to just random events thrown at the canvas Jackson Pollock-style for six months, the Giants might be building something.

Plucky survivors. Mix-n-match heroes. Something like that.

If so, if the current vibe holds over the long haul, Wednesday afternoon’s 9-4 win over the Padres provided two poster lads. And an enduring image.

The lads would be backup catcher Nick Hundley and returning-from-injury relief pitcher Will Smith.

Smith, out to pasture more than a year following Tommy John surgery, pitched a one-walk, no-hit seventh inning, whiffing two. Then he slapped his glove against his thigh in celebration.

In the dugout, Smith was greeted by Hundley, who handed Smith the baseball from the inning-ending strikeout and gave Smith a long hug. Welcome back.

After the game, there was a lot of noise from the clubhouse, shouting and loud music. Starting pitcher Derek Holland said later the party was in honor of Hundley, although Hundley modestly declined to discuss that detail.

“Oh, we were excited to win,” said Hundley, who, catching for the resting Buster Posey, got the party going with a homer, two doubles, a single and four runs.

The Giants are only 31 games into the season, 16-15 after Wednesday, but they wrapped up a 7-3 homestand and have won four series in a row.

This despite injury issues with their top three starting pitchers, their closer, their hot power-hitting hopeful (Mac Williamson), their second baseman and their left fielder.

There have been enough odd, semi-magical occurrences to give rise to a feeling that this team might be rocking some special mojo. Joe Panik’s homer-homer performance to open the season ... Andrew McCutchen’s six-hit and walk-off-homer game ... Brandon Belt’s 21-pitch at-bat ... Pablo Sandoval’s pitching debut ... Hundley’s walk-off single Monday night.

Speaking of Belt, the much-maligned Adolescent Giraffe (no longer a baby) is part of this feel-good story. He had a double, single and two walks Wednesday and continues to be an on-base machine and reliable power source.

Wednesday’s game, though, was a celebration of the has-beens and forgottens. Smith hadn’t pitched since the playoffs in 2016. And with the Giants’ pitching staff besieged, they were glad to see the big lefty.

And vice versa, squared.

Warming up, Smith said, “I was a little, like, ‘All right, it’s about to happen. This isn’t High A anymore. This isn’t Triple-A. Like, you’re back, you’re back in the big leagues. Let’s make some pitches and get out of here pretty quick.’”

Smith’s goal: “I wanted to, one, put up a zero, I didn’t want (manager Bruce Bochy) to have to come and get me or anything like that, I wanted to have a good first inning.”

From the outside, these comebacks can look purely clinical. Tommy John surgery, rehab for 13 months, back in uniform, yadda-yadda. But if you’re the man, it can be a bit emotional.

“Just to be able to play baseball again was a pretty incredible feeling I’ll probably never forget,” Smith said.

The baseball Hundley handed Smith in the dugout, come Thursday when the Giants are in Atlanta, will be presented to Smith’s parents, who live in Georgia.

Oh, the cold, heartless big leagues.

Hundley, who is 34, did a nice job as Posey’s backup last season. Then, a free agent, he waited around while the Giants did their rebuilding and restocking. When the dust cleared, they signed Hundley for another year, for not a lot over MLB minimum wage.

And he has been Nick Hundley-plus for them, batting .326 (career average .250) after Wednesday’s outburst.

Hundley said he and hitting coach Alonzo Powell had a nice session a couple of days earlier.

“We talked about a little something with my leg kick,” Hundley said, “and it really got me back to the swing where I felt like I could deliver a blow again.”

Several. Hundley singled home the first run in the first inning, doubled to open the third and homered in the fourth. He came to the plate in the sixth needing a triple to complete the cycle. Instead, he doubled to left-center. Obviously, he is a lousy situational hitter.

But he’s perfect to play a role in developing what could be a team identity of resilience and scrappiness. With all the injuries, it might be expected, even grudgingly accepted, for the Giants to sink in the standings, victims of fate and flawed planning.

Instead, they’re in the mix, with the makings of an interesting team identity, as battlers.

Not quite a classic crew yet. Not, say, the ’34 Cardinals, the Gashouse Gang, scruffy hustlers. But the potential is there for something intriguing.

Scott Ostler is a San Francisco Chronicle columnist. Email: sostler@sfchronicle.com Twitter: @scottostler