Back to Contents Page Lesson 2

Exercise Sheet: Working with Functions with Minecraft Pi Edition API Mark Scheme

 

1) import block

import minecraft

import minecraftturtle

 

playerPos = minecraftturtle.MinecraftTurtle(mc, pos)

playerPos.forward(30)

 

1 mark for:

 Importing correct libraries

 Including using correct function from minecraftturtle library

2 marks for:

 creating the line and making it 30 bocks long

 

2) import block

import minecraft

import minecraftturtle

 

playerPos = minecraftturtle.MinecraftTurtle(mc, pos)

playerPos.up(30)

playerPos.forward(40)

 

1 mark for:

Importing correct libraries

Including using correct function from minecraftturtle library

2 marks for:

Creating the 40 blocks  at 30degress

 

3) import block

import minecraft

mc.setBlock(1,2,4,block.WOOL.id.10)

 

1 mark for:

Importing correct libraries

Including using correct function from minecraftturtle library

2 marks for:

Including the line mc.setBlock(1,2,4,block.WOOL.id.10)

 

4) import block

import minecraft

mc.setBlock(2,2,2,block.SANDSTONE.12)

 

1 mark for:

Importing correct libraries

Including using correct function from minecraftturtle library

2 marks for:

Including the line mc.setBlock(2,2,2,block.SANDSTONE.12)

 

Challenge Question acquires no marks, however it can be used as an idea for a competition. Whereby the person that creates the most interesting (based on votes by peers) block wins.