I made my code simpler here but I think I have also narrowed down my question. name dosent equal main when this is run by mcedit as a filter, so are you supposed to compare name to something else other than main that its called by another program, making main PlaceBlock instead still didnt work either?
from multiprocessing import Process
from pymclevel import alphaMaterials
displayName = "PlaceBlock"
def perform(level, box, options):
x = box.minx
z = box.minz
def block(height):
level.setBlockAt(x, height, z, 1)
print(__name__)
if __name__ == "__main__":
print('Processing')
p1 = Process(target=block, args=(1, ))
p2 = Process(target=block, args=(2, ))
p1.start()
p2.start()
p1.join()
p2.join()
Also to answer a question in the comments, this a filter for a minecraft program called mcedit to edit worlds, filters are just programs that edit the worlds. So this program dosent actually do anything unless you have the program