Functii

Fisier Python (trebuie pus in folderul sitas)

import mcpi.minecraft as minecraft
import mcpi.minecraftstuff as minecraftstuff
import mcpi.block as block
mc = minecraft.Minecraft.create()
mcdrawing = minecraftstuff.MinecraftDrawing(mc)
def tunel():

for x in range(75,105,2):

mc.setBlock(x,4,-543,70)
mc.setBlock(x,4,-544,55)
mc.setBlock(x,4,-542,55)
for x in range (75,105):
mc.setBlock(x,4,-545,123)
mc.setBlock(x,4,-541,123)
mc.setBlock(x,5,-545,123)
mc.setBlock(x,5,-541,123)
mc.setBlock(x,6,-542,123)
mc.setBlock(x,6,-544,123)
mc.setBlock(x,7,-543,123)

def tunel1(z):

for x in range(75,105,2):

mc.setBlock(x,4,z,70)
mc.setBlock(x,4,z-1,55)
mc.setBlock(x,4,z+1,55)
for x in range (75,105):
mc.setBlock(x,4,z-2,123)
mc.setBlock(x,4,z+2,123)
mc.setBlock(x,5,z-2,123)
mc.setBlock(x,5,z+2,123)
mc.setBlock(x,6,z+1,123)
mc.setBlock(x,6,z-1,123)
mc.setBlock(x,7,z,123)

tunel1(-520)

Leave a comment