ygopro-msg-encode 1.1.6 → 1.1.7
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/index.cjs +22 -50
- package/dist/index.cjs.map +3 -3
- package/dist/index.d.ts +2 -5
- package/dist/index.mjs +24 -49
- package/dist/index.mjs.map +3 -3
- package/dist/src/proto-base/index.d.ts +3 -0
- package/dist/src/proto-base/ygopro-proto-base.d.ts +19 -0
- package/dist/src/protos/ctos/base.d.ts +3 -16
- package/dist/src/protos/index.d.ts +5 -0
- package/dist/src/protos/stoc/base.d.ts +3 -16
- package/index.ts +2 -5
- package/package.json +1 -1
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { PayloadBase } from './payload-base';
|
|
2
|
+
export declare class YGOProProtoBase extends PayloadBase {
|
|
3
|
+
static messageDirection: string;
|
|
4
|
+
get messageDirection(): string;
|
|
5
|
+
/**
|
|
6
|
+
* Serialize to full payload including header (length + identifier + body)
|
|
7
|
+
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
8
|
+
* Length = 1 (identifier) + body.length
|
|
9
|
+
*/
|
|
10
|
+
toFullPayload(): Uint8Array;
|
|
11
|
+
/**
|
|
12
|
+
* Deserialize from full payload including header (length + identifier + body)
|
|
13
|
+
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
14
|
+
* @param data - Full payload data
|
|
15
|
+
* @returns this instance
|
|
16
|
+
* @throws Error if data is too short or identifier mismatch
|
|
17
|
+
*/
|
|
18
|
+
fromFullPayload(data: Uint8Array): this;
|
|
19
|
+
}
|
|
@@ -1,17 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare class YGOProCtosBase extends
|
|
3
|
-
|
|
4
|
-
* Serialize to full payload including header (length + identifier + body)
|
|
5
|
-
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
6
|
-
* Length = 1 (identifier) + body.length
|
|
7
|
-
*/
|
|
8
|
-
toFullPayload(): Uint8Array;
|
|
9
|
-
/**
|
|
10
|
-
* Deserialize from full payload including header (length + identifier + body)
|
|
11
|
-
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
12
|
-
* @param data - Full payload data
|
|
13
|
-
* @returns this instance
|
|
14
|
-
* @throws Error if data is too short or identifier mismatch
|
|
15
|
-
*/
|
|
16
|
-
fromFullPayload(data: Uint8Array): this;
|
|
1
|
+
import { YGOProProtoBase } from '../../proto-base/ygopro-proto-base';
|
|
2
|
+
export declare class YGOProCtosBase extends YGOProProtoBase {
|
|
3
|
+
static messageDirection: string;
|
|
17
4
|
}
|
|
@@ -1,17 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare class YGOProStocBase extends
|
|
3
|
-
|
|
4
|
-
* Serialize to full payload including header (length + identifier + body)
|
|
5
|
-
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
6
|
-
* Length = 1 (identifier) + body.length
|
|
7
|
-
*/
|
|
8
|
-
toFullPayload(): Uint8Array;
|
|
9
|
-
/**
|
|
10
|
-
* Deserialize from full payload including header (length + identifier + body)
|
|
11
|
-
* Format: [length 2 bytes LE][identifier 1 byte][body]
|
|
12
|
-
* @param data - Full payload data
|
|
13
|
-
* @returns this instance
|
|
14
|
-
* @throws Error if data is too short or identifier mismatch
|
|
15
|
-
*/
|
|
16
|
-
fromFullPayload(data: Uint8Array): this;
|
|
1
|
+
import { YGOProProtoBase } from '../../proto-base/ygopro-proto-base';
|
|
2
|
+
export declare class YGOProStocBase extends YGOProProtoBase {
|
|
3
|
+
static messageDirection: string;
|
|
17
4
|
}
|
package/index.ts
CHANGED
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
export * from './src/binary/binary-meta';
|
|
2
2
|
export * from './src/binary/fill-binary-fields';
|
|
3
|
-
export * from './src/protos
|
|
4
|
-
export * from './src/protos/ctos';
|
|
5
|
-
export * from './src/protos/stoc';
|
|
6
|
-
export * from './src/protos/msg';
|
|
7
|
-
export * from './src/protos/network-enums';
|
|
3
|
+
export * from './src/protos';
|
|
8
4
|
export * from './src/vendor/ocgcore-constants';
|
|
9
5
|
export * from './src/vendor/script-constants';
|
|
6
|
+
export * from './src/proto-base';
|