Skip to Main Content
Adventures in Minecraft, 2nd Edition
book

Adventures in Minecraft, 2nd Edition

by David Whale, Martin O'Hanlon
November 2017
Intermediate to advanced content levelIntermediate to advanced
320 pages
6h 57m
English
Wiley
Content preview from Adventures in Minecraft, 2nd Edition
image

ONE OF THE great things about programming in Minecraft is that in addition to looking at your creations on a 2D screen you can actually bring them to life in a virtual 3D world. You can walk around them, go inside them, make them bigger—even blow them up if you like! By using the ideas originally created to display 3D objects on a 2D screen, you can code 3D objects in Minecraft, turning the ordinary into the extraordinary.

In this adventure you find out how to use the minecraftstuff module to create 2D lines and shapes, which, when combined with a little maths, allow you to program a clock so big you can stand on its hands as they go round (see Figure 6-1). After you have mastered creating 2D shapes, you then learn how to combine them to create enormous 3D structures in seconds.

image

FIGURE 6-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 ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

The Ultimate Player’s Guide to Minecraft, Third Edition

The Ultimate Player’s Guide to Minecraft, Third Edition

Stephen O’Brien
Minecraft Modding For Kids For Dummies

Minecraft Modding For Kids For Dummies

Sarah Guthals, Stephen Foster, Lindsey Handley

Publisher Resources

ISBN: 9781119439585Purchase book