Hardware Reference
In-Depth Information
FIGURE.7-1 A massive Minecraft clock
The minecraftstuff Module
minecraftstuff is an extension module to the Minecraft API, which was written
for Adventures in Minecraft, and contains all the code you need to draw shapes and
control 3D objects. It has a set of functions called MinecraftDrawing , which allows
you to create lines, circles, spheres and other shapes. Because this complicated code is
in a separate module it makes it simpler for you to create the code, and it's easier to
understand too. Modules are a way of splitting up a program into smaller chunks.
When programs get too big they are more difficult to read and harder to understand,
and it takes longer to track down problems.
he minecraftstuff module is included in the “Adventures in Minecraft” starter kit
available on the topic's companion website at www.wiley.com/go/adventuresinminecraft
and can be imported to a Minecraft program in the same way as the minecraft and
block modules.
Creating Lines, Circles
and.Spheres
When you combine a lot of small, simple things, you can create something as large and
complex as you want. In this adventure, you're going to use lots of lines, circles, spheres
and other shapes to produce a really big Minecraft structure. In this part of the adven-
ture, you will create a new program, import the modules you need and set up the
minecraft and minecraftdrawing modules. Later, you'll use the functions in the
modules to draw lines, circles and spheres.
 
Search WWH ::




Custom Search