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

1.18 support #2339

Merged
merged 25 commits into from
Jan 22, 2022
Merged

1.18 support #2339

merged 25 commits into from
Jan 22, 2022

Conversation

rom1504
Copy link
Member

@rom1504 rom1504 commented Dec 11, 2021

needs

for another PR:

@littlefryingpan
Copy link

Is there already effort on going for these four tasks? If not, I will try and contribute

@catfishjw
Copy link

I am currently working on step 2 (block/item data), should be done in a bit

@tippfehlr tippfehlr mentioned this pull request Dec 21, 2021
@rom1504
Copy link
Member Author

rom1504 commented Jan 6, 2022

PrismarineJS/prismarine-chunk#154 or PrismarineJS/prismarine-chunk#153 will help fix find block

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

the burger path may require to redefine the definition of material / define a new field in blocks.json like "base dig time"
the goal of materials is only to get https://github.com/PrismarineJS/prismarine-block/blob/master/index.js#L266 to work
any alternative property is fine as long as we can backport it to older versions

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

materials.json solved

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

https://wiki.vg/index.php?title=Pre-release_protocol&oldid=17160 for identifying next steps

@rom1504
Copy link
Member Author

rom1504 commented Jan 9, 2022

failing blockAt internal test just needs a fix of https://github.com/PrismarineJS/mineflayer/blob/master/test/internalTest.js#L131

@rom1504
Copy link
Member Author

rom1504 commented Jan 20, 2022

https://github.com/PrismarineJS/mineflayer/tree/1_18#example doc on how to running specific tests

for example npm run mocha_test -- -g "1.18.*BlockFinder"

@rom1504
Copy link
Member Author

rom1504 commented Jan 21, 2022

npm run mocha_test -- -g "mineflayer_internal 1.18.*blockAt"

  mineflayer_internal 1.18
Error: Attempted to read beyond the bounds of the managed data.
    at SmartBuffer.ensureReadable (/workspace/mineflayer/node_modules/smart-buffer/build/smartbuffer.js:1093:19)
    at SmartBuffer._readNumberValue (/workspace/mineflayer/node_modules/smart-buffer/build/smartbuffer.js:1163:14)
    at SmartBuffer.readInt16BE (/workspace/mineflayer/node_modules/smart-buffer/build/smartbuffer.js:118:21)
    at Function.read (/workspace/mineflayer/node_modules/prismarine-chunk/src/pc/common/PaletteChunkSection.js:78:41)
    at ChunkColumn.load (/workspace/mineflayer/node_modules/prismarine-chunk/src/pc/1.18/ChunkColumn.js:242:41)
    ```

looking into internal tests

@rom1504
Copy link
Member Author

rom1504 commented Jan 21, 2022

for beds we need the new /setblock command to update

    bot.chat(`/setblock ${bedPos1.toArray().join(' ')} ${bedItem.name}[part=foot]`)
    bot.chat(`/setblock ${bedPos2.toArray().join(' ')} ${bedItem.name}[part=head]`)

if someone can boot minecraft and tell me what it is, it'll be appreciated

@Beaness
Copy link
Member

Beaness commented Jan 21, 2022

It seems like that the beds got placed correctly. However the multi block change packet seems not to be handled correctly. Is this y level normal?

multi_block_change {
  chunkCoordinates: { x: 0, z: 0, y: 1048572 },
  notTrustEdges: false,
  records: [ 4436500, 4440580 ]
}

@rom1504
Copy link
Member Author

rom1504 commented Jan 21, 2022

now test pass so the next step is PrismarineJS/prismarine-chunk#162 (and some more in mineflayer) for biome dynamic support

then testing a bunch of example: calling volunteers on this one

@rom1504
Copy link
Member Author

rom1504 commented Jan 21, 2022

#2110 (comment)

@rom1504
Copy link
Member Author

rom1504 commented Jan 21, 2022

  • inventory.js
  • chest.js
  • digger.js
  • jumper.js

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

Successfully merging this pull request may close these issues.

5 participants