PrismarineJS / minecraft-data

Language independent module providing minecraft data for minecraft clients, servers and libraries.
https://prismarinejs.github.io/minecraft-data
644 stars 218 forks source link

Recursive 'itemstacks' definition #359

Open barneygale opened 3 years ago

barneygale commented 3 years ago

The definition of PE's 'itemstacks' type itself refers to 'itemstacks': https://github.com/PrismarineJS/minecraft-data/blob/4e9c6056ccb42379f6ff4c017504f26441edf992/data/pe/0.15/protocol.json#L316-L330

rom1504 commented 3 years ago

Yeah that seems broken indeed. I believe @extremeheat is working on an updated version for a newer version

barneygale commented 3 years ago

Nice. I'm going to try to put together a definition for RakNet too, which shouldn't ever need to change. Don't expect it any time soon, though :)

rom1504 commented 3 years ago

We have one at https://github.com/mhsjlw/node-raknet/blob/master/data/protocol.json It works, just missing implementing ack queues on the js side

extremeheat commented 3 years ago

Yes, I'm working on updating it with the protocol library to 1.16. What's your use case? I should have something working soon.

extremeheat commented 3 years ago

Here's an updated ProtoDef protocol definition for bedrock 1.16 if you needed, https://github.com/extremeheat/pocket-minecraft-protocol/blob/new/data/newproto.json

I have it generated from two yaml files for now, https://github.com/extremeheat/pocket-minecraft-protocol/tree/new/data/new through this tool https://github.com/extremeheat/protodef-yaml. This makes maintenance easier and adds comment support.

Expect lots of errors and changes, most of this is manual and has yet to be tested. Once it's stable we can move the definitions to mc-data.

barneygale commented 3 years ago

Amazing! I'll give it a spin soon.