Gamasutra: The Art & Business of Making Gamesspacer
View All     RSS
April 24, 2014
arrowPress Releases
April 24, 2014
PR Newswire
View All
View All     Submit Event





If you enjoy reading this site, you might also want to check out these UBM TechWeb sites:


 
PONKMORTEM
by Sos Sosowski on 04/30/13 09:57:00 am   Featured Blogs

The following blog post, unless otherwise noted, was written by a member of Gamasutra’s community.
The thoughts and opinions expressed are those of the writer and not Gamasutra or its parent company.

 

Sooo… I decided to make a game on a C64… And how did it go? Pretty awesome!

Making a game for a C64 and on PC is super simple and tons of fun! But Making a game on a real C64 is something else! One false move and BAH! your game is gone! There are no drives inside C64, everything that you are working on will die once you flip the power button. Moreover, there is no memory protection, so you can accidentally wipe out your code while it’s executing~!

 

The Setup

PC

I have been swapping around 3 C64s, because all of them have quirks.
- Top one is a C64 C with old motherboard and it had troubles with VIC IRQs
- The middle one I used the most, it seems to work fine, but old memory chips catch interference easily, so somehimes it swapped random bits in memory.
- The bottom one is a new 1993 C64C. It is super stable, but the video signal quality was too bad for streaming.

Storage

I never had a C64 disk drive so I’m super used to tapes. Fortunately I had this.

This is Black Box v8 a.k.a Quick Box, it has many cool features.

- Turbo Tape (25min vs 3min)
- Head Fit (a tool to visualise tape reads to help you setup head angle properly)
- Monitor (think of it as a C64 system debugger)
- Speech synthesis (polish only, but still!)
- Reset button (dev is impossible without this thing)

And to go with that I have my super cyborg Datassete.

Inside it, you can see a MP3<->JACK adapter. Basically, it’s a tape with a head inside connected to jack. This way you can easily Transfer games from T64 and PRG files onto a C64. Unfortunately, it only works one way.

I have also found an old blank tape! It is really neat! Back in the days, you could buy a tape specifically engineered for data storage, but I didn’t have that! But a blank tape works fine at all times! If it has music, it is good to wipe it beforehand.

As I said, C64 can be a pain when it comes to crashes. It can glitch out wiping itself randomly because you screwed something up. Fortunately, with this, saving was super neat, and since tapes are sequential I have so many old versions on it! You can easily do merges with old revisions with that!

HDMI

Previously, I had trouble with good C64 recording quality. But I made an S-Video cable and it all works fine.

Here is how it looked on my old cable.

This was hooked to a simple USB video grabber.

I used AMCap to work fullscreen and XSplit to stream that.

Here’s a quality sample of my environment.

Click images for full resolution.

This one is a screenshot of a game I abandoned to make PONK.

Tools that didn’t exist when I started.

I had to find a way to transfer stuff from C64 to PC since the tape adapter thing worked only one way. I had to make a transfer cable.

I used these to create XE1541 extended cable that only works with DOS and Linux. Setting up DOS on an SD was taking too much time so I had to find another way anyways.
I also had this neato helper to hold things for me.

The Citizen

The Citizen may have ruined buttons, but it can do HEX<->DEC conversions pretty well. This helped me out a big deal.

Also, it has the first known occurrence of the word ‘Sosowski’ on the back!

The Pro-cess

I got back from A-MAZE Indie connect in Berlin on Saturday morning after a long night drive and I woke up on Saturday evening. I started working on something but in the edn I decided to scrape it and start something smaller. I’m glad I chose to do that since I ended up with a 1kb large game and you’ll see how this was important later.

I was using the cartridge’s Turbo Tape functions to save often and monitor to write my code and do graphics.

Writing code on C64 is not like writing in a text editor or even like BASIC line numbers. You type your code directly into RAM and instructions are being assembled as you type. This way it is super simple to accidentally wipe out your entire game with a bug.

I wanted to make a platformer where you play as the platform first, but then I ended up with making a lunar buggy kind of racing game. When I woke up on Sunday I started making an XE1541 transfer cable.

When I finished, it was too late to finish my game so I started a new one. This time, I wanted to make PONG, because it’s super simple. The results were nice and fast!

I was finished and had time to polish, so I made a code snippet to wipe the screen contents before the game and quickly tested it. However, video memory was super close to where the game resided (like, 32 bytes apart) and I accidentally corrupted my game. The last save was from super long ago and I had to go through all the code and make it work again.

This is how it looked like. Random bytes swapped in random places. Moreover, I later realised that the Commodore has Alzheimer’s disease and forgets stuff if you work for too long. It was a lot of work but I managed to fix the code and had a working playable version, wooo!

It was all cool until I tried to copy the game onto PC!

The Copyright

First of all, I tried using the tape adapter to get the game on the PC! It was super simple and I had a high quality tape audio data dump soon after that. But it failed to work with any sound<->data applications since they require an audio record of the tape, not a data transfer record.

So I moved to using the cable I made!

But the cable required DOS or Linux installation to operate and no VM could do that for me. Setting this up took too much time, so I had another idea.

First, I rewound the tape and wanted to load the game and suddenly…

It couldn’t load! It seemed like the magnetic interference from my hardware wiped the tape! But in the end I realised that the cable I soldered is producing the interference and it all worked fine.

So I came up with another idea. I wanted to use one of my old ghetto-blasters to record audio from the tape so that it can be used with the conversion app.

But it appeared that neither of these had a working tape player. I had only 3 hours left so I decided to take screenshots of memory dumps on C64, and use OCR to read them! I used OneNote’s OCR feature (paste image, right click and copy test) but it was awful and in the end I had to proofread all 1024 bytes.

Then I wrote a simple C app that assembled a .PRG binary from the text and it magically worked!

I was really glad that the game is only 1kb. Also, it’s this small because it takes a lot of work to fill up memory on a C64, it was kind of not intended.

The End

I really like how PONK plays and it’s a very simple game. It also has a ball slow-motion mode wherer you can slow down the balkl by holding fire button. But two joysticks are XORed so if both players hold the button, it goes fast! This creates a really cool mechanic that makes you want to kill your opponent IRL.

In the end I took the code dumps from C64 and commented them to show you how simple C64 development is! You should totally try it out one day!

Click image to enlarge.

Making this was tons of fun!

Play PONK

Original article


Related Jobs

Crytek
Crytek — Shanghai, China
[04.24.14]

Mobile Programmer
2K
2K — Novato, California, United States
[04.24.14]

Senior Tools Programmer
Turbine Inc.
Turbine Inc. — Needham, Massachusetts, United States
[04.23.14]

Director, Analytics Platform Development
Gameloft Toronto
Gameloft Toronto — Toronto, Ontario, Canada
[04.23.14]

Technical Artist






Comments


TC Weidner
profile image
wow, I thought I was old school and stuff, but wow, this is truly crazy. nice

Maria Jayne
profile image
Ah the C64...(My brother had the one in the middle) I was only ickle when I first discovered playing cassette tape computer games on this machine. A time when you could begin loading a game and leave the computer for up to 20 minutes while it continued to beep and squeak as the internal modem translated the cassette tones into code.

20 minute load times and sometimes there was more loading per level or even if you died you might have to reload the entire game, because the RAM wasn't big enough to store enough of the game to restart. This was the machine that taught me patience, the experience that makes me scoff at today's gamers who say 60 seconds is a "long load time".... damn, I feel old now.

Raid on Bungling Bay, Ghost Busters, Daily Thompsons Decathlon, Football Manager, Pole Position 2, Kung Fu Master and High Noon....good times.

Pierre Xavier
profile image
C64 FTW! :D

Brandon Johnson
profile image
I wrote a Light Cycles game and a Tetris clone on my C64 WAAAAY back =D It was tons of fun and is primarily how I got into programming.

tony oakden
profile image
your mad! I love it :)

Kevin Reese
profile image
Wow S.S.S this is really quite something! Highly amusing c64 adventure you had there !

John Byrd
profile image
not sure if troll

Rey Samonte
profile image
Awesome! I tried getting back to my roots with the Vic-20 a few years ago. I purchased the Commodore monitor, unused floppy disk drive still with original packaging, and a Vic-20 from ebay. Unfortunately, the Vic-20 didn't work. :(

Really neat to see guys still mess around with this stuff!

Adrian Ludley
profile image
I have great memories creating games on the C64. Thank you for this trip down memory lane!
Games have come a long way since those days, and i will never forget my roots. :)


none
 
Comment: