PowerNukkit / Java2Nukkit-World-Converter

Converts worlds from Minecraft 1.15.2+ Java Edition to the newest Nukkit MCA file format
MIT License
23 stars 6 forks source link

I support you! #16

Open junxiesky opened 5 years ago

junxiesky commented 5 years ago

Come On I support you.

joserobjr commented 5 years ago

Thank you :) image

Subject-4 commented 5 years ago

@joserobjr Can this tool be reversed? I'm looking for Nukkit to Java world converter, block IDs in Bedrock and java are different

joserobjr commented 5 years ago

@joserobjr Can this tool be reversed? I'm looking for Nukkit to Java world converter, block IDs in Bedrock and java are different

Sorry, this tool will support only Java Edition to Nukkit. JE have way more information in the world save then Nukkit, so a lot of processing for individual blocks would be necessary and it would take a lot more time to develop.

I'm also writing this tool because I'm preparing my server to support both Java and Bedrock Edition while keeping the same maps that are created in a spigot server.

Subject-4 commented 5 years ago

Ok how about a block remapper to convert PE Block IDs to PC Block IDs for worlds

joserobjr commented 5 years ago

Bedrock Edition to Java Edition 1.14 is harder to build because in the newest JE all block states are handled by the server while in BE most of them are handled by the client.

For example, a oak fence gate. Nukkit always saves it as 85,0 no matter if it's connected to an other fence or not. But in a tool which is converting from Nukkit to Java Edition 1.14, the same 85,0 may be any of the following block states:

oak_fence;east-true;north-true;south-true;waterlogged-true;west-true=85,0
oak_fence;east-true;north-true;south-true;waterlogged-true;west-false=85,0
oak_fence;east-true;north-true;south-true;waterlogged-false;west-true=85,0
oak_fence;east-true;north-true;south-true;waterlogged-false;west-false=85,0
oak_fence;east-true;north-true;south-false;waterlogged-true;west-true=85,0
oak_fence;east-true;north-true;south-false;waterlogged-true;west-false=85,0
oak_fence;east-true;north-true;south-false;waterlogged-false;west-true=85,0
oak_fence;east-true;north-true;south-false;waterlogged-false;west-false=85,0
oak_fence;east-true;north-false;south-true;waterlogged-true;west-true=85,0
oak_fence;east-true;north-false;south-true;waterlogged-true;west-false=85,0
oak_fence;east-true;north-false;south-true;waterlogged-false;west-true=85,0
oak_fence;east-true;north-false;south-true;waterlogged-false;west-false=85,0
oak_fence;east-true;north-false;south-false;waterlogged-true;west-true=85,0
oak_fence;east-true;north-false;south-false;waterlogged-true;west-false=85,0
oak_fence;east-true;north-false;south-false;waterlogged-false;west-true=85,0
oak_fence;east-true;north-false;south-false;waterlogged-false;west-false=85,0
oak_fence;east-false;north-true;south-true;waterlogged-true;west-true=85,0
oak_fence;east-false;north-true;south-true;waterlogged-true;west-false=85,0
oak_fence;east-false;north-true;south-true;waterlogged-false;west-true=85,0
oak_fence;east-false;north-true;south-true;waterlogged-false;west-false=85,0
oak_fence;east-false;north-true;south-false;waterlogged-true;west-true=85,0
oak_fence;east-false;north-true;south-false;waterlogged-true;west-false=85,0
oak_fence;east-false;north-true;south-false;waterlogged-false;west-true=85,0
oak_fence;east-false;north-true;south-false;waterlogged-false;west-false=85,0
oak_fence;east-false;north-false;south-true;waterlogged-true;west-true=85,0
oak_fence;east-false;north-false;south-true;waterlogged-true;west-false=85,0
oak_fence;east-false;north-false;south-true;waterlogged-false;west-true=85,0
oak_fence;east-false;north-false;south-true;waterlogged-false;west-false=85,0
oak_fence;east-false;north-false;south-false;waterlogged-true;west-true=85,0
oak_fence;east-false;north-false;south-false;waterlogged-true;west-false=85,0
oak_fence;east-false;north-false;south-false;waterlogged-false;west-true=85,0
oak_fence;east-false;north-false;south-false;waterlogged-false;west-false=85,0

So for each fence type the converter would need to check for all possible property in the blockstate.

An other example would be to convert a redstone wire, that's gonna be a hell to convert that! Look how many lines it took to convert from Java to Nukkit: https://github.com/GameModsBR/Java2Nukkit-World-Converter/blob/4be23f8f2b44227a67d4be3e9b3703e978a1d271/src/main/resources/block-states.properties#L2129-L3424

And this tool is designed to convert only from Java Edition 1.14+ to Nukkit, it's a one-way road.