A pulsating Scottish Division One match between Kilmarnock and Raith Rovers was finely poised at 3-3 as the sun began to set behind the old Rugby Park. The 1,436 fans scattered around the ground on 12 September 1987 scanned the pitch for a potential hero. Sometimes heroes are the unlikeliest figures.

With the clock running down, Raith Rovers’ veteran goalkeeper, Hamish McAlpine, launched a kick from his own penalty area towards his opposite number, Barry Holland, in the Killie goal. Incredibly, the ball bounced once and flew beyond his baffled opponent into the back of the net. As the Raith Rovers fans celebrated, McAlpine looked on in bewilderment as he tried to figure out what had happened. Astonishment soon turned to joy and, in typical McAlpine style, he celebrated by lifting his boot up for one of his fellow defenders to kiss. The unlikely goal was not so joyful for the man on the receiving end. Holland was dropped for the following match and only made one more appearance for Kilmarnock.

McAlpine was an alluring individual and a fans’ favourite at all of his clubs. During 22 seasons as a pro he represented Dundee United, Montrose, Dunfermline, Raith Rovers and Arbroath. He won two Scottish League Cups, a Premier Division title and was even voted Football Writers’ Player of the Year in 1985 at the age of 37. He was a real character and would often bring a smile to the supporters’ faces by having a swing on the crossbar during dreary passages of play. His sense of fun, along with his goalkeeping prowess, led Dundee musician Michael Marra to compose a song about him.

When the ball nestled in the back of the net on that autumn afternoon in 1987, McAlpine had added another feat to his long list of achievements. He had extended his own somewhat quirky Scottish goalkeeping record: it was the fourth goal of his career – more than any other keeper in the history of Scottish football. So, how did a keeper rack up four goals when he was employed to prevent them? A big factor in his scoring record was his eagerness to take penalty kicks. In fact, his goal tally could have been even higher.

It’s often said a goalkeeper is under under no pressure when a referee awards a penalty kick. The expectation is usually on the outfield players. Unless you are McAlpine. Until 28 April 1976, he was a bog-standard keeper, doing his bit between the sticks, saving, blocking, catching and clearing shots. However, when Dundee United played Hibs in their final home match of the 1975-76 season, they were on the back of a terrible run of missed penalties, having failed to convert six spot kicks in the campaign. When the referee pointe to the spot in the 13th minute, there wasn’t a mad rush of players volunteering to take it.

There were gasps from the Tannadice crowd as McAlpine left his goalmouth and set off up the pitch to solve the problem. The captain took responsibility and slammed the penalty high into the net for the first goal of his career. Although manager Jim McLean never hid his preference for outfield players to take penalties, he reluctantly gave McAlpine the job after his successful first attempt.

A week later, in Dundee United’s final match of the 1975-76 season, they went to Ibrox needing at least a point to stay in the Premier Division. McLean was four years into his career at the club and relegation would have been a major setback. They may not have gone on to enjoy the success they did in the 1980s had they not collected a point at Ibrox that day. So when United were awarded a penalty during the game, the keeper raced forward again to claim the kick. This time however, McAlpine’s effort struck the post and he had to race back to stop Rangers taking advantage. He got away it and kept a clean sheet in a 0-0 draw as United picked up the point they needed to stay in the top division.

The charismatic keeper went on to score two more penalties the following season against Hibs in September and Rangers in February. The latter came as United came back from 2-0 down to win by the odd goal. With United trailing 2-1 in the second half, John Greig pulled down Gordon Wallace in the box and once again the keeper made the journey from his goal. Rangers keeper Stuart Kennedy dived wrong way and McAlpine had the third goal of career goal.

The obvious disadvantage of having your goalkeeper at the wrong end of the pitch during a game was not lost on McLean. The manager grudgingly accepted the risks involved; unsurprisingly he had to endure a few scary moments. McAlpine liked the responsibility and enjoyed seeing his name on the scoresheet but his honour was to be short-lived as, between his successful conversions, he missed a further four penalties within a year. He eventually missed more penalties than he scored.

McAlpine missed two penalties in the same game against Ayr United in September 1976. United still ran out comfortable 4-1 winners at Somerset Park despite his incredible double miss. In the opening 10 minutes his first penalty was saved by Hugh Sproat. When United were awarded another penalty just before half time, McAlpine wasn’t going to pass the baton to a team-mate so he stepped up again, aiming to make amends. Unfortunately he failed for a second time, firing the ball high over the bar. The writing was on the wall for his career as a spot-kick specialist.

Rose Reilly: the only Scottish footballer to win the World Cup ... as Italy captain Read more

His last penalty attempt came against Celtic in a 2-0 defeat for Dundee United at Parkhead in March 1977. McAlpine came up against a debutant keeper Roy Baines, who was drafted in to the side after Celtic’s regular keeper Peter Latchford suffered an ankle injury. With 25 minutes on the clock, the referee pointed to the spot after Paul Hegarty was fouled by Danny McGrain. Baines tried to psyche out McAlpine by turning his back on the United man as he was about to run up. McAlpine paused his run and, when he eventually struck his shot, the Celtic keeper made a fine save. McAlpine had to race back up the park frantically as the home fans roared for Baines to clear the ball upfield. The brazen but quick-thinking United striker Tom McAdam grappled Baines to the ground, deliberately conceding a free-kick to give McAlpine enough time to scurry back to his own goal.

That was the last penalty kick taken by McAlpine and it was 10 years before he would find the net again. Aged 39, the kick-out that flew the length of the pitch and settled in the back of the net at Rugby Park put the icing on the cake for what was a wonderfully successful career. McAlpine is now back at Tannadice, having been appointed a club ambassador in 2014. With a seat for life, the legendary goalkeeper represents the club at all home games. Having made 688 appearances for the United over 18 years, he certainly deserves the role. For the time being, his goalscoring record looks as comfortable as he did hanging from the crossbar.

• This article is from issue five of Nutmeg magazine

• Follow Nutmeg and Graeme Webster on Twitter