Putting the 'Port' in Portal: Old-school fan brings game to Apple II

The cake is a IIe

Portal for the Apple II

Videos What do you get when you cross a 10-year-old game with a 40-year-old computer? The weekend at El Reg.

Vince Weaver, an assistant professor of computer engineering at the University of Maine, used his winter holiday to write a port of the beloved puzzle-driven snarkfest Portal for the Apple II.

"My wife got me the original Portal for Christmas, which I enjoyed playing," Weaver told The Register.

"I am horribly behind the times gaming-wise, in part because I am primarily a Linux user and as we all know, Linux isn't really known for its gaming culture."

Inspired by the ASCII-art final credits of the original game, Weaver set out to first recreate that sequence on the Apple II.

"That was going to be that, until I noticed that the blue/orange technology colors used in Portal matched very well to the hideous color palette available in Apple II hi-res color mode," Weaver told The Register.

"And one thing led to another."

Youtube Video

Over the course of about five days, Weaver said he was able to get an Apple II native version of the game working on his souped-up 1987 Apple IIe.

"I was surprised by how much gameplay could be implemented in BASIC and have it still be playable," he said.

"And a lot of neat Portal features and gameplay elements sort of fell out for free once you implement a minimal portal physics engine (and by 'physics engine' I mean the 5 lines of BASIC code that handle motion in the game)."

This is not Weaver's first crack at sending a game back in time. Last year he wrote an Apple II version of Kerbal Space Program.

Youtube Video

He notes that while writing for decades-old machines has a number of technical drawbacks, it does carry the advantage of four decades of troubleshooting.

Weaver reckons the entire process of development took about seven days (two for the credits sequence and five for the game itself), and while much of the work was done on a Linux box with emulators, final testing was done the old-fashioned way: with a five-inch floppy on the IIe.

"The nice thing about old platforms is that they are well documented, and there's a surprising amount of people hanging out on the internet who are willing to help out if you get stuck on some obscure 30-year-old issue," he says.

Screencap from Portal on Apple II

That said, Weaver notes that the game as it stands has a number of limitations. In addition to the unique challenges posed by the graphics system of the Apple II, the BASIC code can only handle so much before performance slows to a crawl. He says that adding more levels and features would likely require rewriting the entire project in 6502 Assembly code.

There's also the small matter of copyright.

"A lot of people would like it if I improved things to be a fast and fully playable hours-long game," he said. "I am not sure how faithful I could be to the original before Valve's lawyers become involved." ®

Are you or someone you know working on a vintage code project, computer science marvel, or other awesome idea? Are you a Valve legal rep who wants to give Vince the all-clear to expand his awesome Apple II port? In either case, get in touch.

Sponsored: The Joy and Pain of Buying IT - Have Your Say


Biting the hand that feeds IT © 1998–2017