skip navigation

Building Your Playfield on an Atari 2600


In this episode we go deeper into scan lines and their ‘ideal’ numbers, and also the design and programming of the ATARI 2600 playfield to create interesting and appealing games. We also explore how some commercial games designed their own playfields and all the different components involved in the creating rich worlds within a restricted environment.

May 19, 2021

Original Link:


Your support is greatly appreciated!

Welcome back everyone!

In the last episode we talked about drawing the playfield, and all the fiddly bits involved in that process. Today we’ll continue talking more on that topic, the timings involved in generating a stable screen, and differences between how the screen is rendered on a CRT television verses. the Stella emulator. So, let’s start with that.

As we’ve covered in a previous video, an Atari 2600 uses 192 of the total scanlines on an NTSC CRT television to display your game, and 242 scanlines on a PAL CRT television.. but that’s not entirely true. That’s actually just the recommended number to use for your playfield. The Truth is, besides the three scanlines of vertical sync, You can generally use the rest anyway you want, but there could be some issues. Just because your drawing scanlines doesn’t mean the television will be able to display them. 192 scan lines is just the recommended number because it’s generally considered to be a safe visual space for most of the CRT’s in existence. In fact, all these numbers are just suggestions, if you want to add a few more or less scanlines to your playfield, go ahead. Especially if you are only targeting your game for emulators. Emulators will display everything you give them because they don’t suffer from hardware limitations. Real CRT’s however could become increasingly unpredictable the more you stray from the safe numbers, but you as the programmer can do your own risk assessment.

It’s not uncommon for commercial games to stray a little from safe numbers. Generally it’s safe to produce 262 total scanlines, with 192 of those being the playfield… and generally positioned somewhere near the center where CRT’s usually have their displayable areas. Lucky for us, the Stella emulator can display the total number of scan lines a game is generating so we can see what we’re dealing with. Let’s open that up and run one of our example programs for this video which is linked below.

Here you can see that we’re generating 262 total scanlines… and we have the blue box oriented in the recommended safe zone, with two periods of Vertical blank as shown by the black bars at the top and bottom. Now let’s look at a few commercial games and see what they are generating.

Here we have Combat, one of my favorite games, and made by Atari in 1977. They’re generating a total of 263 scanlines. So they’re well within the safe zone.

Galaxian, another Atari game made in 1983, also use 263 scanlines

Buck Rogers, a game made by Sega in 1983 has variable scanlines. The title screen itself sports 240 scanlines… and the most annoying sound on earth.
When starting the game, the level introduction pushes out 249 scanlines, and then switches to our safe 262 scan lines during actual game play.

This doesn’t account for the limited visible area of the screen. As we know, the safe zone on a CRT is the 192 scanlines somewhere in the middle, but many of the earlier CRTs were very curved, and had large rounded corners, so you wouldn’t want to display any important information on that portion of the screen because it could be cut of or obscured. Later CRT had more square corners which allowed you to increase the visible portion of the playfield. However, doing so would make the game less player friendly on those older tv sets. These days, CRT’s are uncommon enough, and earlier CRTs even more so. So when making your playfield, keep your target audience in mind, and design for what works for them.

I’ve included a few more basic examples demonstrating more of the playfield.

In the first example we’re drawing a border around the safe visual portion of the screen. While the top and bottom area are much thicker than the side border. On a real CRT the top and bottom area would generally show up as the same thickness as the sides. Since we can’t know how many scan lines are visible on our CRT, you can extend your background color or playfield in order to make the playfield look larger than it actually is. For example, if your game has a blue sky, then just set the background color to blue at the beginning of the frame, and if the top portion needs to be used for collision detection, then just draw solid lines of playfield pixels. That way, even though a lot of it won’t be visible on the screen, you generate a nice clean edge to edge playfield. And because the TIA will continue drawing whatever was last written into the registers, you don’t have to do any additional work or waste machine cycles.

However, if what you’re looking for is a boxy border, example two demonstrates how we can draw a true box around our playfield. It’s a little boring now, but add some tanks and missiles in there and you have yourself a hit game. Speaking of Tanks, example three shows another feature of the TIA playfield registers used in the game Combat. In this case we use the player color registers to set our payfield pixels to be different colors on each side of the screen. By using this technique, we don’t need to manually change color half way through drawing each scan line, the TIA will do that for use.

Now that we have a few examples under our belt, and we know a few tricks to use when drawing the playfield for a game, let’s have a look at what the professionals have done and see if we can figure out how their playfields were created. Since we’ve already talked about the game Combat a couple times, let’s have a look at it’s playfield.

As you can see the play field for is box like we’ve see in one of the example we looked at, and if we overlay some lines on the screen to represent where the 40 pixel are displayed on the screen, we can clearly see the walls are drawn in mirror mode using the 20 PF register pixels.

Now let’s have a look at Pitfall, a game made by Activisionn in 1982.

Right away, the only obvious use of the pixel can be seen with the placement of the tree trunks. We can see that the playfield is all in mirror mode as well. That’s not to say that the entire screen has to be in mirror mode, this can be switched with every scan line if you choose to do so,.. But in the case of Pitfall, it works well due to the variety of screens in quick succession. Let’s break down what’s happening on the screen a little more.

If we isolate each area of the screen we can figure out how the playfield is built.

Let’s start at the top of the screen. For now we’ll skip past the score and timer and revisit that in another video. Here we can see that the entire top of the screen is made up of either solid green pixels or a green background. This represents the top of the trees well, and remains this way on all of the different screens.

Right below that section is a thin strip to create a wavy pattern to represent the bottom of the leaves, and include some sprites to make use of higher resolution to draw the bottom of the tree branches.

As we’ve seen before, the tree trunks are just two pixels on a mirrored playfield giving us four trees with a bright green used for the playfield background.

Next is the surface area, and again it uses a yellow background color and a black or blue playfield color to build the pits and water holes. The ground is made up of a brown background with black pixels to help represent any holes visible on the surface, and for the ladder I believe it used the higher resolution sprites to draw the ladder.

The underground area is all black, except for the occasional ladder, or wall. With the wall being made up of two red pixels which are changed to gray on certain scan lines, and some black sprites to separate the bricks.

Moving down, we have a solid brown area to represent the surface of the underground which never changes, and below that, the Activision Copyright animation.

These screens are both simple and complex, they’re created using simple methods that are easy and quick to draw, but show it’s complexity in the creative way each area of the screen is built.

One interesting item that you might have missed at first glance is the two pixel wide black bar on the left side of the screen. This was actually used in many of the Activision games to cover up a flaw in the way the TIA draws a scanline after a horizontal move was done. In some cases this may produce some black lines on the left side of the screen. This can be avoided in many cases, but Activision chose to obscure the problem by making that entire area black. This can be seen in many other Activision games. Personally, I think this was a great way to solve the problem, and doesn’t take away from the quality games they produced for the 2600.

One thing I think it’s important to point out here is the sheer size of the world in Pitfall, it’s amazing that it manages to fit in 255 screens in the limited memory space available on the 2600. I won’t go into more detail about that in this video, but a user on reddit has written a great article describing how it was done. I’ve added a link down in the video description if you’d like to check it out.

And… Well, that’s all I have for you today. I hope you found this interesting, and the examples useful. As always, the code for the example can be found on our GITHUB which is linked in the description below.

Please help out the channel by liking, commenting, and sharing this video, and if you’re new here, or have not already done so, please consider subscribing to the channel to keep in touch.

Thanks for watching, and I’ll catch you next time.

Back to top of page