@miniblox/protocol 3.41.77-0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/common_pb.d.mts +132 -0
- package/dist/common_pb.mjs +252 -0
- package/dist/protocol2_pb.d.mts +3297 -0
- package/dist/protocol2_pb.mjs +7043 -0
- package/dist/protocol3_pb.d.mts +104 -0
- package/dist/protocol3_pb.mjs +233 -0
- package/package.json +29 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, Message, PartialMessage, PlainMessage, proto3 } from "@bufbuild/protobuf";
|
|
2
|
+
|
|
3
|
+
//#region gen/protocol3_pb.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* @generated from message PBCell
|
|
6
|
+
*/
|
|
7
|
+
declare class PBCell extends Message<PBCell> {
|
|
8
|
+
/**
|
|
9
|
+
* @generated from field: uint32 bitsPerEntry = 2;
|
|
10
|
+
*/
|
|
11
|
+
bitsPerEntry: number;
|
|
12
|
+
/**
|
|
13
|
+
* @generated from field: repeated uint32 palette = 3;
|
|
14
|
+
*/
|
|
15
|
+
palette: number[];
|
|
16
|
+
/**
|
|
17
|
+
* @generated from field: uint32 blockRefCount = 5;
|
|
18
|
+
*/
|
|
19
|
+
blockRefCount: number;
|
|
20
|
+
/**
|
|
21
|
+
* @generated from field: bytes bitArray = 6;
|
|
22
|
+
*/
|
|
23
|
+
bitArray: Uint8Array<ArrayBuffer>;
|
|
24
|
+
/**
|
|
25
|
+
* @generated from field: uint32 y = 7;
|
|
26
|
+
*/
|
|
27
|
+
y: number;
|
|
28
|
+
constructor(data?: PartialMessage<PBCell>);
|
|
29
|
+
static readonly runtime: typeof proto3;
|
|
30
|
+
static readonly typeName = "PBCell";
|
|
31
|
+
static readonly fields: FieldList;
|
|
32
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): PBCell;
|
|
33
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): PBCell;
|
|
34
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): PBCell;
|
|
35
|
+
static equals(a: PBCell | PlainMessage<PBCell> | undefined, b: PBCell | PlainMessage<PBCell> | undefined): boolean;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* @generated from message PBTileEntity
|
|
39
|
+
*/
|
|
40
|
+
declare class PBTileEntity extends Message<PBTileEntity> {
|
|
41
|
+
/**
|
|
42
|
+
* @generated from field: sint32 x = 1;
|
|
43
|
+
*/
|
|
44
|
+
x: number;
|
|
45
|
+
/**
|
|
46
|
+
* @generated from field: uint32 y = 2;
|
|
47
|
+
*/
|
|
48
|
+
y: number;
|
|
49
|
+
/**
|
|
50
|
+
* @generated from field: sint32 z = 3;
|
|
51
|
+
*/
|
|
52
|
+
z: number;
|
|
53
|
+
/**
|
|
54
|
+
* @generated from field: bytes nbt = 5;
|
|
55
|
+
*/
|
|
56
|
+
nbt: Uint8Array<ArrayBuffer>;
|
|
57
|
+
constructor(data?: PartialMessage<PBTileEntity>);
|
|
58
|
+
static readonly runtime: typeof proto3;
|
|
59
|
+
static readonly typeName = "PBTileEntity";
|
|
60
|
+
static readonly fields: FieldList;
|
|
61
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): PBTileEntity;
|
|
62
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): PBTileEntity;
|
|
63
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): PBTileEntity;
|
|
64
|
+
static equals(a: PBTileEntity | PlainMessage<PBTileEntity> | undefined, b: PBTileEntity | PlainMessage<PBTileEntity> | undefined): boolean;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* @generated from message CPacketChunkData
|
|
68
|
+
*/
|
|
69
|
+
declare class CPacketChunkData extends Message<CPacketChunkData> {
|
|
70
|
+
/**
|
|
71
|
+
* @generated from field: sint32 x = 1;
|
|
72
|
+
*/
|
|
73
|
+
x: number;
|
|
74
|
+
/**
|
|
75
|
+
* @generated from field: sint32 z = 2;
|
|
76
|
+
*/
|
|
77
|
+
z: number;
|
|
78
|
+
/**
|
|
79
|
+
* @generated from field: repeated PBCell cells = 3;
|
|
80
|
+
*/
|
|
81
|
+
cells: PBCell[];
|
|
82
|
+
/**
|
|
83
|
+
* @generated from field: repeated PBTileEntity tileEntities = 4;
|
|
84
|
+
*/
|
|
85
|
+
tileEntities: PBTileEntity[];
|
|
86
|
+
/**
|
|
87
|
+
* @generated from field: int32 dimension = 5;
|
|
88
|
+
*/
|
|
89
|
+
dimension: number;
|
|
90
|
+
/**
|
|
91
|
+
* @generated from field: repeated uint32 biomes = 6;
|
|
92
|
+
*/
|
|
93
|
+
biomes: number[];
|
|
94
|
+
constructor(data?: PartialMessage<CPacketChunkData>);
|
|
95
|
+
static readonly runtime: typeof proto3;
|
|
96
|
+
static readonly typeName = "CPacketChunkData";
|
|
97
|
+
static readonly fields: FieldList;
|
|
98
|
+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CPacketChunkData;
|
|
99
|
+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CPacketChunkData;
|
|
100
|
+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CPacketChunkData;
|
|
101
|
+
static equals(a: CPacketChunkData | PlainMessage<CPacketChunkData> | undefined, b: CPacketChunkData | PlainMessage<CPacketChunkData> | undefined): boolean;
|
|
102
|
+
}
|
|
103
|
+
//#endregion
|
|
104
|
+
export { CPacketChunkData, PBCell, PBTileEntity };
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
import { Message, proto3 } from "@bufbuild/protobuf";
|
|
2
|
+
//#region gen/protocol3_pb.ts
|
|
3
|
+
/**
|
|
4
|
+
* @generated from message PBCell
|
|
5
|
+
*/
|
|
6
|
+
var PBCell = class PBCell extends Message {
|
|
7
|
+
/**
|
|
8
|
+
* @generated from field: uint32 bitsPerEntry = 2;
|
|
9
|
+
*/
|
|
10
|
+
bitsPerEntry = 0;
|
|
11
|
+
/**
|
|
12
|
+
* @generated from field: repeated uint32 palette = 3;
|
|
13
|
+
*/
|
|
14
|
+
palette = [];
|
|
15
|
+
/**
|
|
16
|
+
* @generated from field: uint32 blockRefCount = 5;
|
|
17
|
+
*/
|
|
18
|
+
blockRefCount = 0;
|
|
19
|
+
/**
|
|
20
|
+
* @generated from field: bytes bitArray = 6;
|
|
21
|
+
*/
|
|
22
|
+
bitArray = new Uint8Array(0);
|
|
23
|
+
/**
|
|
24
|
+
* @generated from field: uint32 y = 7;
|
|
25
|
+
*/
|
|
26
|
+
y = 0;
|
|
27
|
+
constructor(data) {
|
|
28
|
+
super();
|
|
29
|
+
proto3.util.initPartial(data, this);
|
|
30
|
+
}
|
|
31
|
+
static runtime = proto3;
|
|
32
|
+
static typeName = "PBCell";
|
|
33
|
+
static fields = proto3.util.newFieldList(() => [
|
|
34
|
+
{
|
|
35
|
+
no: 2,
|
|
36
|
+
name: "bitsPerEntry",
|
|
37
|
+
kind: "scalar",
|
|
38
|
+
T: 13
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
no: 3,
|
|
42
|
+
name: "palette",
|
|
43
|
+
kind: "scalar",
|
|
44
|
+
T: 13,
|
|
45
|
+
repeated: true
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
no: 5,
|
|
49
|
+
name: "blockRefCount",
|
|
50
|
+
kind: "scalar",
|
|
51
|
+
T: 13
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
no: 6,
|
|
55
|
+
name: "bitArray",
|
|
56
|
+
kind: "scalar",
|
|
57
|
+
T: 12
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
no: 7,
|
|
61
|
+
name: "y",
|
|
62
|
+
kind: "scalar",
|
|
63
|
+
T: 13
|
|
64
|
+
}
|
|
65
|
+
]);
|
|
66
|
+
static fromBinary(bytes, options) {
|
|
67
|
+
return new PBCell().fromBinary(bytes, options);
|
|
68
|
+
}
|
|
69
|
+
static fromJson(jsonValue, options) {
|
|
70
|
+
return new PBCell().fromJson(jsonValue, options);
|
|
71
|
+
}
|
|
72
|
+
static fromJsonString(jsonString, options) {
|
|
73
|
+
return new PBCell().fromJsonString(jsonString, options);
|
|
74
|
+
}
|
|
75
|
+
static equals(a, b) {
|
|
76
|
+
return proto3.util.equals(PBCell, a, b);
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* @generated from message PBTileEntity
|
|
81
|
+
*/
|
|
82
|
+
var PBTileEntity = class PBTileEntity extends Message {
|
|
83
|
+
/**
|
|
84
|
+
* @generated from field: sint32 x = 1;
|
|
85
|
+
*/
|
|
86
|
+
x = 0;
|
|
87
|
+
/**
|
|
88
|
+
* @generated from field: uint32 y = 2;
|
|
89
|
+
*/
|
|
90
|
+
y = 0;
|
|
91
|
+
/**
|
|
92
|
+
* @generated from field: sint32 z = 3;
|
|
93
|
+
*/
|
|
94
|
+
z = 0;
|
|
95
|
+
/**
|
|
96
|
+
* @generated from field: bytes nbt = 5;
|
|
97
|
+
*/
|
|
98
|
+
nbt = new Uint8Array(0);
|
|
99
|
+
constructor(data) {
|
|
100
|
+
super();
|
|
101
|
+
proto3.util.initPartial(data, this);
|
|
102
|
+
}
|
|
103
|
+
static runtime = proto3;
|
|
104
|
+
static typeName = "PBTileEntity";
|
|
105
|
+
static fields = proto3.util.newFieldList(() => [
|
|
106
|
+
{
|
|
107
|
+
no: 1,
|
|
108
|
+
name: "x",
|
|
109
|
+
kind: "scalar",
|
|
110
|
+
T: 17
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
no: 2,
|
|
114
|
+
name: "y",
|
|
115
|
+
kind: "scalar",
|
|
116
|
+
T: 13
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
no: 3,
|
|
120
|
+
name: "z",
|
|
121
|
+
kind: "scalar",
|
|
122
|
+
T: 17
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
no: 5,
|
|
126
|
+
name: "nbt",
|
|
127
|
+
kind: "scalar",
|
|
128
|
+
T: 12
|
|
129
|
+
}
|
|
130
|
+
]);
|
|
131
|
+
static fromBinary(bytes, options) {
|
|
132
|
+
return new PBTileEntity().fromBinary(bytes, options);
|
|
133
|
+
}
|
|
134
|
+
static fromJson(jsonValue, options) {
|
|
135
|
+
return new PBTileEntity().fromJson(jsonValue, options);
|
|
136
|
+
}
|
|
137
|
+
static fromJsonString(jsonString, options) {
|
|
138
|
+
return new PBTileEntity().fromJsonString(jsonString, options);
|
|
139
|
+
}
|
|
140
|
+
static equals(a, b) {
|
|
141
|
+
return proto3.util.equals(PBTileEntity, a, b);
|
|
142
|
+
}
|
|
143
|
+
};
|
|
144
|
+
/**
|
|
145
|
+
* @generated from message CPacketChunkData
|
|
146
|
+
*/
|
|
147
|
+
var CPacketChunkData = class CPacketChunkData extends Message {
|
|
148
|
+
/**
|
|
149
|
+
* @generated from field: sint32 x = 1;
|
|
150
|
+
*/
|
|
151
|
+
x = 0;
|
|
152
|
+
/**
|
|
153
|
+
* @generated from field: sint32 z = 2;
|
|
154
|
+
*/
|
|
155
|
+
z = 0;
|
|
156
|
+
/**
|
|
157
|
+
* @generated from field: repeated PBCell cells = 3;
|
|
158
|
+
*/
|
|
159
|
+
cells = [];
|
|
160
|
+
/**
|
|
161
|
+
* @generated from field: repeated PBTileEntity tileEntities = 4;
|
|
162
|
+
*/
|
|
163
|
+
tileEntities = [];
|
|
164
|
+
/**
|
|
165
|
+
* @generated from field: int32 dimension = 5;
|
|
166
|
+
*/
|
|
167
|
+
dimension = 0;
|
|
168
|
+
/**
|
|
169
|
+
* @generated from field: repeated uint32 biomes = 6;
|
|
170
|
+
*/
|
|
171
|
+
biomes = [];
|
|
172
|
+
constructor(data) {
|
|
173
|
+
super();
|
|
174
|
+
proto3.util.initPartial(data, this);
|
|
175
|
+
}
|
|
176
|
+
static runtime = proto3;
|
|
177
|
+
static typeName = "CPacketChunkData";
|
|
178
|
+
static fields = proto3.util.newFieldList(() => [
|
|
179
|
+
{
|
|
180
|
+
no: 1,
|
|
181
|
+
name: "x",
|
|
182
|
+
kind: "scalar",
|
|
183
|
+
T: 17
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
no: 2,
|
|
187
|
+
name: "z",
|
|
188
|
+
kind: "scalar",
|
|
189
|
+
T: 17
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
no: 3,
|
|
193
|
+
name: "cells",
|
|
194
|
+
kind: "message",
|
|
195
|
+
T: PBCell,
|
|
196
|
+
repeated: true
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
no: 4,
|
|
200
|
+
name: "tileEntities",
|
|
201
|
+
kind: "message",
|
|
202
|
+
T: PBTileEntity,
|
|
203
|
+
repeated: true
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
no: 5,
|
|
207
|
+
name: "dimension",
|
|
208
|
+
kind: "scalar",
|
|
209
|
+
T: 5
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
no: 6,
|
|
213
|
+
name: "biomes",
|
|
214
|
+
kind: "scalar",
|
|
215
|
+
T: 13,
|
|
216
|
+
repeated: true
|
|
217
|
+
}
|
|
218
|
+
]);
|
|
219
|
+
static fromBinary(bytes, options) {
|
|
220
|
+
return new CPacketChunkData().fromBinary(bytes, options);
|
|
221
|
+
}
|
|
222
|
+
static fromJson(jsonValue, options) {
|
|
223
|
+
return new CPacketChunkData().fromJson(jsonValue, options);
|
|
224
|
+
}
|
|
225
|
+
static fromJsonString(jsonString, options) {
|
|
226
|
+
return new CPacketChunkData().fromJsonString(jsonString, options);
|
|
227
|
+
}
|
|
228
|
+
static equals(a, b) {
|
|
229
|
+
return proto3.util.equals(CPacketChunkData, a, b);
|
|
230
|
+
}
|
|
231
|
+
};
|
|
232
|
+
//#endregion
|
|
233
|
+
export { CPacketChunkData, PBCell, PBTileEntity };
|
package/package.json
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@miniblox/protocol",
|
|
3
|
+
"version": "3.41.77-0.0.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"packageManager": "bun@1.3.4",
|
|
6
|
+
"readme": "ReadME.md",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"build:proto": "buf generate",
|
|
9
|
+
"build:js": "tsdown",
|
|
10
|
+
"build": "bun run build:proto && bun run build:js",
|
|
11
|
+
"prepublishOnly": "bun run build"
|
|
12
|
+
},
|
|
13
|
+
"publishConfig": {
|
|
14
|
+
"access": "public",
|
|
15
|
+
"provenance": true
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
20
|
+
"dependencies": {
|
|
21
|
+
"@bufbuild/buf": "^1.70.0",
|
|
22
|
+
"@bufbuild/protobuf": "^1.10.1"
|
|
23
|
+
},
|
|
24
|
+
"devDependencies": {
|
|
25
|
+
"@bufbuild/protoc-gen-es": "^1.10.1",
|
|
26
|
+
"@msgpack/msgpack": "^3.1.3",
|
|
27
|
+
"tsdown": "0.22.2"
|
|
28
|
+
}
|
|
29
|
+
}
|