louis-e / arnis

Arnis - Generate cities from real life in Minecraft using Python
GNU General Public License v3.0
260 stars 18 forks source link

all chunks are corrupt from any export, the worlds are unstable #38

Open DanHues opened 4 weeks ago

DanHues commented 4 weeks ago

So, when importing the world with two separate multiworld management plugins on a spigot server and attempting to import the world in worldpainter I am getting issues with corrupt region data, this happens on all export types, box exports and citywide exports,

you can reproduce this error by going into a exported world and seeing your latest log output thousands of messages a second about chunk location errors, im assuming this is because the export command requires a existing world to overwrite the chunks which is causing the world to assume the chunks are in the wrong location causing the error


[00:14:14] [Server thread/ERROR]: Chunk file at [460, 760] is in the wrong location; relocating. (Expected [460, 760], got [12, 24])
[00:14:14] [Server thread/ERROR]: Chunk file at [450, 761] is in the wrong location; relocating. (Expected [450, 761], got [2, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [465, 760] is in the wrong location; relocating. (Expected [465, 760], got [17, 24])
[00:14:14] [Server thread/ERROR]: Chunk file at [467, 760] is in the wrong location; relocating. (Expected [467, 760], got [19, 24])
[00:14:14] [Server thread/ERROR]: Chunk file at [451, 761] is in the wrong location; relocating. (Expected [451, 761], got [3, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [468, 760] is in the wrong location; relocating. (Expected [468, 760], got [20, 24])
[00:14:14] [Server thread/ERROR]: Chunk file at [452, 761] is in the wrong location; relocating. (Expected [452, 761], got [4, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [463, 760] is in the wrong location; relocating. (Expected [463, 760], got [15, 24])
[00:14:14] [Server thread/ERROR]: Chunk file at [453, 761] is in the wrong location; relocating. (Expected [453, 761], got [5, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [455, 761] is in the wrong location; relocating. (Expected [455, 761], got [7, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [454, 761] is in the wrong location; relocating. (Expected [454, 761], got [6, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [456, 761] is in the wrong location; relocating. (Expected [456, 761], got [8, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [457, 761] is in the wrong location; relocating. (Expected [457, 761], got [9, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [459, 761] is in the wrong location; relocating. (Expected [459, 761], got [11, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [458, 761] is in the wrong location; relocating. (Expected [458, 761], got [10, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [460, 761] is in the wrong location; relocating. (Expected [460, 761], got [12, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [463, 761] is in the wrong location; relocating. (Expected [463, 761], got [15, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [461, 761] is in the wrong location; relocating. (Expected [461, 761], got [13, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [462, 761] is in the wrong location; relocating. (Expected [462, 761], got [14, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [464, 761] is in the wrong location; relocating. (Expected [464, 761], got [16, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [467, 761] is in the wrong location; relocating. (Expected [467, 761], got [19, 25])
[00:14:14] [Server thread/ERROR]: Chunk file at [468, 761] is in the wrong location; relocating. (Expected [468, 761], got [20, 25])``` 
daniil2327 commented 4 weeks ago

I know about this bug and I also tried to run the server with the same error, I tried to run it through worldpainter but nothing worked, I think that this is a problem with anvil parser or with the code associated with it

amir16yp commented 4 weeks ago

Having the same issue on singleplayer, but the city renders fine anyway. here's the log latest.log

louis-e commented 4 weeks ago

Singleplayer seems to be working fine every time, but I already noticed Minecraft detecting some problems. image

Not sure if it might help, but we can look into updating the anvil package to this continued development fork: https://github.com/Intergalactyc/anvil-new

amir16yp commented 4 weeks ago

Singleplayer seems to be working fine every time, but I already noticed Minecraft detecting some problems. image

Not sure if it might help, but we can look into updating the anvil package to this continued development fork: https://github.com/Intergalactyc/anvil-new

i'll try replacing the package and see if it changes anything.

amir16yp commented 4 weeks ago

Singleplayer seems to be working fine every time, but I already noticed Minecraft detecting some problems. image Not sure if it might help, but we can look into updating the anvil package to this continued development fork: https://github.com/Intergalactyc/anvil-new

i'll try replacing the package and see if it changes anything.

i changed the package and not much has changed. since this one doesnt have the Block.from_id function, i had to adjust the block definitions


import anvil

air = anvil.Block("minecraft", "air")
birch_leaves = anvil.Block("minecraft", "birch_leaves")
birch_log = anvil.Block("minecraft", "birch_log")
black_concrete = anvil.Block("minecraft", "black_concrete")
blue_flower = anvil.Block("minecraft", "blue_orchid")
brick = anvil.Block("minecraft", "bricks")
carrots = anvil.Block("minecraft", "carrots", {"age": 7})
cauldron = anvil.Block("minecraft", "cauldron")
cobblestone = anvil.Block("minecraft", "cobblestone")
cobblestone_wall = anvil.Block("minecraft", "cobblestone_wall")
dark_oak_door_lower = anvil.Block("minecraft", "dark_oak_door", {"half": "lower"})
dark_oak_door_upper = anvil.Block("minecraft", "dark_oak_door", {"half": "upper"})
dirt = anvil.Block("minecraft", "dirt")
farmland = anvil.Block("minecraft", "farmland")
glass = anvil.Block("minecraft", "glass_pane")
glowstone = anvil.Block("minecraft", "glowstone")
grass = anvil.Block("minecraft", "grass")
grass_block = anvil.Block("minecraft", "grass_block")
gravel = anvil.Block("minecraft", "gravel")
gray_concrete = anvil.Block("minecraft", "gray_concrete")
green_stained_hardened_clay = anvil.Block("minecraft", "green_terracotta")
hay_bale = anvil.Block("minecraft", "hay_block")
iron_block = anvil.Block("minecraft", "iron_block")
light_gray_concrete = anvil.Block("minecraft", "light_gray_concrete")
oak_fence = anvil.Block("minecraft", "oak_fence")
oak_leaves = anvil.Block("minecraft", "oak_leaves")
oak_log = anvil.Block("minecraft", "oak_log")
oak_planks = anvil.Block("minecraft", "oak_planks")
podzol = anvil.Block("minecraft", "podzol")
potatoes = anvil.Block("minecraft", "potatoes", {"age": 7})
rail = anvil.Block("minecraft", "rail")
red_flower = anvil.Block("minecraft", "poppy")
sand = anvil.Block("minecraft", "sand")
scaffolding = anvil.Block("minecraft", "scaffolding")
sponge = anvil.Block("minecraft", "sponge")
spruce_log = anvil.Block("minecraft", "spruce_log")
stone = anvil.Block("minecraft", "stone")
stone_block_slab = anvil.Block("minecraft", "stone_slab")
stone_brick_slab = anvil.Block("minecraft", "stone_brick_slab")
water = anvil.Block("minecraft", "water")
wheat = anvil.Block("minecraft", "wheat", {"age": 7})
white_concrete = anvil.Block("minecraft", "white_concrete")
white_flower = anvil.Block("minecraft", "azure_bluet")
white_stained_glass = anvil.Block("minecraft", "white_stained_glass")
yellow_flower = anvil.Block("minecraft", "dandelion")

# Variations for building corners
building_corner_variations = [
    anvil.Block("minecraft", "stone_bricks"),
    anvil.Block("minecraft", "cobblestone"),
    anvil.Block("minecraft", "bricks"),
    anvil.Block("minecraft", "mossy_cobblestone"),
    anvil.Block("minecraft", "sandstone"),
    anvil.Block("minecraft", "red_nether_bricks"),
    anvil.Block("minecraft", "blackstone"),
    anvil.Block("minecraft", "smooth_quartz"),
    anvil.Block("minecraft", "chiseled_stone_bricks"),
    anvil.Block("minecraft", "polished_basalt"),
    anvil.Block("minecraft", "cut_sandstone"),
    anvil.Block("minecraft", "polished_blackstone_bricks"),
]

# Variations for building walls
building_wall_variations = [
    anvil.Block("minecraft", "white_terracotta"),
    anvil.Block("minecraft", "gray_terracotta"),
    anvil.Block("minecraft", "bricks"),
    anvil.Block("minecraft", "smooth_sandstone"),
    anvil.Block("minecraft", "red_terracotta"),
    anvil.Block("minecraft", "polished_diorite"),
    anvil.Block("minecraft", "smooth_stone"),
    anvil.Block("minecraft", "polished_andesite"),
    anvil.Block("minecraft", "warped_planks"),
    anvil.Block("minecraft", "end_stone_bricks"),
    anvil.Block("minecraft", "smooth_red_sandstone"),
    anvil.Block("minecraft", "nether_bricks"),
]

# Variations for building floors
building_floor_variations = [
    anvil.Block("minecraft", "oak_planks"),
    anvil.Block("minecraft", "spruce_planks"),
    anvil.Block("minecraft", "dark_oak_planks"),
    anvil.Block("minecraft", "stone_bricks"),
    anvil.Block("minecraft", "polished_granite"),
    anvil.Block("minecraft", "polished_diorite"),
    anvil.Block("minecraft", "acacia_planks"),
    anvil.Block("minecraft", "jungle_planks"),
    anvil.Block("minecraft", "warped_planks"),
    anvil.Block("minecraft", "purpur_block"),
    anvil.Block("minecraft", "smooth_red_sandstone"),
    anvil.Block("minecraft", "polished_blackstone"),
]
louis-e commented 4 weeks ago

Thanks for checking, if it has a major speed improvement for setting, reading blocks or saving the regions we should consider updating to this package. What's your opinion on that?

amir16yp commented 4 weeks ago

Thanks for checking, if it has a major speed improvement for setting, reading blocks or saving the regions we should consider updating to this package. What's your opinion on that?

I didn't specifically notice a performance difference, but that doesnt mean there isnt one. I haven't benchmarked it. I think we should we upgrade regardless, to futureproof