@sanctumterra/raknet 1.3.80 → 1.4.1
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/README.md +1 -1
- package/dist/client/client.d.ts +19 -20
- package/dist/client/client.d.ts.map +1 -1
- package/dist/client/client.js +139 -184
- package/dist/client/types/client-events.d.ts +5 -20
- package/dist/client/types/client-events.d.ts.map +1 -1
- package/dist/client/types/client-options.d.ts +7 -8
- package/dist/client/types/client-options.d.ts.map +1 -1
- package/dist/client/types/client-options.js +9 -9
- package/dist/client/types/index.d.ts +1 -1
- package/dist/client/types/index.d.ts.map +1 -1
- package/dist/client/types/index.js +1 -1
- package/dist/index.d.ts +1 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -3
- package/dist/server/connection.d.ts +20 -59
- package/dist/server/connection.d.ts.map +1 -1
- package/dist/server/connection.js +53 -365
- package/dist/server/index.d.ts +2 -3
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +2 -3
- package/dist/server/server.d.ts +11 -18
- package/dist/server/server.d.ts.map +1 -1
- package/dist/server/server.js +98 -137
- package/dist/{proto → server}/types/advertisement.d.ts +1 -1
- package/dist/server/types/advertisement.d.ts.map +1 -0
- package/dist/{proto → server}/types/advertisement.js +14 -10
- package/dist/server/types/connection-events.d.ts +4 -0
- package/dist/server/types/connection-events.d.ts.map +1 -0
- package/dist/server/types/index.d.ts +5 -0
- package/dist/server/types/index.d.ts.map +1 -0
- package/dist/{proto → server}/types/index.js +3 -1
- package/dist/server/types/server-events.d.ts +7 -0
- package/dist/server/types/server-events.d.ts.map +1 -0
- package/dist/server/types/server-options.d.ts +12 -0
- package/dist/server/types/server-options.d.ts.map +1 -0
- package/dist/server/types/server-options.js +14 -0
- package/dist/shared/emitter.d.ts +28 -0
- package/dist/shared/emitter.d.ts.map +1 -0
- package/dist/shared/emitter.js +71 -0
- package/dist/shared/index.d.ts +5 -0
- package/dist/shared/index.d.ts.map +1 -0
- package/dist/{proto/decorators → shared}/index.js +4 -2
- package/dist/{utils/Logger.d.ts → shared/logger.d.ts} +1 -1
- package/dist/shared/logger.d.ts.map +1 -0
- package/dist/shared/network_session.d.ts +34 -0
- package/dist/shared/network_session.d.ts.map +1 -0
- package/dist/shared/network_session.js +247 -0
- package/dist/shared/proto/enums/connectionStatus.d.ts +8 -0
- package/dist/shared/proto/enums/connectionStatus.d.ts.map +1 -0
- package/dist/shared/proto/enums/connectionStatus.js +11 -0
- package/dist/shared/proto/enums/index.d.ts +5 -0
- package/dist/shared/proto/enums/index.d.ts.map +1 -0
- package/dist/{proto → shared/proto}/enums/index.js +2 -3
- package/dist/shared/proto/enums/packets.d.ts +19 -0
- package/dist/shared/proto/enums/packets.d.ts.map +1 -0
- package/dist/shared/proto/enums/packets.js +23 -0
- package/dist/shared/proto/enums/priority.d.ts +6 -0
- package/dist/shared/proto/enums/priority.d.ts.map +1 -0
- package/dist/shared/proto/enums/priority.js +4 -0
- package/dist/shared/proto/enums/reliability.d.ts.map +1 -0
- package/dist/shared/proto/index.d.ts +5 -0
- package/dist/shared/proto/index.d.ts.map +1 -0
- package/dist/{proto → shared/proto}/index.js +3 -3
- package/dist/shared/proto/offline/index.d.ts +7 -0
- package/dist/shared/proto/offline/index.d.ts.map +1 -0
- package/dist/shared/proto/offline/index.js +22 -0
- package/dist/shared/proto/offline/open-connection-reply-one.d.ts +9 -0
- package/dist/shared/proto/offline/open-connection-reply-one.d.ts.map +1 -0
- package/dist/shared/proto/offline/open-connection-reply-one.js +28 -0
- package/dist/shared/proto/offline/open-connection-reply-two.d.ts +11 -0
- package/dist/shared/proto/offline/open-connection-reply-two.d.ts.map +1 -0
- package/dist/shared/proto/offline/open-connection-reply-two.js +31 -0
- package/dist/shared/proto/offline/open-connection-request-one.d.ts +8 -0
- package/dist/shared/proto/offline/open-connection-request-one.d.ts.map +1 -0
- package/dist/shared/proto/offline/open-connection-request-one.js +25 -0
- package/dist/shared/proto/offline/open-connection-request-two.d.ts +10 -0
- package/dist/shared/proto/offline/open-connection-request-two.d.ts.map +1 -0
- package/dist/shared/proto/offline/open-connection-request-two.js +28 -0
- package/dist/shared/proto/offline/unconnected-ping.d.ts +8 -0
- package/dist/shared/proto/offline/unconnected-ping.d.ts.map +1 -0
- package/dist/shared/proto/offline/unconnected-ping.js +25 -0
- package/dist/shared/proto/offline/unconnected-pong.d.ts +9 -0
- package/dist/shared/proto/offline/unconnected-pong.d.ts.map +1 -0
- package/dist/shared/proto/offline/unconnected-pong.js +28 -0
- package/dist/shared/proto/online/ack.d.ts +7 -0
- package/dist/shared/proto/online/ack.d.ts.map +1 -0
- package/dist/{proto/packets → shared/proto/online}/ack.js +16 -31
- package/dist/shared/proto/online/connected-ping.d.ts +7 -0
- package/dist/shared/proto/online/connected-ping.d.ts.map +1 -0
- package/dist/shared/proto/online/connected-ping.js +19 -0
- package/dist/shared/proto/online/connected-pong.d.ts +8 -0
- package/dist/shared/proto/online/connected-pong.d.ts.map +1 -0
- package/dist/shared/proto/online/connected-pong.js +22 -0
- package/dist/shared/proto/online/connection-request-accepted.d.ts +12 -0
- package/dist/shared/proto/online/connection-request-accepted.d.ts.map +1 -0
- package/dist/shared/proto/online/connection-request-accepted.js +37 -0
- package/dist/shared/proto/online/connection-request.d.ts +9 -0
- package/dist/shared/proto/online/connection-request.d.ts.map +1 -0
- package/dist/shared/proto/online/connection-request.js +25 -0
- package/dist/shared/proto/online/disconnect-message.d.ts +6 -0
- package/dist/shared/proto/online/disconnect-message.d.ts.map +1 -0
- package/dist/shared/proto/online/disconnect-message.js +15 -0
- package/dist/shared/proto/online/frame-set.d.ts +9 -0
- package/dist/shared/proto/online/frame-set.d.ts.map +1 -0
- package/dist/shared/proto/online/frame-set.js +23 -0
- package/dist/shared/proto/online/index.d.ts +9 -0
- package/dist/shared/proto/online/index.d.ts.map +1 -0
- package/dist/shared/proto/online/index.js +24 -0
- package/dist/shared/proto/online/new-incomming-connection.d.ts +11 -0
- package/dist/shared/proto/online/new-incomming-connection.d.ts.map +1 -0
- package/dist/shared/proto/online/new-incomming-connection.js +33 -0
- package/dist/shared/proto/types/address.d.ts +12 -0
- package/dist/shared/proto/types/address.d.ts.map +1 -0
- package/dist/shared/proto/types/address.js +61 -0
- package/dist/shared/proto/types/frame.d.ts +23 -0
- package/dist/shared/proto/types/frame.d.ts.map +1 -0
- package/dist/shared/proto/types/frame.js +119 -0
- package/dist/{proto/packets → shared/proto}/types/index.d.ts +0 -2
- package/dist/shared/proto/types/index.d.ts.map +1 -0
- package/dist/{proto/packets → shared/proto}/types/index.js +0 -2
- package/dist/shared/proto/types/magic.d.ts +7 -0
- package/dist/shared/proto/types/magic.d.ts.map +1 -0
- package/dist/shared/proto/types/magic.js +15 -0
- package/dist/shared/proto/types/mtu.d.ts +7 -0
- package/dist/shared/proto/types/mtu.d.ts.map +1 -0
- package/dist/shared/proto/types/mtu.js +13 -0
- package/dist/tests/client-connect.d.ts +2 -0
- package/dist/tests/client-connect.d.ts.map +1 -0
- package/dist/tests/client-connect.js +32 -0
- package/dist/tests/client-once.d.ts +2 -0
- package/dist/tests/client-once.d.ts.map +1 -0
- package/dist/tests/client-once.js +11 -0
- package/dist/tests/server-listen.d.ts +2 -0
- package/dist/tests/server-listen.d.ts.map +1 -0
- package/dist/tests/server-listen.js +5 -0
- package/package.json +12 -6
- package/bun.lock +0 -67
- package/dist/client/framer.d.ts +0 -55
- package/dist/client/framer.d.ts.map +0 -1
- package/dist/client/framer.js +0 -458
- package/dist/proto/decorators/create.d.ts +0 -8
- package/dist/proto/decorators/create.d.ts.map +0 -1
- package/dist/proto/decorators/create.js +0 -77
- package/dist/proto/decorators/index.d.ts +0 -3
- package/dist/proto/decorators/index.d.ts.map +0 -1
- package/dist/proto/decorators/serialize.d.ts +0 -4
- package/dist/proto/decorators/serialize.d.ts.map +0 -1
- package/dist/proto/decorators/serialize.js +0 -12
- package/dist/proto/enums/flags.d.ts +0 -7
- package/dist/proto/enums/flags.d.ts.map +0 -1
- package/dist/proto/enums/flags.js +0 -10
- package/dist/proto/enums/index.d.ts +0 -6
- package/dist/proto/enums/index.d.ts.map +0 -1
- package/dist/proto/enums/packet.d.ts +0 -122
- package/dist/proto/enums/packet.d.ts.map +0 -1
- package/dist/proto/enums/packet.js +0 -125
- package/dist/proto/enums/priority.d.ts +0 -5
- package/dist/proto/enums/priority.d.ts.map +0 -1
- package/dist/proto/enums/priority.js +0 -8
- package/dist/proto/enums/reliability.d.ts.map +0 -1
- package/dist/proto/enums/status.d.ts +0 -7
- package/dist/proto/enums/status.d.ts.map +0 -1
- package/dist/proto/enums/status.js +0 -10
- package/dist/proto/index.d.ts +0 -5
- package/dist/proto/index.d.ts.map +0 -1
- package/dist/proto/packets/ack.d.ts +0 -10
- package/dist/proto/packets/ack.d.ts.map +0 -1
- package/dist/proto/packets/base-packet.d.ts +0 -26
- package/dist/proto/packets/base-packet.d.ts.map +0 -1
- package/dist/proto/packets/base-packet.js +0 -37
- package/dist/proto/packets/connected-ping.d.ts +0 -5
- package/dist/proto/packets/connected-ping.d.ts.map +0 -1
- package/dist/proto/packets/connected-ping.js +0 -27
- package/dist/proto/packets/connected-pong.d.ts +0 -6
- package/dist/proto/packets/connected-pong.d.ts.map +0 -1
- package/dist/proto/packets/connected-pong.js +0 -32
- package/dist/proto/packets/connection-request-accepted.d.ts +0 -10
- package/dist/proto/packets/connection-request-accepted.d.ts.map +0 -1
- package/dist/proto/packets/connection-request-accepted.js +0 -48
- package/dist/proto/packets/connection-request.d.ts +0 -7
- package/dist/proto/packets/connection-request.d.ts.map +0 -1
- package/dist/proto/packets/connection-request.js +0 -37
- package/dist/proto/packets/disconnect.d.ts +0 -5
- package/dist/proto/packets/disconnect.d.ts.map +0 -1
- package/dist/proto/packets/disconnect.js +0 -17
- package/dist/proto/packets/frame.d.ts +0 -1
- package/dist/proto/packets/frame.d.ts.map +0 -1
- package/dist/proto/packets/frame.js +0 -1
- package/dist/proto/packets/frameset.d.ts +0 -11
- package/dist/proto/packets/frameset.d.ts.map +0 -1
- package/dist/proto/packets/frameset.js +0 -37
- package/dist/proto/packets/incompatible-protocol-version.d.ts +0 -8
- package/dist/proto/packets/incompatible-protocol-version.d.ts.map +0 -1
- package/dist/proto/packets/incompatible-protocol-version.js +0 -38
- package/dist/proto/packets/index.d.ts +0 -19
- package/dist/proto/packets/index.d.ts.map +0 -1
- package/dist/proto/packets/index.js +0 -34
- package/dist/proto/packets/nack.d.ts +0 -8
- package/dist/proto/packets/nack.d.ts.map +0 -1
- package/dist/proto/packets/nack.js +0 -88
- package/dist/proto/packets/new-incoming-connection.d.ts +0 -9
- package/dist/proto/packets/new-incoming-connection.d.ts.map +0 -1
- package/dist/proto/packets/new-incoming-connection.js +0 -43
- package/dist/proto/packets/open-connection-reply-one.d.ts +0 -8
- package/dist/proto/packets/open-connection-reply-one.d.ts.map +0 -1
- package/dist/proto/packets/open-connection-reply-one.js +0 -43
- package/dist/proto/packets/open-connection-reply-two.d.ts +0 -10
- package/dist/proto/packets/open-connection-reply-two.d.ts.map +0 -1
- package/dist/proto/packets/open-connection-reply-two.js +0 -48
- package/dist/proto/packets/open-connection-request-one.d.ts +0 -7
- package/dist/proto/packets/open-connection-request-one.d.ts.map +0 -1
- package/dist/proto/packets/open-connection-request-one.js +0 -38
- package/dist/proto/packets/open-connection-request-two.d.ts +0 -9
- package/dist/proto/packets/open-connection-request-two.d.ts.map +0 -1
- package/dist/proto/packets/open-connection-request-two.js +0 -43
- package/dist/proto/packets/types/address.d.ts +0 -48
- package/dist/proto/packets/types/address.d.ts.map +0 -1
- package/dist/proto/packets/types/address.js +0 -99
- package/dist/proto/packets/types/data-type.d.ts +0 -21
- package/dist/proto/packets/types/data-type.d.ts.map +0 -1
- package/dist/proto/packets/types/data-type.js +0 -29
- package/dist/proto/packets/types/frame.d.ts +0 -23
- package/dist/proto/packets/types/frame.d.ts.map +0 -1
- package/dist/proto/packets/types/frame.js +0 -94
- package/dist/proto/packets/types/index.d.ts.map +0 -1
- package/dist/proto/packets/types/magic.d.ts +0 -7
- package/dist/proto/packets/types/magic.d.ts.map +0 -1
- package/dist/proto/packets/types/magic.js +0 -14
- package/dist/proto/packets/types/mtu.d.ts +0 -9
- package/dist/proto/packets/types/mtu.d.ts.map +0 -1
- package/dist/proto/packets/types/mtu.js +0 -18
- package/dist/proto/packets/types/sys-address.d.ts +0 -11
- package/dist/proto/packets/types/sys-address.d.ts.map +0 -1
- package/dist/proto/packets/types/sys-address.js +0 -32
- package/dist/proto/packets/unconnected-ping.d.ts +0 -7
- package/dist/proto/packets/unconnected-ping.d.ts.map +0 -1
- package/dist/proto/packets/unconnected-ping.js +0 -38
- package/dist/proto/packets/unconnected-pong.d.ts +0 -8
- package/dist/proto/packets/unconnected-pong.d.ts.map +0 -1
- package/dist/proto/packets/unconnected-pong.js +0 -43
- package/dist/proto/types/advertisement.d.ts.map +0 -1
- package/dist/proto/types/index.d.ts +0 -3
- package/dist/proto/types/index.d.ts.map +0 -1
- package/dist/proto/types/valid.d.ts +0 -4
- package/dist/proto/types/valid.d.ts.map +0 -1
- package/dist/server/server-events.d.ts +0 -9
- package/dist/server/server-events.d.ts.map +0 -1
- package/dist/server/server-options.d.ts +0 -26
- package/dist/server/server-options.d.ts.map +0 -1
- package/dist/server/server-options.js +0 -20
- package/dist/tests/client.d.ts +0 -2
- package/dist/tests/client.d.ts.map +0 -1
- package/dist/tests/client.js +0 -15
- package/dist/tests/localhost.d.ts +0 -2
- package/dist/tests/localhost.d.ts.map +0 -1
- package/dist/tests/localhost.js +0 -34
- package/dist/tests/server.d.ts +0 -2
- package/dist/tests/server.d.ts.map +0 -1
- package/dist/tests/server.js +0 -32
- package/dist/tests/test.d.ts +0 -2
- package/dist/tests/test.d.ts.map +0 -1
- package/dist/tests/test.js +0 -49
- package/dist/utils/Logger.d.ts.map +0 -1
- package/dist/utils/decorators.d.ts +0 -2
- package/dist/utils/decorators.d.ts.map +0 -1
- package/dist/utils/decorators.js +0 -17
- package/dist/utils/index.d.ts +0 -3
- package/dist/utils/index.d.ts.map +0 -1
- package/dist/utils/index.js +0 -18
- package/tsconfig.single.json +0 -9
- /package/dist/{proto/types/valid.js → server/types/connection-events.js} +0 -0
- /package/dist/server/{server-events.js → types/server-events.js} +0 -0
- /package/dist/{utils/Logger.js → shared/logger.js} +0 -0
- /package/dist/{proto → shared/proto}/enums/reliability.d.ts +0 -0
- /package/dist/{proto → shared/proto}/enums/reliability.js +0 -0
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { BasePacket } from "./base-packet";
|
|
2
|
-
import { Frame } from "./types";
|
|
3
|
-
/**
|
|
4
|
-
* https://wiki.vg/Raknet_Protocol#Frame_Set_Packet
|
|
5
|
-
*/
|
|
6
|
-
export declare class Frameset extends BasePacket {
|
|
7
|
-
/** Uint25 Little Endian */
|
|
8
|
-
sequence: number;
|
|
9
|
-
frames: Array<Frame>;
|
|
10
|
-
}
|
|
11
|
-
//# sourceMappingURL=frameset.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"frameset.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/frameset.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAI3C,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC;;GAEG;AACH,qBACa,QAAS,SAAQ,UAAU;IACvC,2BAA2B;IACkB,QAAQ,EAAG,MAAM,CAAC;IACtC,MAAM,EAAG,KAAK,CAAC,KAAK,CAAC,CAAC;CAC/C"}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.Frameset = void 0;
|
|
13
|
-
const base_packet_1 = require("./base-packet");
|
|
14
|
-
const decorators_1 = require("../decorators");
|
|
15
|
-
const enums_1 = require("../enums");
|
|
16
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
/**
|
|
19
|
-
* https://wiki.vg/Raknet_Protocol#Frame_Set_Packet
|
|
20
|
-
*/
|
|
21
|
-
let Frameset = class Frameset extends base_packet_1.BasePacket {
|
|
22
|
-
/** Uint25 Little Endian */
|
|
23
|
-
sequence;
|
|
24
|
-
frames;
|
|
25
|
-
};
|
|
26
|
-
exports.Frameset = Frameset;
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint24, 1 /* Endianness.Little */),
|
|
29
|
-
__metadata("design:type", Number)
|
|
30
|
-
], Frameset.prototype, "sequence", void 0);
|
|
31
|
-
__decorate([
|
|
32
|
-
(0, decorators_1.Serialize)(types_1.Frame),
|
|
33
|
-
__metadata("design:type", Array)
|
|
34
|
-
], Frameset.prototype, "frames", void 0);
|
|
35
|
-
exports.Frameset = Frameset = __decorate([
|
|
36
|
-
(0, decorators_1.Create)(enums_1.Packet.FrameSet)
|
|
37
|
-
], Frameset);
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { BasePacket } from "./base-packet";
|
|
2
|
-
import { Magic } from "./types";
|
|
3
|
-
export declare class IncompatibleProtocolVersion extends BasePacket {
|
|
4
|
-
protocol: number;
|
|
5
|
-
magic: Magic;
|
|
6
|
-
guid: bigint;
|
|
7
|
-
}
|
|
8
|
-
//# sourceMappingURL=incompatible-protocol-version.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"incompatible-protocol-version.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/incompatible-protocol-version.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,qBACa,2BAA4B,SAAQ,UAAU;IACxC,QAAQ,EAAG,MAAM,CAAC;IAClB,KAAK,EAAG,KAAK,CAAC;IACf,IAAI,EAAG,MAAM,CAAC;CAC/B"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.IncompatibleProtocolVersion = void 0;
|
|
13
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
14
|
-
const decorators_1 = require("../decorators");
|
|
15
|
-
const enums_1 = require("../enums");
|
|
16
|
-
const base_packet_1 = require("./base-packet");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
let IncompatibleProtocolVersion = class IncompatibleProtocolVersion extends base_packet_1.BasePacket {
|
|
19
|
-
protocol;
|
|
20
|
-
magic;
|
|
21
|
-
guid;
|
|
22
|
-
};
|
|
23
|
-
exports.IncompatibleProtocolVersion = IncompatibleProtocolVersion;
|
|
24
|
-
__decorate([
|
|
25
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint8),
|
|
26
|
-
__metadata("design:type", Number)
|
|
27
|
-
], IncompatibleProtocolVersion.prototype, "protocol", void 0);
|
|
28
|
-
__decorate([
|
|
29
|
-
(0, decorators_1.Serialize)(types_1.Magic),
|
|
30
|
-
__metadata("design:type", types_1.Magic)
|
|
31
|
-
], IncompatibleProtocolVersion.prototype, "magic", void 0);
|
|
32
|
-
__decorate([
|
|
33
|
-
(0, decorators_1.Serialize)(binarystream_1.Long),
|
|
34
|
-
__metadata("design:type", BigInt)
|
|
35
|
-
], IncompatibleProtocolVersion.prototype, "guid", void 0);
|
|
36
|
-
exports.IncompatibleProtocolVersion = IncompatibleProtocolVersion = __decorate([
|
|
37
|
-
(0, decorators_1.Create)(enums_1.Packet.IncompatibleProtocolVersion)
|
|
38
|
-
], IncompatibleProtocolVersion);
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
export * from "./base-packet";
|
|
2
|
-
export * from "./types";
|
|
3
|
-
export * from "./unconnected-ping";
|
|
4
|
-
export * from "./unconnected-pong";
|
|
5
|
-
export * from "./open-connection-request-one";
|
|
6
|
-
export * from "./open-connection-request-two";
|
|
7
|
-
export * from "./open-connection-reply-one";
|
|
8
|
-
export * from "./open-connection-reply-two";
|
|
9
|
-
export * from "./connection-request";
|
|
10
|
-
export * from "./frameset";
|
|
11
|
-
export * from "./ack";
|
|
12
|
-
export * from "./nack";
|
|
13
|
-
export * from "./connected-ping";
|
|
14
|
-
export * from "./connected-pong";
|
|
15
|
-
export * from "./new-incoming-connection";
|
|
16
|
-
export * from "./connection-request-accepted";
|
|
17
|
-
export * from "./incompatible-protocol-version";
|
|
18
|
-
export * from "./disconnect";
|
|
19
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,iCAAiC,CAAC;AAChD,cAAc,cAAc,CAAC"}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./base-packet"), exports);
|
|
18
|
-
__exportStar(require("./types"), exports);
|
|
19
|
-
__exportStar(require("./unconnected-ping"), exports);
|
|
20
|
-
__exportStar(require("./unconnected-pong"), exports);
|
|
21
|
-
__exportStar(require("./open-connection-request-one"), exports);
|
|
22
|
-
__exportStar(require("./open-connection-request-two"), exports);
|
|
23
|
-
__exportStar(require("./open-connection-reply-one"), exports);
|
|
24
|
-
__exportStar(require("./open-connection-reply-two"), exports);
|
|
25
|
-
__exportStar(require("./connection-request"), exports);
|
|
26
|
-
__exportStar(require("./frameset"), exports);
|
|
27
|
-
__exportStar(require("./ack"), exports);
|
|
28
|
-
__exportStar(require("./nack"), exports);
|
|
29
|
-
__exportStar(require("./connected-ping"), exports);
|
|
30
|
-
__exportStar(require("./connected-pong"), exports);
|
|
31
|
-
__exportStar(require("./new-incoming-connection"), exports);
|
|
32
|
-
__exportStar(require("./connection-request-accepted"), exports);
|
|
33
|
-
__exportStar(require("./incompatible-protocol-version"), exports);
|
|
34
|
-
__exportStar(require("./disconnect"), exports);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"nack.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/nack.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,cACM,IAAK,SAAQ,UAAU;IACrB,SAAS,EAAE,KAAK,CAAC,MAAM,CAAC,CAAM;IAGrB,SAAS,IAAI,MAAM;IAoDnB,WAAW,IAAI,IAAI;CAmBnC;AAED,OAAO,EAAE,IAAI,EAAE,CAAC"}
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var Nack_1;
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.Nack = void 0;
|
|
11
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
12
|
-
const decorators_1 = require("../decorators");
|
|
13
|
-
const enums_1 = require("../enums");
|
|
14
|
-
const base_packet_1 = require("./base-packet");
|
|
15
|
-
let Nack = Nack_1 = class Nack extends base_packet_1.BasePacket {
|
|
16
|
-
sequences = [];
|
|
17
|
-
// Override encode due to custom logic, maybe move into own type?
|
|
18
|
-
serialize() {
|
|
19
|
-
this.writeUint8(Nack_1.id);
|
|
20
|
-
const stream = new binarystream_1.BinaryStream();
|
|
21
|
-
const count = this.sequences.length;
|
|
22
|
-
let records = 0;
|
|
23
|
-
if (count > 0) {
|
|
24
|
-
let cursor = 0;
|
|
25
|
-
let start = this.sequences[0];
|
|
26
|
-
let last = this.sequences[0];
|
|
27
|
-
while (cursor < count) {
|
|
28
|
-
const current = this.sequences[cursor++];
|
|
29
|
-
const diff = current - last;
|
|
30
|
-
if (diff === 1) {
|
|
31
|
-
last = current;
|
|
32
|
-
}
|
|
33
|
-
else if (diff > 1) {
|
|
34
|
-
if (start === last) {
|
|
35
|
-
stream.writeBool(true); // single?
|
|
36
|
-
stream.writeUint24(start, 1 /* Endianness.Little */);
|
|
37
|
-
start = last = current;
|
|
38
|
-
}
|
|
39
|
-
else {
|
|
40
|
-
stream.writeBool(false); // single?
|
|
41
|
-
stream.writeUint24(start, 1 /* Endianness.Little */);
|
|
42
|
-
stream.writeUint24(last, 1 /* Endianness.Little */);
|
|
43
|
-
start = last = current;
|
|
44
|
-
}
|
|
45
|
-
++records;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
// last iteration
|
|
49
|
-
if (start === last) {
|
|
50
|
-
stream.writeBool(true); // single?
|
|
51
|
-
stream.writeUint24(start, 1 /* Endianness.Little */);
|
|
52
|
-
}
|
|
53
|
-
else {
|
|
54
|
-
stream.writeBool(false); // single?
|
|
55
|
-
stream.writeUint24(start, 1 /* Endianness.Little */);
|
|
56
|
-
stream.writeUint24(last, 1 /* Endianness.Little */);
|
|
57
|
-
}
|
|
58
|
-
++records;
|
|
59
|
-
this.writeUShort(records);
|
|
60
|
-
this.writeBuffer(stream.getBuffer());
|
|
61
|
-
}
|
|
62
|
-
return this.getBuffer();
|
|
63
|
-
}
|
|
64
|
-
// Override decode due to custom logic, maybe move into own type?
|
|
65
|
-
deserialize() {
|
|
66
|
-
this.readUint8();
|
|
67
|
-
this.sequences = [];
|
|
68
|
-
const recordCount = this.readUShort();
|
|
69
|
-
for (let index = 0; index < recordCount; index++) {
|
|
70
|
-
const range = this.readBool(); // False for range, True for no range
|
|
71
|
-
if (range) {
|
|
72
|
-
this.sequences.push(this.readUint24(1 /* Endianness.Little */));
|
|
73
|
-
}
|
|
74
|
-
else {
|
|
75
|
-
const start = this.readUint24(1 /* Endianness.Little */);
|
|
76
|
-
const end = this.readUint24(1 /* Endianness.Little */);
|
|
77
|
-
for (let index = start; index <= end; index++) {
|
|
78
|
-
this.sequences.push(index);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
return this;
|
|
83
|
-
}
|
|
84
|
-
};
|
|
85
|
-
exports.Nack = Nack;
|
|
86
|
-
exports.Nack = Nack = Nack_1 = __decorate([
|
|
87
|
-
(0, decorators_1.Create)(enums_1.Packet.Nack)
|
|
88
|
-
], Nack);
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Address } from "./types";
|
|
2
|
-
import { BasePacket } from "./base-packet";
|
|
3
|
-
export declare class NewIncomingConnection extends BasePacket {
|
|
4
|
-
serverAddress: Address;
|
|
5
|
-
internalAddresses: Address[];
|
|
6
|
-
incomingTimestamp: bigint;
|
|
7
|
-
serverTimestamp: bigint;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=new-incoming-connection.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"new-incoming-connection.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/new-incoming-connection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAiB,MAAM,SAAS,CAAC;AAKjD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,qBACa,qBAAsB,SAAQ,UAAU;IACzB,aAAa,EAAG,OAAO,CAAC;IAClB,iBAAiB,EAAE,OAAO,EAAE,CAAM;IAC3C,iBAAiB,EAAG,MAAM,CAAC;IAC3B,eAAe,EAAG,MAAM,CAAC;CACjD"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.NewIncomingConnection = void 0;
|
|
13
|
-
const types_1 = require("./types");
|
|
14
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
15
|
-
const decorators_1 = require("../decorators");
|
|
16
|
-
const enums_1 = require("../enums");
|
|
17
|
-
const base_packet_1 = require("./base-packet");
|
|
18
|
-
let NewIncomingConnection = class NewIncomingConnection extends base_packet_1.BasePacket {
|
|
19
|
-
serverAddress;
|
|
20
|
-
internalAddresses = [];
|
|
21
|
-
incomingTimestamp;
|
|
22
|
-
serverTimestamp;
|
|
23
|
-
};
|
|
24
|
-
exports.NewIncomingConnection = NewIncomingConnection;
|
|
25
|
-
__decorate([
|
|
26
|
-
(0, decorators_1.Serialize)(types_1.Address),
|
|
27
|
-
__metadata("design:type", types_1.Address)
|
|
28
|
-
], NewIncomingConnection.prototype, "serverAddress", void 0);
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, decorators_1.Serialize)(types_1.SystemAddress),
|
|
31
|
-
__metadata("design:type", Array)
|
|
32
|
-
], NewIncomingConnection.prototype, "internalAddresses", void 0);
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, decorators_1.Serialize)(binarystream_1.Long),
|
|
35
|
-
__metadata("design:type", BigInt)
|
|
36
|
-
], NewIncomingConnection.prototype, "incomingTimestamp", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, decorators_1.Serialize)(binarystream_1.Long),
|
|
39
|
-
__metadata("design:type", BigInt)
|
|
40
|
-
], NewIncomingConnection.prototype, "serverTimestamp", void 0);
|
|
41
|
-
exports.NewIncomingConnection = NewIncomingConnection = __decorate([
|
|
42
|
-
(0, decorators_1.Create)(enums_1.Packet.NewIncomingConnection)
|
|
43
|
-
], NewIncomingConnection);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"open-connection-reply-one.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/open-connection-reply-one.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAe3C,qBACa,sBAAuB,SAAQ,UAAU;IAC5B,KAAK,EAAG,MAAM,CAAC;IAChB,UAAU,EAAG,MAAM,CAAC;IACpB,iBAAiB,EAAG,OAAO,CAAC;IAC1B,GAAG,EAAG,MAAM,CAAC;CACvC"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.OpenConnectionReplyOne = void 0;
|
|
13
|
-
const base_packet_1 = require("./base-packet");
|
|
14
|
-
const enums_1 = require("../enums");
|
|
15
|
-
const decorators_1 = require("../decorators");
|
|
16
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
let OpenConnectionReplyOne = class OpenConnectionReplyOne extends base_packet_1.BasePacket {
|
|
19
|
-
magic;
|
|
20
|
-
serverGuid;
|
|
21
|
-
serverHasSecurity;
|
|
22
|
-
mtu;
|
|
23
|
-
};
|
|
24
|
-
exports.OpenConnectionReplyOne = OpenConnectionReplyOne;
|
|
25
|
-
__decorate([
|
|
26
|
-
(0, decorators_1.Serialize)(types_1.Magic),
|
|
27
|
-
__metadata("design:type", Buffer)
|
|
28
|
-
], OpenConnectionReplyOne.prototype, "magic", void 0);
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, decorators_1.Serialize)(binarystream_1.Long),
|
|
31
|
-
__metadata("design:type", BigInt)
|
|
32
|
-
], OpenConnectionReplyOne.prototype, "serverGuid", void 0);
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, decorators_1.Serialize)(binarystream_1.Bool),
|
|
35
|
-
__metadata("design:type", Boolean)
|
|
36
|
-
], OpenConnectionReplyOne.prototype, "serverHasSecurity", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint16),
|
|
39
|
-
__metadata("design:type", Number)
|
|
40
|
-
], OpenConnectionReplyOne.prototype, "mtu", void 0);
|
|
41
|
-
exports.OpenConnectionReplyOne = OpenConnectionReplyOne = __decorate([
|
|
42
|
-
(0, decorators_1.Create)(enums_1.Packet.OpenConnectionReplyOne)
|
|
43
|
-
], OpenConnectionReplyOne);
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BasePacket } from "./base-packet";
|
|
2
|
-
import { Address, Magic } from "./types";
|
|
3
|
-
export declare class OpenConnectionReplyTwo extends BasePacket {
|
|
4
|
-
magic: Magic;
|
|
5
|
-
serverGuid: bigint;
|
|
6
|
-
clientAddress: Address;
|
|
7
|
-
mtu: number;
|
|
8
|
-
encryptionEnabled: boolean;
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=open-connection-reply-two.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"open-connection-reply-two.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/open-connection-reply-two.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEzC,qBACa,sBAAuB,SAAQ,UAAU;IAC5B,KAAK,EAAG,KAAK,CAAC;IACf,UAAU,EAAG,MAAM,CAAC;IACjB,aAAa,EAAG,OAAO,CAAC;IACzB,GAAG,EAAG,MAAM,CAAC;IACf,iBAAiB,EAAG,OAAO,CAAC;CACpD"}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.OpenConnectionReplyTwo = void 0;
|
|
13
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
14
|
-
const decorators_1 = require("../decorators");
|
|
15
|
-
const enums_1 = require("../enums");
|
|
16
|
-
const base_packet_1 = require("./base-packet");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
let OpenConnectionReplyTwo = class OpenConnectionReplyTwo extends base_packet_1.BasePacket {
|
|
19
|
-
magic;
|
|
20
|
-
serverGuid;
|
|
21
|
-
clientAddress;
|
|
22
|
-
mtu;
|
|
23
|
-
encryptionEnabled;
|
|
24
|
-
};
|
|
25
|
-
exports.OpenConnectionReplyTwo = OpenConnectionReplyTwo;
|
|
26
|
-
__decorate([
|
|
27
|
-
(0, decorators_1.Serialize)(types_1.Magic),
|
|
28
|
-
__metadata("design:type", types_1.Magic)
|
|
29
|
-
], OpenConnectionReplyTwo.prototype, "magic", void 0);
|
|
30
|
-
__decorate([
|
|
31
|
-
(0, decorators_1.Serialize)(binarystream_1.Long),
|
|
32
|
-
__metadata("design:type", BigInt)
|
|
33
|
-
], OpenConnectionReplyTwo.prototype, "serverGuid", void 0);
|
|
34
|
-
__decorate([
|
|
35
|
-
(0, decorators_1.Serialize)(types_1.Address),
|
|
36
|
-
__metadata("design:type", types_1.Address)
|
|
37
|
-
], OpenConnectionReplyTwo.prototype, "clientAddress", void 0);
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint16),
|
|
40
|
-
__metadata("design:type", Number)
|
|
41
|
-
], OpenConnectionReplyTwo.prototype, "mtu", void 0);
|
|
42
|
-
__decorate([
|
|
43
|
-
(0, decorators_1.Serialize)(binarystream_1.Bool),
|
|
44
|
-
__metadata("design:type", Boolean)
|
|
45
|
-
], OpenConnectionReplyTwo.prototype, "encryptionEnabled", void 0);
|
|
46
|
-
exports.OpenConnectionReplyTwo = OpenConnectionReplyTwo = __decorate([
|
|
47
|
-
(0, decorators_1.Create)(enums_1.Packet.OpenConnectionReplyTwo)
|
|
48
|
-
], OpenConnectionReplyTwo);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"open-connection-request-one.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/open-connection-request-one.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAG3C,qBACa,wBAAyB,SAAQ,UAAU;IAC9B,KAAK,EAAG,MAAM,CAAC;IACf,QAAQ,EAAG,MAAM,CAAC;IACpB,GAAG,EAAG,MAAM,CAAC;CACpC"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.OpenConnectionRequestOne = void 0;
|
|
13
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
14
|
-
const decorators_1 = require("../decorators");
|
|
15
|
-
const enums_1 = require("../enums");
|
|
16
|
-
const base_packet_1 = require("./base-packet");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
let OpenConnectionRequestOne = class OpenConnectionRequestOne extends base_packet_1.BasePacket {
|
|
19
|
-
magic;
|
|
20
|
-
protocol;
|
|
21
|
-
mtu;
|
|
22
|
-
};
|
|
23
|
-
exports.OpenConnectionRequestOne = OpenConnectionRequestOne;
|
|
24
|
-
__decorate([
|
|
25
|
-
(0, decorators_1.Serialize)(types_1.Magic),
|
|
26
|
-
__metadata("design:type", Buffer)
|
|
27
|
-
], OpenConnectionRequestOne.prototype, "magic", void 0);
|
|
28
|
-
__decorate([
|
|
29
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint8),
|
|
30
|
-
__metadata("design:type", Number)
|
|
31
|
-
], OpenConnectionRequestOne.prototype, "protocol", void 0);
|
|
32
|
-
__decorate([
|
|
33
|
-
(0, decorators_1.Serialize)(types_1.MTU),
|
|
34
|
-
__metadata("design:type", Number)
|
|
35
|
-
], OpenConnectionRequestOne.prototype, "mtu", void 0);
|
|
36
|
-
exports.OpenConnectionRequestOne = OpenConnectionRequestOne = __decorate([
|
|
37
|
-
(0, decorators_1.Create)(enums_1.Packet.OpenConnectionRequestOne)
|
|
38
|
-
], OpenConnectionRequestOne);
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { BasePacket } from "./base-packet";
|
|
2
|
-
import { Address } from "./types";
|
|
3
|
-
export declare class OpenConnectionRequestTwo extends BasePacket {
|
|
4
|
-
magic: Buffer;
|
|
5
|
-
address: Address;
|
|
6
|
-
mtu: number;
|
|
7
|
-
clientGuid: bigint;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=open-connection-request-two.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"open-connection-request-two.d.ts","sourceRoot":"","sources":["../../../src/proto/packets/open-connection-request-two.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAI3C,OAAO,EAAE,OAAO,EAAS,MAAM,SAAS,CAAC;AAEzC,qBACa,wBAAyB,SAAQ,UAAU;IAC9B,KAAK,EAAG,MAAM,CAAC;IACb,OAAO,EAAG,OAAO,CAAC;IACnB,GAAG,EAAG,MAAM,CAAC;IACb,UAAU,EAAG,MAAM,CAAC;CAC9C"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.OpenConnectionRequestTwo = void 0;
|
|
13
|
-
const base_packet_1 = require("./base-packet");
|
|
14
|
-
const enums_1 = require("../enums");
|
|
15
|
-
const decorators_1 = require("../decorators");
|
|
16
|
-
const binarystream_1 = require("@serenityjs/binarystream");
|
|
17
|
-
const types_1 = require("./types");
|
|
18
|
-
let OpenConnectionRequestTwo = class OpenConnectionRequestTwo extends base_packet_1.BasePacket {
|
|
19
|
-
magic;
|
|
20
|
-
address;
|
|
21
|
-
mtu;
|
|
22
|
-
clientGuid;
|
|
23
|
-
};
|
|
24
|
-
exports.OpenConnectionRequestTwo = OpenConnectionRequestTwo;
|
|
25
|
-
__decorate([
|
|
26
|
-
(0, decorators_1.Serialize)(types_1.Magic),
|
|
27
|
-
__metadata("design:type", Buffer)
|
|
28
|
-
], OpenConnectionRequestTwo.prototype, "magic", void 0);
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, decorators_1.Serialize)(types_1.Address),
|
|
31
|
-
__metadata("design:type", types_1.Address)
|
|
32
|
-
], OpenConnectionRequestTwo.prototype, "address", void 0);
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint16),
|
|
35
|
-
__metadata("design:type", Number)
|
|
36
|
-
], OpenConnectionRequestTwo.prototype, "mtu", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, decorators_1.Serialize)(binarystream_1.Uint64),
|
|
39
|
-
__metadata("design:type", BigInt)
|
|
40
|
-
], OpenConnectionRequestTwo.prototype, "clientGuid", void 0);
|
|
41
|
-
exports.OpenConnectionRequestTwo = OpenConnectionRequestTwo = __decorate([
|
|
42
|
-
(0, decorators_1.Create)(enums_1.Packet.OpenConnectionRequestTwo)
|
|
43
|
-
], OpenConnectionRequestTwo);
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import type { BinaryStream } from "@serenityjs/binarystream";
|
|
2
|
-
import { DataType } from "./data-type";
|
|
3
|
-
import type { RemoteInfo } from "node:dgram";
|
|
4
|
-
/**
|
|
5
|
-
* Represents an address data type.
|
|
6
|
-
* Address is used when establishing a connection in RakNet.
|
|
7
|
-
*/
|
|
8
|
-
export declare class Address extends DataType {
|
|
9
|
-
/**
|
|
10
|
-
* The address of the data type.
|
|
11
|
-
*/
|
|
12
|
-
address: string;
|
|
13
|
-
/**
|
|
14
|
-
* The port of the data type.
|
|
15
|
-
*/
|
|
16
|
-
port: number;
|
|
17
|
-
/**
|
|
18
|
-
* The version of the data type.
|
|
19
|
-
*/
|
|
20
|
-
version: number;
|
|
21
|
-
/**
|
|
22
|
-
* Initializes a new instance of the Address data type.
|
|
23
|
-
* @param address The address of the data type.
|
|
24
|
-
* @param port The port of the data type.
|
|
25
|
-
* @param version The version of the data type.
|
|
26
|
-
*/
|
|
27
|
-
constructor(address: string, port: number, version: number);
|
|
28
|
-
/**
|
|
29
|
-
* Converts the Address data type to a NetworkIdentifier.
|
|
30
|
-
*
|
|
31
|
-
* @param identifier The NetworkIdentifier.
|
|
32
|
-
* @returns The NetworkIdentifier.
|
|
33
|
-
*/
|
|
34
|
-
static fromIdentifier(identifier: RemoteInfo): Address;
|
|
35
|
-
/**
|
|
36
|
-
* Writes the Address data type to a binary stream.
|
|
37
|
-
* @param stream The binary stream to write to.
|
|
38
|
-
* @param value The value to write.
|
|
39
|
-
*/
|
|
40
|
-
static write(stream: BinaryStream, value: Address): void;
|
|
41
|
-
/**
|
|
42
|
-
* Reads the Address data type from a binary stream.
|
|
43
|
-
* @param stream The binary stream to read from.
|
|
44
|
-
* @returns The Address data type.
|
|
45
|
-
*/
|
|
46
|
-
static read(stream: BinaryStream): Address;
|
|
47
|
-
}
|
|
48
|
-
//# sourceMappingURL=address.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"address.d.ts","sourceRoot":"","sources":["../../../../src/proto/packets/types/address.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C;;;GAGG;AACH,qBAAa,OAAQ,SAAQ,QAAQ;IACpC;;OAEG;IACI,OAAO,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACI,IAAI,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACI,OAAO,EAAE,MAAM,CAAC;IAEvB;;;;;OAKG;gBACgB,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM;IAOjE;;;;;OAKG;WACW,cAAc,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO;IAQ7D;;;;OAIG;WACW,KAAK,CAAC,MAAM,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI;IAqB/D;;;;OAIG;WACW,IAAI,CAAC,MAAM,EAAE,YAAY,GAAG,OAAO;CAuBjD"}
|