Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run at minecraftpe1.5? (even if there are no new squares on the map) #51

Open
ZanyXD opened this issue Jul 20, 2018 · 6 comments

Comments

@ZanyXD
Copy link

ZanyXD commented Jul 20, 2018

No description provided.

@ZanyXD
Copy link
Author

ZanyXD commented Jul 20, 2018

D:>java -jar Converter.jar D:/MC/AA D:/mcpc
Converting chunk 0,0...
Biomes and Heightmap
SubChunk...0
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException
at java.base/java.lang.System.arraycopy(Native Method)
at com.ljyloo.PE2PC.ConvertSource.convertSubChunk(ConvertSource.java:127)
at com.ljyloo.PE2PC.PE2PC.convert(PE2PC.java:102)
at com.ljyloo.PE2PC.PE2PC.main(PE2PC.java:35)

@CrystalRays
Copy link

I hava the same problem.
How to fix it ?

@CrystalRays
Copy link

CrystalRays commented Aug 14, 2018

I am new to Java.
I found the leveldb fields read into the program are divided to two part: byte[4096] oldBlock & byte[2048] oldMeta.
I guess the leveldb fields of old Minecraft Bedrock are byte[6145]:1+4096+2048
But now there is some fields are byte[2509], byte[23**] and etc.
So here comes the error: ArrayIndexOutOfBoundsException, when use the arraycopy to copy and divide the fields to oldBlock and old Meta.
I don't know how to fix it, is here anyone can fix it?

@nomizzz
Copy link

nomizzz commented Aug 15, 2018

@CrystalRays nice insight, from my limited debugging and experience with the NBT format, it I think you're on the right track.

Looks like in one of the Bedrock upgrades the "Block Data" field of Subchunks can now be variable and less than the BLOCKDATA_BYTES constant defined on line 18 of ConvertSource.java. I'm trying to debug it further but because there's such limited data on the Bedrock Level format I'm having trouble determining what belongs there.

This also seems to be a duplicate of #46

@CrystalRays
Copy link

Thanks. @nomizzz
Thanks for your effort.
If possible we should to search for more information about what has mojang changed in the new version of Bloack Data which is really difficulty.
It's the first time I tried to read Java code, however I had a little experience on other language and I will try to continue on this issue.

Maybe my pour English would bother you and sorry for that if it's true.

@0x9fff00
Copy link
Contributor

@CrystalRays @nomizzz See my comment in #46 for documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants