LittleTiles

LittleTiles

12M Downloads

harvestLevelBlock has no effect

LemADEC opened this issue ยท 1 comments

commented

As reported initially in #609, the harvestLevelBlock has no visible effect.

Steps to reproduce:
1- start a new single player world with just LittleTiles_v1.5.8_mc1.12.2 + CreativeCore_v1.10.58_mc1.12.2, no other mods
2- use /cmdconfig to set survival settings as such:

  "survival": {
    "limitAffectedBlocks": true,
    "maxAffectedBlocks": 2,
    "harvestLevelBlock": 0,
    "editUnbreakable": false,
    "minimumTransparency": 255,
    "limitEditBlocks": true,
    "maxEditBlocks": 10,
    "limitPlaceBlocks": true,
    "maxPlaceBlocks": 10
  },

3- place a few obsidian, stone and diamond ore blocks, grab a little hammer
4- switch to survival
5- switch Little hammer to type or box mode then try to chisel

  • 1 stone can be chiseled => ok
  • 2 stone can be chiseled => ok
  • 3 stones can't be chiseled (affected blocks limit reach) => ok
  • 1 obsidian can be modified => NOK
  • 1 diamond ore can be modified => NOK

I suspect the issue is related to the condition which return too soon when editUnbreakable is false, here:

return state.getBlock().getBlockHardness(state, world, pos) > 0;

commented

Good call! Thanks a lot, could never reproduce this issue because editUnbreakable was set to true. Fixed in the newest version!