Hardware Reference
In-Depth Information
MINECRAFT APPEALS TO the Lego fan in everyone. It enables you to build immersive 3D
worlds from blocks of materials, and it's ired up imaginations to the extent that an esti-
mated 20 million copies have been sold across platforms including the PC and Xbox.
An early development version of Minecraft is available for the Raspberry Pi. It features only
the creative mode, where you can build things peacefully without the threat of monster
attacks or starvation, but it has one neat twist: You can program it using multiple languages,
including Python. his means that you can build a grand palace without having to manually
place every block, and can write programs that can invent original new structures for you to
roam around and explore, as you'll see in this chapter.
his project uses a Python program to build a maze in Minecraft. Each time you run the pro-
gram, it will build a new maze for you, and you can control how big you want it to be and
which materials you want it to be made of. During the course of this project, you'll learn how
to place and remove blocks in Minecraft using Python, so you'll have the skills to write your
own programs that supercharge your construction work.
At the time of writing, Minecraft: Pi Edition is alpha software, which means that it's a very
early test version (less well developed than a beta version). I had only a couple of minor
issues with it: he window and its content were strangely aligned using a screen resolution of
1024 x 768 (so I switched to 1280 x 1024), and the cursor misbehaved when I maximised the
window. Nevertheless, I recommend that you always back up any important data on your
Raspberry Pi when you use any alpha software, just in case something goes wrong.
The easiest way to back up iles on your Raspberry Pi is to connect a USB storage device and
use the File Manager in the desktop environment to copy them across.
You can download the code for this chapter from my website at www.sean.co.uk .
Installing Minecraft
Although Minecraft is distributed commercially on other platforms, the Raspberry Pi alpha
version is free to download. To use it, you'll need to have the Raspbian Wheezy version of
Linux on your Raspberry Pi. It's the operating system version recommended by the Raspberry
Pi Foundation, and you can install it using the New Out of Box Software (NOOBS) image
available through the Downloads section at www.raspberrypi.org . For help with install-
ing the operating system, see Chapter 1, “Getting Your Raspberry Pi Up and Running”.
 
Search WWH ::




Custom Search