
Lootr 1.20.1 Forge - Lootr chests can be destroyed by Create mechanisms (drills, etc.)
Closed this issue ยท 9 comments
Lootr 1.20.1 Forge - Lootr chests can be destroyed by Create mechanisms (drills, etc.)
The "fix" that existed in 1.19 is not going to be forward-ported to 1.20.
Instead, you'll need to file an issue with Create: there are two places in the code where "can this be broken" is checked, and both of them only check block hardness when they could very easily check for the existence of a block tag.
Place 1: BlockBreakingKineticBlockEntity::isBreakable
Place 2: Actually just defers to that isBreakable
method.
Adding a tag is not hard.
Their current mechanism of consulting BlockState::getDestroySpeed
returns the hard-coded destroySpeed
which comes directly from the block's properties when it is initialized. There's no context not consultation of the block to allow it to be consulted as to whether it should be breakable or not.
(For the record, my previous "fix" that was in place was actually a broken mixin.)
I'm creating an example PR for Create. Again, this is nothing I can personally fix, it needs to be adjusted by Create.
As noted in the issue, this is a completely untested PR made simply as an example and a starting point. Their use of tags is idioscyncratic and I don't fully understand it. Plus, I wrote it in the web interface and never checked the code base out.
As noted in the issue, this is a completely untested PR made simply as an example and a starting point. Their use of tags is idioscyncratic and I don't fully understand it. Plus, I wrote it in the web interface and never checked the code base out.
your PR working. i test and good work thank you!