LAS VEGAS — Had the Washington Capitals just looked out the window of their hotel suite, they would have seen Sin City in all its glory, bright lights and temptation for miles. Instead, their eyes were glued to the television screen, where an intense race between Princess Peach and Yoshi and Bowser was playing out.

“I played about four hours of Mario Kart,” defenseman Matt Niskanen said about the night before Game 1 of the Stanley Cup finals.

As the Capitals have traveled to four cities during this month-and-a-half-long playoff run, a Nintendo 64 video game console has made the trip with them. The night before a road game, players will gather in a communal hotel suite, blow into the gray game cartridge and pop it into the console. Then they’re off to the races.

The oddest link between the Capitals and the Vegas Golden Knights, opponents in this Stanley Cup finals, is each team’s reliance on the same old-school video game to kill time and keep loose on the road during a pressure-packed time of year.

“You can’t practice all day, every day,” Niskanen said. “You’ve gotta find something to do with your downtime. It’s funny, too, because I’m not a gamer at all, but I can’t get enough of that.”

The story of how Mario Kart, a game in which players race cartoonish avatars around a course, became a passion for two Stanley Cup finals teams began in Toronto’s Chinatown during last year’s postseason. The Capitals were about to play Game 3 of their first-round series against the Maple Leafs, and defenseman Nate Schmidt wanted to surprise his teammates. He and forward Paul Carey hailed a cab to a vintage video game store, and Schmidt used Washington’s fine fund — NHL locker rooms levy financial penalties to teammates for all sorts of wacky reasons — to purchase a Nintendo 64 and all of the accompanying accessories.

“It was actually pretty expensive — I’m not going to lie — but it wasn’t my money,” Schmidt said.

Schmidt, who has a Nintendo 64 of his own that he regularly plays in the summer, didn’t feel the need to play when his Capitals teammates waited to take a turn. “I had more fun watching all of the turmoil and all of the anger,” Schmidt said.

Because the console had been purchased with the fine fund, he thought it only fair that it stay in Washington even after he was selected by the Golden Knights in the expansion draft later that summer.

“I thought I would leave it so hopefully it would bring them to a place that’s here, I guess,” Schmidt said with a chuckle.

Again charged with managing his team’s fine fund, Schmidt started the same playoff tradition in Vegas, although he acknowledged that the Golden Knights aren’t “as intense.”

Capitals center Jay Beagle was eating dinner that first night Schmidt introduced the team to Mario Kart. He heard the familiar music jingle as the game started up and was reminded of how often he used to play against his brother and sister two decades ago.

When Pittsburgh Penguins forward Phil Kessel referred to Beagle as “an idiot” in the second round of last postseason, Beagle responded by jokingly challenging him to a game of Mario Kart — the first thing that popped into his head after having played the night before.

“I’m a natural racer,” Beagle said.

His teammates agree.

“Beags is one of those guys that he comes in for five games, he’ll win four of them, and then he’ll leave,” forward Brett Connolly said.

The Capitals’ Mario Kart regulars are mostly the team’s veterans, perhaps because the game predates some of Washington’s younger members. Alex Chiasson said he’d classify himself as the “most improved” player since the start of the playoffs. T.J. Oshie, who naturally elects to use the avatar named Yoshi, got so into the game that he bought a Nintendo 64 for his home.

“That’s news to me,” Beagle said. “And that’s why he’s improving at an insane rate. That’s garbage. I’m going after him now.”

The Capitals are 8-3 on the road this postseason after dropping Game 1 against the Golden Knights on Monday, and the team has appeared relaxed on the road, a noticeable difference from years past. It’ll need to maintain that demeanor Wednesday night, when it aims to tie the series in a raucous T-Mobile Arena. Meanwhile, Vegas has lost just two road games in defying every expectation with a Stanley Cup run in its inaugural season.

Perhaps emblematic of what has made both teams surprisingly successful in these playoffs is that they have been gripping their game controllers tighter than their hockey sticks.

“We do keep it loose, but at the right times, too,” Beagle said. “We’re also focused and dialed in, and keeping it loose, it allows you to have fun with it and realize this is a game and this is an opportunity that you only get once in a lifetime.”