Build feature CRASH
FrostyZz opened this issue · 15 comments
Some information
Operating system: Windows 10 Pro
Minecraft version: 1.14.4
Baritone version: Most Recent
Details: The build command just crashes my game, i dont know why.
How to reproduce
just use the #build -----------
Im down to help make it work, i know my way around code. If ur fine with that just lemme know and ill help you fix all the stuff.
I've had the same issue. I believe that the issue might be that the block IDs are all funky, but when I installed Baritone for 1.12.2, it didn't work either. It didn't crash, it just couldn't start the task. Yes, the schematics work just fine, I had previously used them with Schematica for a map I was working on.
If it really is a block ID issue, where are all of the blocks and stuff in the baritone code. I’d be willing to change it and get it fixed.
If it really is a block ID issue, where are all of the blocks and stuff in the baritone code. I’d be willing to change it and get it fixed.
I would too, but I don't think that's what the problem is. Looks like Block IDs have been replaced with another way to identify blocks.
#458
From: 0-x-2-2
Yeah build won't work in 1.13 due to schematics having block ids and they got removed in 1.13
Is there anyway we could assign the blocks their old ID’s?
Not sure. I'm new to this project too. I can see that under the src/main/java/baritone/utils/schematic/Schematic.java:39 is where the process gets the schematic file blocks. We'd need to map each byte in the blocks array.
Although, it would make more sense to check whether the schematic is using the old Block IDs or new system. Then, if it's using the old system, map to the new ID. Otherwise, just read the new IDs from the schematic.
I'll keep looking into it.
Awesome, keep me update. If we just need to update the block ID’s we can all try to work on that.
Awesome, keep me update. If we just need to update the block ID’s we can all try to work on that.
So, if you wanted to re-map the states from version 1.12.2 to current block data, you could create your own functions on lines 61 and 63 of the Schematic.java file
(src/main/java/baritone/utils/schematic/Schematic.java)
Block block = Block.REGISTRY.getObjectById(blockID);
int meta = metadata[blockInd] & 0xFF;
states[x][z][y] = block.getStateFromMeta(meta);
set states[x][z][y] to the BlockState that your custom functions return.
A more permanent solution would be to map old schematic files (or at least detect them & raise an error) and also write code to read 1.14.4 schematics (maybe using LITEMATICA or something?)
Personally, I haven't had time to build the solution for this. @FrostyZz are you going to take the lead on this?
You can map the Block IDs from 1.12 by replacing the Block.REGISTRY.getObjectById(blockID);
call with another function such as getMappedId(int inputID)
or something.
I'll let you guys know if I get time to work on this.
Depending on how much time I have. I’m super busy with other projects right now but if I can squeeze this in I will. I could also try to get a couple buddies of mine to work on it, if all goes well I’ll post it but if not I’ll let you guys know.
For more information, pls read #852 where i have included my contact info and where you can reach me if you want to help, or have any questions!