Raspberry Pi For Dummies, 4th Edition
Book image
Explore Book Buy On Amazon
Pygame Zero lays down strict rules about what your files can be called and where they should be saved on your Raspberry Pi. Filenames must be in all lowercase, which helps to ensure that they work across different computers. Your images must be stored in a folder called images, and your sounds in a folder called sounds.

Let's set up those folders now. Follow these steps:

  1. In the desktop environment, click the taskbar’s File Manager icon.
  2. In the pi folder, right-click, and then choose Create New →   Folder from the contextual menu that appears.
  3. Name your folder images.
  4. Repeat Step 2, but this time name your new folder sounds.
  5. Copy your image files into the images folder, and your sounds into the sounds folder.
Remember that when you download files with your web browser, they will be saved in your Downloads folder, which is also in your pi folder. You may need to extract them from a .zip file, by double-clicking the .zip file and then clicking the Extract Files button when Xarchiver opens. After extracting the files, you can copy them to the images and sounds folders.

About This Article

This article is from the book:

About the book authors:

Sean McManus is an expert technology and business author. His previous books include Mission Python, Coder Academy, and Cool Scratch Projects in Easy Steps. Mike Cook is a lifelong electronics buff, a former lecturer in physics at Manchester Metropolitan University, and the author of more than 300 articles on computing and electronics. You'll often find him monitoring technology forums under the moniker Grumpy Mike.

This article can be found in the category: