def create_block(mc, block_id, subtype=None):
    """Build a block with the specified id and subtype under the player in the
    Minecraft world.  Subtype is optional and can be specified as None to use
    the default subtype for the block.
    """
    # Get player tile position and real position.
    ptx, pty, ptz = mc.player.getTilePos()
    px, py, pz = mc.player.getPos()
    # Create block at current player tile location.
    if subtype is None:
        mc.setBlock(ptx, pty, ptz, block_id)
    else:
        mc.setBlock(ptx, pty, ptz, block_id, subtype)
    # Move the player's real positon up one block.
    mc.player.setPos(px, py+1, pz)
def create_block ( mc , block_id , subtype = None ) : ptx , pty , ptz = mc . player . getTilePos ( ) px , py , pz = mc . player . getPos ( ) if subtype is None : mc . setBlock ( ptx , pty , ptz , block_id ) else : mc . setBlock ( ptx , pty , ptz , block_id , subtype ) mc . player . setPos ( px , py + 1 , pz )
Build a block with the specified id and subtype under the player in the
    Minecraft world.  Subtype is optional and can be specified as None to use
    the default subtype for the block.