overlay-toolkit 0.12.0 → 0.13.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/helper.d.ts +2 -0
- package/dist/memory.d.ts +49 -0
- package/dist/otk.d.ts +33 -2
- package/dist/overlay-toolkit.js +346 -234
- package/dist/overlay-toolkit.umd.cjs +1 -1
- package/package.json +4 -1
package/dist/overlay-toolkit.js
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
var w = Object.defineProperty;
|
|
2
2
|
var y = (r, s, e) => s in r ? w(r, s, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[s] = e;
|
|
3
3
|
var t = (r, s, e) => y(r, typeof s != "symbol" ? s + "" : s, e);
|
|
4
|
+
function u(r) {
|
|
5
|
+
let s = null;
|
|
6
|
+
return r instanceof ArrayBuffer ? s = new Uint8Array(r) : s = new Uint8Array(r.buffer, r.byteOffset, r.byteLength), [...s].map((e) => e.toString(16).padStart(2, "0")).join("");
|
|
7
|
+
}
|
|
8
|
+
function o(r) {
|
|
9
|
+
const s = new Uint8Array(Math.ceil(r.length / 2));
|
|
10
|
+
for (let e = 0; e < r.length; )
|
|
11
|
+
s[e / 2] = Number.parseInt(r.slice(e, e += 2), 16);
|
|
12
|
+
return s;
|
|
13
|
+
}
|
|
4
14
|
function f(r) {
|
|
5
15
|
return new v(r);
|
|
6
16
|
}
|
|
@@ -20,12 +30,12 @@ class v extends EventTarget {
|
|
|
20
30
|
async getDevices() {
|
|
21
31
|
const e = await this.requestGetDevices();
|
|
22
32
|
let a = [];
|
|
23
|
-
return e.forEach((
|
|
24
|
-
if (this.devices.has(
|
|
25
|
-
a.push(this.devices.get(
|
|
33
|
+
return e.forEach((n) => {
|
|
34
|
+
if (this.devices.has(n.instanceId))
|
|
35
|
+
a.push(this.devices.get(n.instanceId));
|
|
26
36
|
else {
|
|
27
|
-
const c = new
|
|
28
|
-
this.devices.set(
|
|
37
|
+
const c = new I(this.api, n);
|
|
38
|
+
this.devices.set(n.instanceId, c), a.push(c);
|
|
29
39
|
}
|
|
30
40
|
}), a;
|
|
31
41
|
}
|
|
@@ -33,30 +43,30 @@ class v extends EventTarget {
|
|
|
33
43
|
return e && console.log("Requesting device with options:", e), this.getDevices();
|
|
34
44
|
}
|
|
35
45
|
async requestGetDevices() {
|
|
36
|
-
return (await
|
|
46
|
+
return (await l(this.api, "getDevices", {})).devices;
|
|
37
47
|
}
|
|
38
48
|
addListener() {
|
|
39
49
|
this.api.addOverlayListener("otk::hid::inputreport", (e) => this.callbackInputReport(e)), this.api.addOverlayListener("otk::hid::devicechanged", (e) => this.callbackDeviceChanged(e));
|
|
40
50
|
}
|
|
41
51
|
callbackInputReport(e) {
|
|
42
|
-
const a = e.instanceId,
|
|
43
|
-
c ? c.dispatchEvent(new k("inputreport", c,
|
|
52
|
+
const a = e.instanceId, n = o(e.data), c = this.devices.get(a);
|
|
53
|
+
c ? c.dispatchEvent(new k("inputreport", c, n[0], new DataView(n.buffer, 1))) : console.warn("Device not found:", a);
|
|
44
54
|
}
|
|
45
55
|
callbackDeviceChanged(e) {
|
|
46
56
|
var a = e.add;
|
|
47
|
-
const
|
|
57
|
+
const n = new I(this.api, e.device), c = new b(a ? "connect" : "disconnect", n);
|
|
48
58
|
this.dispatchEvent(c);
|
|
49
59
|
}
|
|
50
60
|
}
|
|
51
|
-
async function
|
|
61
|
+
async function l(r, s, e) {
|
|
52
62
|
const a = {
|
|
53
63
|
call: "otk::hid",
|
|
54
64
|
type: s,
|
|
55
65
|
...e
|
|
56
|
-
},
|
|
57
|
-
return
|
|
66
|
+
}, n = await r.callOverlayHandler(a);
|
|
67
|
+
return n.error && console.log("callOverlayHID error:", s, e, n), n;
|
|
58
68
|
}
|
|
59
|
-
class
|
|
69
|
+
class I extends EventTarget {
|
|
60
70
|
//#endregion
|
|
61
71
|
// Simulate a device with some properties
|
|
62
72
|
constructor(e, a) {
|
|
@@ -103,17 +113,17 @@ class d extends EventTarget {
|
|
|
103
113
|
throw new Error("Device is not opened.");
|
|
104
114
|
const a = await this.request("recvFeature", {
|
|
105
115
|
reportId: e
|
|
106
|
-
}),
|
|
107
|
-
return new DataView(
|
|
116
|
+
}), n = o(a.data);
|
|
117
|
+
return new DataView(n.buffer);
|
|
108
118
|
}
|
|
109
119
|
async request(e, a) {
|
|
110
|
-
return
|
|
120
|
+
return l(this.api, e, {
|
|
111
121
|
instanceId: this.instanceId,
|
|
112
122
|
...a
|
|
113
123
|
});
|
|
114
124
|
}
|
|
115
125
|
}
|
|
116
|
-
class
|
|
126
|
+
class b extends Event {
|
|
117
127
|
constructor(e, a) {
|
|
118
128
|
super(e);
|
|
119
129
|
t(this, "device");
|
|
@@ -121,25 +131,15 @@ class x extends Event {
|
|
|
121
131
|
}
|
|
122
132
|
}
|
|
123
133
|
class k extends Event {
|
|
124
|
-
constructor(e, a,
|
|
134
|
+
constructor(e, a, n, c) {
|
|
125
135
|
super(e);
|
|
126
136
|
t(this, "device");
|
|
127
137
|
t(this, "reportId");
|
|
128
138
|
t(this, "data");
|
|
129
|
-
this.device = a, this.reportId =
|
|
139
|
+
this.device = a, this.reportId = n, this.data = c;
|
|
130
140
|
}
|
|
131
141
|
}
|
|
132
|
-
|
|
133
|
-
let s = null;
|
|
134
|
-
return r instanceof ArrayBuffer ? s = new Uint8Array(r) : s = new Uint8Array(r.buffer, r.byteOffset, r.byteLength), [...s].map((e) => e.toString(16).padStart(2, "0")).join("");
|
|
135
|
-
}
|
|
136
|
-
function l(r) {
|
|
137
|
-
const s = new Uint8Array(Math.ceil(r.length / 2));
|
|
138
|
-
for (let e = 0; e < r.length; )
|
|
139
|
-
s[e / 2] = Number.parseInt(r.slice(e, e += 2), 16);
|
|
140
|
-
return s;
|
|
141
|
-
}
|
|
142
|
-
class D {
|
|
142
|
+
class x {
|
|
143
143
|
constructor(s = null) {
|
|
144
144
|
t(this, "subscribers", /* @__PURE__ */ new Map());
|
|
145
145
|
t(this, "queue", []);
|
|
@@ -170,8 +170,8 @@ class D {
|
|
|
170
170
|
a.length = 0;
|
|
171
171
|
return;
|
|
172
172
|
}
|
|
173
|
-
const
|
|
174
|
-
|
|
173
|
+
const n = a.indexOf(e);
|
|
174
|
+
n !== -1 && a.splice(n, 1);
|
|
175
175
|
}
|
|
176
176
|
async callOverlayHandler(s) {
|
|
177
177
|
return !this.transport || !this.transport.connected ? (console.warn("OverlayPluginAPI: Transport not connected, queuing message", s), new Promise((a) => {
|
|
@@ -204,7 +204,7 @@ class D {
|
|
|
204
204
|
return ((s = this.transport) == null ? void 0 : s.connected) ?? !1;
|
|
205
205
|
}
|
|
206
206
|
}
|
|
207
|
-
class
|
|
207
|
+
class D extends EventTarget {
|
|
208
208
|
constructor() {
|
|
209
209
|
super(...arguments);
|
|
210
210
|
t(this, "connected", !1);
|
|
@@ -217,7 +217,7 @@ class P extends EventTarget {
|
|
|
217
217
|
}
|
|
218
218
|
sendMessage(e) {
|
|
219
219
|
return new Promise((a) => {
|
|
220
|
-
window.OverlayPluginApi.callHandler(JSON.stringify(e), (
|
|
220
|
+
window.OverlayPluginApi.callHandler(JSON.stringify(e), (n) => a(JSON.parse(n)));
|
|
221
221
|
});
|
|
222
222
|
}
|
|
223
223
|
waitForApi() {
|
|
@@ -228,7 +228,7 @@ class P extends EventTarget {
|
|
|
228
228
|
window.__OverlayCallback = this.evtHandlerWrapper, this.connected = !0, this.dispatchEvent(new Event("connected"));
|
|
229
229
|
}
|
|
230
230
|
}
|
|
231
|
-
class
|
|
231
|
+
class P extends EventTarget {
|
|
232
232
|
constructor(e) {
|
|
233
233
|
super();
|
|
234
234
|
t(this, "ws");
|
|
@@ -252,8 +252,8 @@ class b extends EventTarget {
|
|
|
252
252
|
try {
|
|
253
253
|
const a = JSON.parse(e.data);
|
|
254
254
|
if ("rseq" in a) {
|
|
255
|
-
const
|
|
256
|
-
this.responseResolvers.has(
|
|
255
|
+
const n = a.rseq;
|
|
256
|
+
this.responseResolvers.has(n) && (this.responseResolvers.get(n)(a), this.responseResolvers.delete(n));
|
|
257
257
|
} else
|
|
258
258
|
this.dispatchEvent(new CustomEvent("message", { detail: a }));
|
|
259
259
|
} catch {
|
|
@@ -270,8 +270,8 @@ class b extends EventTarget {
|
|
|
270
270
|
}
|
|
271
271
|
sendMessage(e) {
|
|
272
272
|
const a = this.sequence++;
|
|
273
|
-
return e.rseq = a, new Promise((
|
|
274
|
-
this.responseResolvers.set(a,
|
|
273
|
+
return e.rseq = a, new Promise((n) => {
|
|
274
|
+
this.responseResolvers.set(a, n), this.ws.send(JSON.stringify(e));
|
|
275
275
|
});
|
|
276
276
|
}
|
|
277
277
|
set eventHandler(e) {
|
|
@@ -282,20 +282,20 @@ const N = (r) => ({
|
|
|
282
282
|
call: "otk::filesystem",
|
|
283
283
|
action: "show_save_file_picker",
|
|
284
284
|
options: r
|
|
285
|
-
}),
|
|
285
|
+
}), E = (r) => ({
|
|
286
286
|
call: "otk::filesystem",
|
|
287
287
|
action: "show_open_file_picker",
|
|
288
288
|
options: r
|
|
289
|
-
}),
|
|
289
|
+
}), F = (r) => ({
|
|
290
290
|
call: "otk::filesystem",
|
|
291
291
|
action: "file_info",
|
|
292
292
|
handle: r
|
|
293
|
-
}),
|
|
293
|
+
}), m = (r, s) => ({
|
|
294
294
|
call: "otk::filesystem",
|
|
295
295
|
action: "read_file",
|
|
296
296
|
handle: r,
|
|
297
297
|
binary: s
|
|
298
|
-
}),
|
|
298
|
+
}), C = (r, s) => ({
|
|
299
299
|
call: "otk::filesystem",
|
|
300
300
|
action: "open_write",
|
|
301
301
|
handle: r,
|
|
@@ -306,7 +306,7 @@ const N = (r) => ({
|
|
|
306
306
|
handle: r,
|
|
307
307
|
data: typeof s == "string" ? s : btoa(String.fromCharCode(...new Uint8Array(s))),
|
|
308
308
|
binary: typeof s != "string"
|
|
309
|
-
}),
|
|
309
|
+
}), d = (r, s, e) => ({
|
|
310
310
|
call: "otk::filesystem",
|
|
311
311
|
action: "file_op",
|
|
312
312
|
handle: r,
|
|
@@ -337,7 +337,7 @@ class H {
|
|
|
337
337
|
* @returns A promise that resolves to an array of FileSystemFileHandle for the selected files
|
|
338
338
|
*/
|
|
339
339
|
async showOpenFilePicker(s) {
|
|
340
|
-
const e = await this.api.callOverlayHandler(
|
|
340
|
+
const e = await this.api.callOverlayHandler(E(s));
|
|
341
341
|
if (e.aborted)
|
|
342
342
|
throw DOMException.ABORT_ERR;
|
|
343
343
|
if (e && e.files && Array.isArray(e.files))
|
|
@@ -354,13 +354,13 @@ class p {
|
|
|
354
354
|
this.api = s, this.handle = e, this.name = a;
|
|
355
355
|
}
|
|
356
356
|
async createWritable(s) {
|
|
357
|
-
const e = await this.api.callOverlayHandler(
|
|
357
|
+
const e = await this.api.callOverlayHandler(C(this.handle, s == null ? void 0 : s.keepExistingData));
|
|
358
358
|
if (e && e.handle)
|
|
359
359
|
return new T(this.api, e.handle);
|
|
360
360
|
throw new Error(e.Error ?? "Failed to create writable stream");
|
|
361
361
|
}
|
|
362
362
|
async getFile() {
|
|
363
|
-
const s = await this.api.callOverlayHandler(
|
|
363
|
+
const s = await this.api.callOverlayHandler(F(this.handle));
|
|
364
364
|
if (s && s.handle && s.name)
|
|
365
365
|
return new O(this.api, s);
|
|
366
366
|
throw new Error(s.Error ?? "Failed to get file");
|
|
@@ -384,13 +384,13 @@ class O {
|
|
|
384
384
|
return this.bytes().then((s) => s.buffer);
|
|
385
385
|
}
|
|
386
386
|
async bytes() {
|
|
387
|
-
const s = await this.api.callOverlayHandler(
|
|
387
|
+
const s = await this.api.callOverlayHandler(m(this.handle, !0));
|
|
388
388
|
if (s && s.data)
|
|
389
389
|
return Uint8Array.from(atob(s.data), (e) => e.charCodeAt(0));
|
|
390
390
|
throw new Error(s.Error ?? "Failed to read file");
|
|
391
391
|
}
|
|
392
392
|
async text() {
|
|
393
|
-
const s = await this.api.callOverlayHandler(
|
|
393
|
+
const s = await this.api.callOverlayHandler(m(this.handle, !1));
|
|
394
394
|
if (s && s.text)
|
|
395
395
|
return s.text;
|
|
396
396
|
throw new Error(s.Error ?? "Failed to read file");
|
|
@@ -410,10 +410,10 @@ class T {
|
|
|
410
410
|
this.api = s, this.handle = e;
|
|
411
411
|
}
|
|
412
412
|
seek(s) {
|
|
413
|
-
return this.api.callOverlayHandler(
|
|
413
|
+
return this.api.callOverlayHandler(d(this.handle, "seek", s));
|
|
414
414
|
}
|
|
415
415
|
truncate(s) {
|
|
416
|
-
return this.api.callOverlayHandler(
|
|
416
|
+
return this.api.callOverlayHandler(d(this.handle, "truncate", s));
|
|
417
417
|
}
|
|
418
418
|
writeData(s) {
|
|
419
419
|
return this.api.callOverlayHandler(M(this.handle, s));
|
|
@@ -422,7 +422,7 @@ class T {
|
|
|
422
422
|
return typeof s == "string" || s instanceof ArrayBuffer ? this.writeData(s) : s instanceof Uint8Array ? this.writeData(s.buffer) : s instanceof Blob ? s.arrayBuffer().then((e) => this.writeData(e)) : Promise.reject(new Error("Unsupported data type for writing"));
|
|
423
423
|
}
|
|
424
424
|
close() {
|
|
425
|
-
return this.api.callOverlayHandler(
|
|
425
|
+
return this.api.callOverlayHandler(d(this.handle, "close"));
|
|
426
426
|
}
|
|
427
427
|
abort(s) {
|
|
428
428
|
throw new Error("Method not implemented.");
|
|
@@ -432,6 +432,75 @@ class T {
|
|
|
432
432
|
}
|
|
433
433
|
}
|
|
434
434
|
class S {
|
|
435
|
+
constructor(s) {
|
|
436
|
+
t(this, "addr");
|
|
437
|
+
t(this, "base");
|
|
438
|
+
t(this, "bytes");
|
|
439
|
+
t(this, "mask");
|
|
440
|
+
this.addr = s.addr, this.base = s.base, this.valid ? (this.bytes = o(s.bytes), this.mask = s.mask) : (this.bytes = new Uint8Array(), this.mask = []);
|
|
441
|
+
}
|
|
442
|
+
get valid() {
|
|
443
|
+
return !!this.addr;
|
|
444
|
+
}
|
|
445
|
+
getNthRange(s) {
|
|
446
|
+
let e = 0;
|
|
447
|
+
for (let a = 0; a < this.mask.length; a++)
|
|
448
|
+
if (!this.mask[a]) {
|
|
449
|
+
let n;
|
|
450
|
+
for (n = a; n < this.mask.length && !this.mask[n]; n++) ;
|
|
451
|
+
if (e == s)
|
|
452
|
+
return { begin: a, end: n };
|
|
453
|
+
e++, a = n;
|
|
454
|
+
}
|
|
455
|
+
return { begin: 0, end: 0 };
|
|
456
|
+
}
|
|
457
|
+
/**
|
|
458
|
+
* get nth masked (??) data
|
|
459
|
+
* @param index
|
|
460
|
+
* @returns data slice
|
|
461
|
+
*/
|
|
462
|
+
getNthMasked(s) {
|
|
463
|
+
let e = this.getNthRange(s);
|
|
464
|
+
return e.end > e.begin ? this.bytes.slice(e.begin, e.end) : null;
|
|
465
|
+
}
|
|
466
|
+
/**
|
|
467
|
+
* get nth masked (??) data in DataView
|
|
468
|
+
* @param index
|
|
469
|
+
* @returns dataview
|
|
470
|
+
*/
|
|
471
|
+
getDataView(s) {
|
|
472
|
+
let e = this.getNthRange(s);
|
|
473
|
+
return e.end > e.begin ? new DataView(this.bytes.buffer, this.bytes.byteOffset + e.begin, Math.min(this.bytes.byteLength, e.end - e.begin)) : null;
|
|
474
|
+
}
|
|
475
|
+
/**
|
|
476
|
+
* get relative pointer to another object, usually LEA, call, ...
|
|
477
|
+
* @param index
|
|
478
|
+
* @returns
|
|
479
|
+
*/
|
|
480
|
+
getRelativePointer(s) {
|
|
481
|
+
let e = this.getNthRange(s);
|
|
482
|
+
if (e.end <= e.begin)
|
|
483
|
+
return 0;
|
|
484
|
+
const n = new DataView(this.bytes.buffer, this.bytes.byteOffset, this.bytes.byteLength).getInt32(e.begin, !0);
|
|
485
|
+
return this.addr + n + e.begin + 4;
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
class A {
|
|
489
|
+
constructor(s) {
|
|
490
|
+
t(this, "addr");
|
|
491
|
+
t(this, "length");
|
|
492
|
+
t(this, "bytes");
|
|
493
|
+
t(this, "value");
|
|
494
|
+
this.addr = s.addr, this.length = s.len, this.valid ? (this.bytes = o(s.bytes), this.value = s.value) : this.bytes = new Uint8Array();
|
|
495
|
+
}
|
|
496
|
+
get valid() {
|
|
497
|
+
return !!this.addr && !!this.length;
|
|
498
|
+
}
|
|
499
|
+
get dataView() {
|
|
500
|
+
return new DataView(this.bytes.buffer, this.bytes.byteOffset, this.bytes.byteLength);
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
class L {
|
|
435
504
|
constructor(s) {
|
|
436
505
|
t(this, "headers");
|
|
437
506
|
t(this, "ok");
|
|
@@ -470,14 +539,14 @@ class S {
|
|
|
470
539
|
return Promise.resolve(Uint8Array.from(this._bodyContent, (s) => s.charCodeAt(0)));
|
|
471
540
|
}
|
|
472
541
|
}
|
|
473
|
-
class
|
|
542
|
+
class R {
|
|
474
543
|
constructor() {
|
|
475
544
|
/**
|
|
476
545
|
* HID interface
|
|
477
546
|
*/
|
|
478
547
|
t(this, "hid");
|
|
479
548
|
t(this, "fs");
|
|
480
|
-
t(this, "api", new
|
|
549
|
+
t(this, "api", new x());
|
|
481
550
|
t(this, "handlerMap", /* @__PURE__ */ new Map());
|
|
482
551
|
this.hid = f(this.api), this.fs = new H(this.api);
|
|
483
552
|
}
|
|
@@ -509,10 +578,10 @@ class A {
|
|
|
509
578
|
call: "otk::fetch",
|
|
510
579
|
resource: s,
|
|
511
580
|
options: e
|
|
512
|
-
},
|
|
513
|
-
if (!
|
|
581
|
+
}, n = await this.api.callOverlayHandler(a);
|
|
582
|
+
if (!n)
|
|
514
583
|
throw new Error("method not found");
|
|
515
|
-
return new
|
|
584
|
+
return new L(n);
|
|
516
585
|
}
|
|
517
586
|
/**
|
|
518
587
|
* Subscribe to game packets
|
|
@@ -522,13 +591,13 @@ class A {
|
|
|
522
591
|
* @returns subscription name
|
|
523
592
|
*/
|
|
524
593
|
async SubscribePacket(s, e, a) {
|
|
525
|
-
const
|
|
594
|
+
const n = {
|
|
526
595
|
call: "otk::packet",
|
|
527
596
|
action: "subscribe",
|
|
528
597
|
name: s,
|
|
529
598
|
evt_name: "otk::packet::" + s,
|
|
530
599
|
filters: e
|
|
531
|
-
}, c = await this.api.callOverlayHandler(
|
|
600
|
+
}, c = await this.api.callOverlayHandler(n);
|
|
532
601
|
if (!c)
|
|
533
602
|
throw new Error("method not found");
|
|
534
603
|
if (c.error)
|
|
@@ -551,18 +620,18 @@ class A {
|
|
|
551
620
|
if (a != null && a.error)
|
|
552
621
|
throw new Error(a.error);
|
|
553
622
|
if (this.handlerMap.has(s)) {
|
|
554
|
-
const
|
|
555
|
-
|
|
623
|
+
const n = this.handlerMap.get(s);
|
|
624
|
+
n.evt_name && this.api.removeOverlayListener(n.evt_name), this.handlerMap.delete(s);
|
|
556
625
|
}
|
|
557
626
|
}
|
|
558
627
|
packetHandler(s, e = !1) {
|
|
559
|
-
let a = s,
|
|
560
|
-
|
|
628
|
+
let a = s, n = s;
|
|
629
|
+
n.data = Uint8Array.from(atob(a.msg), (h) => h.charCodeAt(0));
|
|
561
630
|
let c = this.handlerMap.get(a.name);
|
|
562
631
|
if (c) {
|
|
563
632
|
if (e && c.evt_name)
|
|
564
633
|
return;
|
|
565
|
-
c.handler(
|
|
634
|
+
c.handler(n);
|
|
566
635
|
} else e || console.warn("No packet handler for name", a.name);
|
|
567
636
|
}
|
|
568
637
|
/**
|
|
@@ -575,14 +644,21 @@ class A {
|
|
|
575
644
|
return this.api.callOverlayHandler(s);
|
|
576
645
|
}
|
|
577
646
|
/**
|
|
578
|
-
*
|
|
579
|
-
* @returns
|
|
647
|
+
* Get plugin version
|
|
648
|
+
* @returns the plugin version
|
|
580
649
|
*/
|
|
581
650
|
async GetPluginVersion() {
|
|
651
|
+
return (await this.GetPluginInfo()).version;
|
|
652
|
+
}
|
|
653
|
+
/**
|
|
654
|
+
* Get plugin version and tool list
|
|
655
|
+
* @returns the plugin info
|
|
656
|
+
*/
|
|
657
|
+
async GetPluginInfo() {
|
|
582
658
|
const s = {
|
|
583
659
|
call: "otk::plugin_ver"
|
|
584
660
|
};
|
|
585
|
-
return
|
|
661
|
+
return await this.api.callOverlayHandler(s);
|
|
586
662
|
}
|
|
587
663
|
/**
|
|
588
664
|
* Open URL in default browser
|
|
@@ -596,6 +672,42 @@ class A {
|
|
|
596
672
|
if (a != null && a.Error)
|
|
597
673
|
throw new Error(a.Error);
|
|
598
674
|
}
|
|
675
|
+
/**
|
|
676
|
+
* Search memory sig in program TEXT section
|
|
677
|
+
* @param sig sig to scan. e.g. "e8 ?? ?? ?? ??"
|
|
678
|
+
* @param startAddr optional. address to start search, absolute address
|
|
679
|
+
* @param offset optional. address to start search, relative to text begin
|
|
680
|
+
* @returns
|
|
681
|
+
*/
|
|
682
|
+
async MemoryScanSig(s, e, a = 0) {
|
|
683
|
+
const n = {
|
|
684
|
+
call: "otk::memory",
|
|
685
|
+
action: "sig_scanner",
|
|
686
|
+
sig: s,
|
|
687
|
+
started_at: a,
|
|
688
|
+
offset: e
|
|
689
|
+
}, c = await this.api.callOverlayHandler(n);
|
|
690
|
+
if (c != null && c.Error)
|
|
691
|
+
throw new Error(c.Error);
|
|
692
|
+
return new S(c);
|
|
693
|
+
}
|
|
694
|
+
/**
|
|
695
|
+
* Read memory with address and length
|
|
696
|
+
* @param addr address to read
|
|
697
|
+
* @param length length to read. 0x10000 maximum
|
|
698
|
+
* @returns
|
|
699
|
+
*/
|
|
700
|
+
async MemoryRead(s, e) {
|
|
701
|
+
const a = {
|
|
702
|
+
call: "otk::memory",
|
|
703
|
+
action: "read",
|
|
704
|
+
addr: s,
|
|
705
|
+
length: e
|
|
706
|
+
}, n = await this.api.callOverlayHandler(a);
|
|
707
|
+
if (n != null && n.Error)
|
|
708
|
+
throw new Error(n.Error);
|
|
709
|
+
return new A(n);
|
|
710
|
+
}
|
|
599
711
|
/**
|
|
600
712
|
* Call start overlay events
|
|
601
713
|
*
|
|
@@ -649,7 +761,7 @@ class A {
|
|
|
649
761
|
setTimeout(() => this.tryConnectToCEF(), 300);
|
|
650
762
|
return;
|
|
651
763
|
}
|
|
652
|
-
const s = new
|
|
764
|
+
const s = new D();
|
|
653
765
|
this.api.setTransport(s), s.waitForApi();
|
|
654
766
|
}
|
|
655
767
|
/**
|
|
@@ -663,7 +775,7 @@ class A {
|
|
|
663
775
|
console.warn("OverlayToolkit: Connect wsUrl ignored in OverlayPlugin CEF environment");
|
|
664
776
|
return;
|
|
665
777
|
}
|
|
666
|
-
const e = new
|
|
778
|
+
const e = new P(s);
|
|
667
779
|
this.api.setTransport(e);
|
|
668
780
|
}
|
|
669
781
|
}
|
|
@@ -674,7 +786,7 @@ class A {
|
|
|
674
786
|
return this.api.isConnected;
|
|
675
787
|
}
|
|
676
788
|
}
|
|
677
|
-
class
|
|
789
|
+
class i {
|
|
678
790
|
constructor(s, e) {
|
|
679
791
|
t(this, "type");
|
|
680
792
|
t(this, "typeCode");
|
|
@@ -685,7 +797,7 @@ class n {
|
|
|
685
797
|
return new Date(this.time);
|
|
686
798
|
}
|
|
687
799
|
}
|
|
688
|
-
class
|
|
800
|
+
class q extends i {
|
|
689
801
|
constructor(e) {
|
|
690
802
|
super("LogLine", e);
|
|
691
803
|
t(this, "code");
|
|
@@ -694,7 +806,7 @@ class L extends n {
|
|
|
694
806
|
this.code = e[2], this.name = e[3], this.line = e[4];
|
|
695
807
|
}
|
|
696
808
|
}
|
|
697
|
-
class
|
|
809
|
+
class _ extends i {
|
|
698
810
|
constructor(e) {
|
|
699
811
|
super("ChangeZone", e);
|
|
700
812
|
/**
|
|
@@ -708,7 +820,7 @@ class R extends n {
|
|
|
708
820
|
this.zoneID = parseInt(e[2], 16), this.zoneName = e[3];
|
|
709
821
|
}
|
|
710
822
|
}
|
|
711
|
-
class z extends
|
|
823
|
+
class z extends i {
|
|
712
824
|
constructor(e) {
|
|
713
825
|
super("ChangePrimaryPlayer", e);
|
|
714
826
|
/**
|
|
@@ -725,7 +837,7 @@ class z extends n {
|
|
|
725
837
|
return this.charID.toString(16).toUpperCase();
|
|
726
838
|
}
|
|
727
839
|
}
|
|
728
|
-
class
|
|
840
|
+
class B extends i {
|
|
729
841
|
constructor(e) {
|
|
730
842
|
super("AddCombatant", e);
|
|
731
843
|
/**
|
|
@@ -754,7 +866,7 @@ class q extends n {
|
|
|
754
866
|
this.id = parseInt(e[2], 16), this.name = e[3], this.job = parseInt(e[4], 16), this.level = parseInt(e[5], 16), this.ownerID = parseInt(e[6], 16), this.worldID = parseInt(e[7], 16), this.worldName = e[8], this.npcNameID = parseInt(e[9]), this.npcBaseID = parseInt(e[10]), this.currentHP = parseInt(e[11]), this.hp = parseInt(e[12]), this.currentMP = parseInt(e[13]), this.mp = parseInt(e[14]), this.x = parseFloat(e[17]), this.y = parseFloat(e[18]), this.z = parseFloat(e[19]), this.heading = parseFloat(e[20]);
|
|
755
867
|
}
|
|
756
868
|
}
|
|
757
|
-
class
|
|
869
|
+
class U extends i {
|
|
758
870
|
constructor(e) {
|
|
759
871
|
super("RemoveCombatant", e);
|
|
760
872
|
/**
|
|
@@ -779,7 +891,7 @@ class _ extends n {
|
|
|
779
891
|
this.id = parseInt(e[2], 16), this.name = e[3], this.job = parseInt(e[4], 16), this.level = parseInt(e[5], 16), this.ownerID = parseInt(e[6], 16), this.world = e[8], this.npcNameID = parseInt(e[9]), this.npcBaseID = parseInt(e[10]), this.currentHP = parseInt(e[11]), this.hp = parseInt(e[12]), this.currentMP = parseInt(e[13]), this.mp = parseInt(e[14]), this.x = parseFloat(e[17]), this.y = parseFloat(e[18]), this.z = parseFloat(e[19]), this.heading = parseFloat(e[20]);
|
|
780
892
|
}
|
|
781
893
|
}
|
|
782
|
-
class
|
|
894
|
+
class j extends i {
|
|
783
895
|
constructor(e) {
|
|
784
896
|
super("PartyChanged", e);
|
|
785
897
|
/**
|
|
@@ -788,11 +900,11 @@ class B extends n {
|
|
|
788
900
|
t(this, "party");
|
|
789
901
|
this.party = [];
|
|
790
902
|
let a = parseInt(e[2]);
|
|
791
|
-
for (let
|
|
792
|
-
this.party.push(parseInt(e[3 +
|
|
903
|
+
for (let n = 0; n < a; n++)
|
|
904
|
+
this.party.push(parseInt(e[3 + n], 16));
|
|
793
905
|
}
|
|
794
906
|
}
|
|
795
|
-
class
|
|
907
|
+
class V extends i {
|
|
796
908
|
constructor(e) {
|
|
797
909
|
super("PlayerStats", e);
|
|
798
910
|
t(this, "job");
|
|
@@ -815,7 +927,7 @@ class U extends n {
|
|
|
815
927
|
this.job = parseInt(e[2], 16), this.strength = parseInt(e[3]), this.dexterity = parseInt(e[4]), this.vitality = parseInt(e[5]), this.intelligence = parseInt(e[6]), this.mind = parseInt(e[7]), this.piety = parseInt(e[8]), this.attackPower = parseInt(e[9]), this.directHit = parseInt(e[10]), this.criticalHit = parseInt(e[11]), this.attakcMagicPotency = parseInt(e[12]), this.healingMagicPotency = parseInt(e[13]), this.determination = parseInt(e[14]), this.skillSpeed = parseInt(e[15]), this.spellSpeed = parseInt(e[16]), this.tenacity = parseInt(e[18]), this.localContentID = parseInt(e[19], 16);
|
|
816
928
|
}
|
|
817
929
|
}
|
|
818
|
-
class W extends
|
|
930
|
+
class W extends i {
|
|
819
931
|
constructor(e) {
|
|
820
932
|
super("NetworkStartsCasting", e);
|
|
821
933
|
t(this, "sourceID");
|
|
@@ -832,7 +944,7 @@ class W extends n {
|
|
|
832
944
|
this.sourceID = parseInt(e[2], 16), this.sourceName = e[3], this.id = parseInt(e[4], 16), this.ability = e[5], this.targetID = parseInt(e[6], 16), this.targetName = e[7], this.castTime = parseFloat(e[8]), this.x = parseFloat(e[9]), this.y = parseFloat(e[10]), this.z = parseFloat(e[11]), this.heading = parseFloat(e[12]);
|
|
833
945
|
}
|
|
834
946
|
}
|
|
835
|
-
class
|
|
947
|
+
class G extends i {
|
|
836
948
|
constructor(e) {
|
|
837
949
|
super(e[0] == "22" ? "NetworkAOEAbility" : "NetworkAbility", e);
|
|
838
950
|
t(this, "sourceID");
|
|
@@ -877,7 +989,7 @@ class j extends n {
|
|
|
877
989
|
this.targetCurrentHP = parseInt(e[24]), this.targetMaxHP = parseInt(e[25]), this.targetCurrentMP = parseInt(e[26]), this.targetMaxMP = parseInt(e[27]), this.targetX = parseFloat(e[30]), this.targetY = parseFloat(e[31]), this.targetZ = parseFloat(e[32]), this.targetHeading = parseFloat(e[33]), this.currentHP = parseInt(e[34]), this.maxHP = parseInt(e[35]), this.currentMP = parseInt(e[36]), this.maxMP = parseInt(e[37]), this.x = parseFloat(e[40]), this.y = parseFloat(e[41]), this.z = parseFloat(e[42]), this.heading = parseFloat(e[43]), this.sequence = parseInt(e[44], 16), this.targetIndex = parseInt(e[45]), this.targetCount = parseInt(e[46]), this.ownerID = parseInt(e[47], 16), this.ownerName = e[48], this.effectDisplayType = parseInt(e[49]), this.actionID = parseInt(e[50], 16), this.actionAnimationID = parseInt(e[51], 16), this.animationLockTime = parseFloat(e[52]), this.rotationHex = parseInt(e[53], 16);
|
|
878
990
|
}
|
|
879
991
|
}
|
|
880
|
-
class
|
|
992
|
+
class Y extends i {
|
|
881
993
|
constructor(e) {
|
|
882
994
|
super("NetworkCancelAbility", e);
|
|
883
995
|
t(this, "sourceID");
|
|
@@ -888,7 +1000,7 @@ class G extends n {
|
|
|
888
1000
|
this.sourceID = parseInt(e[2], 16), this.source = e[3], this.id = parseInt(e[4], 16), this.name = e[5], this.reason = e[6];
|
|
889
1001
|
}
|
|
890
1002
|
}
|
|
891
|
-
class
|
|
1003
|
+
class Z extends i {
|
|
892
1004
|
constructor(e) {
|
|
893
1005
|
super("NetworkDoT", e);
|
|
894
1006
|
t(this, "id");
|
|
@@ -922,7 +1034,7 @@ class V extends n {
|
|
|
922
1034
|
this.id = parseInt(e[2], 16), this.name = e[3], this.which = e[4], this.effectID = parseInt(e[5], 16), this.damage = parseInt(e[6]), this.currentHP = parseInt(e[7]), this.maxHP = parseInt(e[8]), this.currentMP = parseInt(e[9]), this.maxMP = parseInt(e[10]), this.x = parseFloat(e[13]), this.y = parseFloat(e[14]), this.z = parseFloat(e[15]), this.heading = parseFloat(e[16]), this.sourceID = parseInt(e[17], 16), this.sourceName = e[18], this.damageType = parseInt(e[19], 16), this.sourceCurrentHP = parseInt(e[20]), this.sourceMaxHP = parseInt(e[21]), this.sourceCurrentMP = parseInt(e[22]), this.sourceMaxMP = parseInt(e[23]), this.sourceX = parseFloat(e[26]), this.sourceY = parseFloat(e[27]), this.sourceZ = parseFloat(e[28]), this.sourceHeading = parseFloat(e[29]);
|
|
923
1035
|
}
|
|
924
1036
|
}
|
|
925
|
-
class
|
|
1037
|
+
class J extends i {
|
|
926
1038
|
constructor(e) {
|
|
927
1039
|
super("NetworkDeath", e);
|
|
928
1040
|
t(this, "targetID");
|
|
@@ -932,7 +1044,7 @@ class Y extends n {
|
|
|
932
1044
|
this.targetID = parseInt(e[2], 16), this.targetName = e[3], this.sourceID = parseInt(e[4], 16), this.sourceName = e[5];
|
|
933
1045
|
}
|
|
934
1046
|
}
|
|
935
|
-
class
|
|
1047
|
+
class X extends i {
|
|
936
1048
|
constructor(e) {
|
|
937
1049
|
super("NetworkBuff", e);
|
|
938
1050
|
t(this, "effectID");
|
|
@@ -948,7 +1060,7 @@ class Z extends n {
|
|
|
948
1060
|
this.effectID = parseInt(e[2], 16), this.effectName = e[3], this.duration = parseFloat(e[4]), this.sourceID = parseInt(e[5], 16), this.sourceName = e[6], this.targetID = parseInt(e[7], 16), this.targetName = e[8], this.count = parseInt(e[9]), this.targetMaxHP = parseInt(e[10] == "" ? "-1" : e[10]), this.sourceMaxHP = parseInt(e[11] == "" ? "-1" : e[11]);
|
|
949
1061
|
}
|
|
950
1062
|
}
|
|
951
|
-
class
|
|
1063
|
+
class K extends i {
|
|
952
1064
|
constructor(e) {
|
|
953
1065
|
super("NetworkTargetIcon", e);
|
|
954
1066
|
t(this, "targetID");
|
|
@@ -958,7 +1070,7 @@ class J extends n {
|
|
|
958
1070
|
this.targetID = parseInt(e[2], 16), this.targetName = e[3], this.id = parseInt(e[6], 16), this.data0 = parseInt(e[7], 16);
|
|
959
1071
|
}
|
|
960
1072
|
}
|
|
961
|
-
class
|
|
1073
|
+
class $ extends i {
|
|
962
1074
|
constructor(e) {
|
|
963
1075
|
super("NetworkRaidMarker", e);
|
|
964
1076
|
t(this, "operation");
|
|
@@ -971,7 +1083,7 @@ class X extends n {
|
|
|
971
1083
|
this.operation = e[2], this.waymark = parseInt(e[3]), this.id = parseInt(e[4], 16), this.name = e[5], this.x = parseFloat(e[6]), this.y = parseFloat(e[7]), this.z = parseFloat(e[8]);
|
|
972
1084
|
}
|
|
973
1085
|
}
|
|
974
|
-
class
|
|
1086
|
+
class Q extends i {
|
|
975
1087
|
constructor(e) {
|
|
976
1088
|
super("NetworkTargetMarker", e);
|
|
977
1089
|
t(this, "operation");
|
|
@@ -983,7 +1095,7 @@ class K extends n {
|
|
|
983
1095
|
this.operation = e[2], this.waymark = parseInt(e[3]), this.id = parseInt(e[4], 16), this.name = e[5], this.targetID = parseInt(e[6], 16), this.targetName = e[7];
|
|
984
1096
|
}
|
|
985
1097
|
}
|
|
986
|
-
class
|
|
1098
|
+
class g extends i {
|
|
987
1099
|
constructor(e) {
|
|
988
1100
|
super("NetworkBuffRemove", e);
|
|
989
1101
|
t(this, "effectID");
|
|
@@ -996,7 +1108,7 @@ class $ extends n {
|
|
|
996
1108
|
this.effectID = parseInt(e[2], 16), this.effectName = e[3], this.sourceID = parseInt(e[5], 16), this.sourceName = e[6], this.targetID = parseInt(e[7], 16), this.targetName = e[8], this.count = parseInt(e[9], 16);
|
|
997
1109
|
}
|
|
998
1110
|
}
|
|
999
|
-
class
|
|
1111
|
+
class ee extends i {
|
|
1000
1112
|
constructor(e) {
|
|
1001
1113
|
super("NetworkGauge", e);
|
|
1002
1114
|
t(this, "id");
|
|
@@ -1008,13 +1120,13 @@ class Q extends n {
|
|
|
1008
1120
|
t(this, "data");
|
|
1009
1121
|
this.id = parseInt(e[2], 16), this.data = new Uint8Array(16);
|
|
1010
1122
|
let a = new DataView(this.data.buffer);
|
|
1011
|
-
for (let
|
|
1012
|
-
let c = parseInt(e[3 +
|
|
1013
|
-
a.setUint32(
|
|
1123
|
+
for (let n = 0; n < 4; n++) {
|
|
1124
|
+
let c = parseInt(e[3 + n]);
|
|
1125
|
+
a.setUint32(n * 4, c, !0);
|
|
1014
1126
|
}
|
|
1015
1127
|
}
|
|
1016
1128
|
}
|
|
1017
|
-
class
|
|
1129
|
+
class te extends i {
|
|
1018
1130
|
constructor(e) {
|
|
1019
1131
|
super("NetworkActorControl", e);
|
|
1020
1132
|
t(this, "instance");
|
|
@@ -1025,7 +1137,7 @@ class g extends n {
|
|
|
1025
1137
|
this.data.push(parseInt(e[4 + a], 16));
|
|
1026
1138
|
}
|
|
1027
1139
|
}
|
|
1028
|
-
class
|
|
1140
|
+
class se extends i {
|
|
1029
1141
|
constructor(e) {
|
|
1030
1142
|
super("NetworkNameToggle", e);
|
|
1031
1143
|
t(this, "id");
|
|
@@ -1039,7 +1151,7 @@ class ee extends n {
|
|
|
1039
1151
|
this.id = parseInt(e[2], 16), this.name = e[3], this.targetID = parseInt(e[4], 16), this.targetName = e[5], this.toggle = parseInt(e[6]) === 1;
|
|
1040
1152
|
}
|
|
1041
1153
|
}
|
|
1042
|
-
class
|
|
1154
|
+
class re extends i {
|
|
1043
1155
|
constructor(e) {
|
|
1044
1156
|
super("NetworkTether", e);
|
|
1045
1157
|
t(this, "sourceID");
|
|
@@ -1050,7 +1162,7 @@ class te extends n {
|
|
|
1050
1162
|
this.sourceID = parseInt(e[2], 16), this.sourceName = e[3], this.targetID = parseInt(e[4], 16), this.targetName = e[5], this.id = parseInt(e[8], 16);
|
|
1051
1163
|
}
|
|
1052
1164
|
}
|
|
1053
|
-
class
|
|
1165
|
+
class ae extends i {
|
|
1054
1166
|
constructor(e) {
|
|
1055
1167
|
super("LimitBreak", e);
|
|
1056
1168
|
/**
|
|
@@ -1061,7 +1173,7 @@ class se extends n {
|
|
|
1061
1173
|
this.value = parseInt(e[2], 16), this.bars = parseInt(e[3]);
|
|
1062
1174
|
}
|
|
1063
1175
|
}
|
|
1064
|
-
class
|
|
1176
|
+
class ne extends i {
|
|
1065
1177
|
constructor(e) {
|
|
1066
1178
|
super("NetworkActionSync", e);
|
|
1067
1179
|
t(this, "id");
|
|
@@ -1079,7 +1191,7 @@ class re extends n {
|
|
|
1079
1191
|
this.id = parseInt(e[2], 16), this.name = e[3], this.sequenceID = parseInt(e[4], 16), this.currentHP = e[5] ? parseInt(e[5]) : -1, this.maxHP = e[6] ? parseInt(e[6]) : -1, this.currentMP = e[7] ? parseInt(e[7]) : -1, this.maxMP = e[8] ? parseInt(e[8]) : -1, this.currentShield = e[9] ? parseInt(e[9]) : -1, this.x = parseFloat(e[11]), this.y = parseFloat(e[12]), this.z = parseFloat(e[13]), this.heading = parseFloat(e[14]);
|
|
1080
1192
|
}
|
|
1081
1193
|
}
|
|
1082
|
-
class
|
|
1194
|
+
class ie extends i {
|
|
1083
1195
|
constructor(e) {
|
|
1084
1196
|
super("NetworkStatusEffects", e);
|
|
1085
1197
|
t(this, "targetID");
|
|
@@ -1101,7 +1213,7 @@ class ae extends n {
|
|
|
1101
1213
|
this.data.push(parseInt(e[15 + a], 16));
|
|
1102
1214
|
}
|
|
1103
1215
|
}
|
|
1104
|
-
class
|
|
1216
|
+
class ce extends i {
|
|
1105
1217
|
constructor(e) {
|
|
1106
1218
|
super("NetworkUpdateHP", e);
|
|
1107
1219
|
t(this, "id");
|
|
@@ -1119,7 +1231,7 @@ class ne extends n {
|
|
|
1119
1231
|
this.id = parseInt(e[2], 16), this.name = e[3], this.currentHP = parseInt(e[4]), this.maxHP = parseInt(e[5]), this.currentMP = parseInt(e[6]), this.maxMP = parseInt(e[7]), this.x = parseFloat(e[10]), this.y = parseFloat(e[11]), this.z = parseFloat(e[12]), this.heading = parseFloat(e[13]);
|
|
1120
1232
|
}
|
|
1121
1233
|
}
|
|
1122
|
-
class
|
|
1234
|
+
class he extends i {
|
|
1123
1235
|
constructor(e) {
|
|
1124
1236
|
super("Map", e);
|
|
1125
1237
|
t(this, "id");
|
|
@@ -1129,7 +1241,7 @@ class ie extends n {
|
|
|
1129
1241
|
this.id = parseInt(e[2], 16), this.regionName = e[3], this.placeName = e[4], this.placeNameSub = e[5];
|
|
1130
1242
|
}
|
|
1131
1243
|
}
|
|
1132
|
-
class
|
|
1244
|
+
class pe extends i {
|
|
1133
1245
|
constructor(e) {
|
|
1134
1246
|
super("SystemLogMessage", e);
|
|
1135
1247
|
t(this, "instance");
|
|
@@ -1140,7 +1252,7 @@ class ce extends n {
|
|
|
1140
1252
|
this.params.push(parseInt(e[4 + a], 16));
|
|
1141
1253
|
}
|
|
1142
1254
|
}
|
|
1143
|
-
class
|
|
1255
|
+
class oe extends i {
|
|
1144
1256
|
constructor(e) {
|
|
1145
1257
|
super("StatusList3", e);
|
|
1146
1258
|
t(this, "id");
|
|
@@ -1151,14 +1263,14 @@ class he extends n {
|
|
|
1151
1263
|
this.statusList.push(parseInt(e[4 + a], 16));
|
|
1152
1264
|
}
|
|
1153
1265
|
}
|
|
1154
|
-
class
|
|
1266
|
+
class de extends i {
|
|
1155
1267
|
constructor(e) {
|
|
1156
1268
|
super("Debug", e);
|
|
1157
1269
|
t(this, "message");
|
|
1158
1270
|
this.message = e[2];
|
|
1159
1271
|
}
|
|
1160
1272
|
}
|
|
1161
|
-
class
|
|
1273
|
+
class ue extends i {
|
|
1162
1274
|
constructor(e) {
|
|
1163
1275
|
super("PacketDump", e);
|
|
1164
1276
|
t(this, "len");
|
|
@@ -1167,28 +1279,28 @@ class oe extends n {
|
|
|
1167
1279
|
t(this, "packetType");
|
|
1168
1280
|
t(this, "data");
|
|
1169
1281
|
this.len = parseInt(e[2], 16), this.src = parseInt(e[3], 16), this.dst = parseInt(e[4], 16), this.packetType = parseInt(e[5], 16) & 65535, this.data = new Uint8Array(this.len - 16);
|
|
1170
|
-
for (let a = 6,
|
|
1282
|
+
for (let a = 6, n = 0; a < e.length - 2; a++, n++) {
|
|
1171
1283
|
const c = parseInt(e[a], 16);
|
|
1172
1284
|
for (let h = 0; h < 4; h++)
|
|
1173
|
-
this.data[
|
|
1285
|
+
this.data[n * 4 + h] = c >> h * 8 & 255;
|
|
1174
1286
|
}
|
|
1175
1287
|
}
|
|
1176
1288
|
}
|
|
1177
|
-
class
|
|
1289
|
+
class Ie extends i {
|
|
1178
1290
|
constructor(e) {
|
|
1179
1291
|
super("Version", e);
|
|
1180
1292
|
t(this, "message");
|
|
1181
1293
|
this.message = e[2];
|
|
1182
1294
|
}
|
|
1183
1295
|
}
|
|
1184
|
-
let
|
|
1296
|
+
let me = class extends i {
|
|
1185
1297
|
constructor(e) {
|
|
1186
1298
|
super("Error", e);
|
|
1187
1299
|
t(this, "message");
|
|
1188
1300
|
this.message = e[2];
|
|
1189
1301
|
}
|
|
1190
1302
|
};
|
|
1191
|
-
class
|
|
1303
|
+
class le extends i {
|
|
1192
1304
|
constructor(e) {
|
|
1193
1305
|
super("LineRegistration", e);
|
|
1194
1306
|
t(this, "id");
|
|
@@ -1198,7 +1310,7 @@ class Ie extends n {
|
|
|
1198
1310
|
this.id = parseInt(e[2]), this.source = e[3], this.name = e[4], this.version = e[5];
|
|
1199
1311
|
}
|
|
1200
1312
|
}
|
|
1201
|
-
class
|
|
1313
|
+
class we extends i {
|
|
1202
1314
|
constructor(e) {
|
|
1203
1315
|
super("MapEffect", e);
|
|
1204
1316
|
t(this, "instance");
|
|
@@ -1209,7 +1321,7 @@ class me extends n {
|
|
|
1209
1321
|
this.instance = parseInt(e[2], 16), this.flags = parseInt(e[3], 16), this.location = parseInt(e[4], 16), this.data0 = parseInt(e[5], 16), this.data1 = parseInt(e[6], 16);
|
|
1210
1322
|
}
|
|
1211
1323
|
}
|
|
1212
|
-
class
|
|
1324
|
+
class ye extends i {
|
|
1213
1325
|
constructor(e) {
|
|
1214
1326
|
super("FateDirector", e);
|
|
1215
1327
|
t(this, "category");
|
|
@@ -1219,7 +1331,7 @@ class le extends n {
|
|
|
1219
1331
|
this.category = e[2], this.unknown = parseInt(e[3], 16), this.id = parseInt(e[4], 16), this.progress = parseInt(e[5], 16);
|
|
1220
1332
|
}
|
|
1221
1333
|
}
|
|
1222
|
-
class
|
|
1334
|
+
class fe extends i {
|
|
1223
1335
|
constructor(e) {
|
|
1224
1336
|
super("CEDirector", e);
|
|
1225
1337
|
t(this, "popTime");
|
|
@@ -1234,7 +1346,7 @@ class we extends n {
|
|
|
1234
1346
|
this.popTime = parseInt(e[2], 16), this.timeRemaining = parseInt(e[3], 16), this.unknown = parseInt(e[4], 16), this.ceKey = parseInt(e[5], 16), this.numPlayers = parseInt(e[6], 16), this.status = parseInt(e[7], 16), this.unknown2 = parseInt(e[8], 16), this.progress = parseInt(e[9], 16);
|
|
1235
1347
|
}
|
|
1236
1348
|
}
|
|
1237
|
-
class
|
|
1349
|
+
class ve extends i {
|
|
1238
1350
|
constructor(e) {
|
|
1239
1351
|
super("InCombat", e);
|
|
1240
1352
|
t(this, "inACTCombat");
|
|
@@ -1244,7 +1356,7 @@ class ye extends n {
|
|
|
1244
1356
|
this.inACTCombat = parseInt(e[2]) === 1, this.inGameCombat = parseInt(e[3]) === 1, this.isACTChanged = parseInt(e[4]) === 1, this.isGameChanged = parseInt(e[5]) === 1;
|
|
1245
1357
|
}
|
|
1246
1358
|
}
|
|
1247
|
-
class
|
|
1359
|
+
class be extends i {
|
|
1248
1360
|
constructor(e) {
|
|
1249
1361
|
super("CombatantMemory", e);
|
|
1250
1362
|
t(this, "change");
|
|
@@ -1255,7 +1367,7 @@ class fe extends n {
|
|
|
1255
1367
|
this.data.set(e[a], e[a + 1]);
|
|
1256
1368
|
}
|
|
1257
1369
|
}
|
|
1258
|
-
class
|
|
1370
|
+
class ke extends i {
|
|
1259
1371
|
constructor(e) {
|
|
1260
1372
|
super("RSVData", e);
|
|
1261
1373
|
t(this, "locale");
|
|
@@ -1265,7 +1377,7 @@ class ve extends n {
|
|
|
1265
1377
|
this.locale = e[2], this.unknown = parseInt(e[3], 16), this.key = e[4], this.value = e[5];
|
|
1266
1378
|
}
|
|
1267
1379
|
}
|
|
1268
|
-
class xe extends
|
|
1380
|
+
class xe extends i {
|
|
1269
1381
|
constructor(e) {
|
|
1270
1382
|
super("StartsUsingExtra", e);
|
|
1271
1383
|
t(this, "sourceID");
|
|
@@ -1277,7 +1389,7 @@ class xe extends n {
|
|
|
1277
1389
|
this.sourceID = parseInt(e[2], 16), this.id = parseInt(e[3], 16), this.x = parseFloat(e[4]), this.y = parseFloat(e[5]), this.z = parseFloat(e[6]), this.heading = parseFloat(e[7]);
|
|
1278
1390
|
}
|
|
1279
1391
|
}
|
|
1280
|
-
class
|
|
1392
|
+
class De extends i {
|
|
1281
1393
|
constructor(e) {
|
|
1282
1394
|
super("AbilityExtra", e);
|
|
1283
1395
|
t(this, "sourceID");
|
|
@@ -1292,7 +1404,7 @@ class ke extends n {
|
|
|
1292
1404
|
this.sourceID = parseInt(e[2], 16), this.id = parseInt(e[3], 16), this.globalEffectCounter = parseInt(e[4], 16), this.dataFlag = parseInt(e[5], 16), this.x = parseFloat(e[6]), this.y = parseFloat(e[7]), this.z = parseFloat(e[8]), this.heading = parseFloat(e[9]), this.animationTargetId = parseInt(e[10], 16);
|
|
1293
1405
|
}
|
|
1294
1406
|
}
|
|
1295
|
-
class
|
|
1407
|
+
class Pe extends i {
|
|
1296
1408
|
constructor(e) {
|
|
1297
1409
|
super("ContentFinderSettings", e);
|
|
1298
1410
|
t(this, "zoneID");
|
|
@@ -1306,7 +1418,7 @@ class De extends n {
|
|
|
1306
1418
|
this.zoneID = parseInt(e[2], 16), this.zoneName = e[3], this.inContentFinderContent = parseInt(e[4]) === 1, this.unrestrictedParty = parseInt(e[5]) === 1, this.minimalItemLevel = parseInt(e[6]) === 1, this.silenceEcho = parseInt(e[7]) === 1, this.explorerMode = parseInt(e[8]) === 1, this.levelSync = parseInt(e[9]) === 1;
|
|
1307
1419
|
}
|
|
1308
1420
|
}
|
|
1309
|
-
class
|
|
1421
|
+
class Ne extends i {
|
|
1310
1422
|
constructor(e) {
|
|
1311
1423
|
super("NpcYell", e);
|
|
1312
1424
|
t(this, "npcId");
|
|
@@ -1315,7 +1427,7 @@ class Pe extends n {
|
|
|
1315
1427
|
this.npcId = parseInt(e[2], 16), this.npcNameId = parseInt(e[3], 16), this.npcYellId = parseInt(e[4], 16);
|
|
1316
1428
|
}
|
|
1317
1429
|
}
|
|
1318
|
-
class
|
|
1430
|
+
class Ee extends i {
|
|
1319
1431
|
constructor(e) {
|
|
1320
1432
|
super("BattleTalk2", e);
|
|
1321
1433
|
t(this, "npcId");
|
|
@@ -1326,7 +1438,7 @@ class be extends n {
|
|
|
1326
1438
|
this.npcId = parseInt(e[2], 16), this.instance = parseInt(e[3], 16), this.npcNameId = parseInt(e[4], 16), this.instanceContentTextId = parseInt(e[5], 16), this.displayMs = parseInt(e[6]);
|
|
1327
1439
|
}
|
|
1328
1440
|
}
|
|
1329
|
-
class
|
|
1441
|
+
class Fe extends i {
|
|
1330
1442
|
constructor(e) {
|
|
1331
1443
|
super("Countdown", e);
|
|
1332
1444
|
t(this, "id");
|
|
@@ -1337,7 +1449,7 @@ class Ne extends n {
|
|
|
1337
1449
|
this.id = parseInt(e[2], 16), this.worldID = parseInt(e[3], 16), this.countdownTime = parseInt(e[4]), this.result = parseInt(e[5], 16), this.name = e[6];
|
|
1338
1450
|
}
|
|
1339
1451
|
}
|
|
1340
|
-
class
|
|
1452
|
+
class Ce extends i {
|
|
1341
1453
|
constructor(e) {
|
|
1342
1454
|
super("CountdownCancel", e);
|
|
1343
1455
|
t(this, "id");
|
|
@@ -1346,7 +1458,7 @@ class Fe extends n {
|
|
|
1346
1458
|
this.id = parseInt(e[2], 16), this.worldID = parseInt(e[3], 16), this.name = e[4];
|
|
1347
1459
|
}
|
|
1348
1460
|
}
|
|
1349
|
-
class
|
|
1461
|
+
class Me extends i {
|
|
1350
1462
|
constructor(e) {
|
|
1351
1463
|
super("ActorMove", e);
|
|
1352
1464
|
t(this, "id");
|
|
@@ -1359,7 +1471,7 @@ class Ce extends n {
|
|
|
1359
1471
|
this.id = parseInt(e[2], 16), this.heading = parseFloat(e[3]), this.unk1 = parseInt(e[4], 16), this.unk2 = parseInt(e[5], 16), this.x = parseFloat(e[6]), this.y = parseFloat(e[7]), this.z = parseFloat(e[8]);
|
|
1360
1472
|
}
|
|
1361
1473
|
}
|
|
1362
|
-
class
|
|
1474
|
+
class He extends i {
|
|
1363
1475
|
constructor(e) {
|
|
1364
1476
|
super("ActorSetPos", e);
|
|
1365
1477
|
t(this, "id");
|
|
@@ -1372,7 +1484,7 @@ class Ee extends n {
|
|
|
1372
1484
|
this.id = parseInt(e[2], 16), this.heading = parseFloat(e[3]), this.unk1 = parseInt(e[4], 16), this.unk2 = parseInt(e[5], 16), this.x = parseFloat(e[6]), this.y = parseFloat(e[7]), this.z = parseFloat(e[8]);
|
|
1373
1485
|
}
|
|
1374
1486
|
}
|
|
1375
|
-
class
|
|
1487
|
+
class Oe extends i {
|
|
1376
1488
|
constructor(e) {
|
|
1377
1489
|
super("SpawnNpcExtra", e);
|
|
1378
1490
|
t(this, "id");
|
|
@@ -1382,7 +1494,7 @@ class Me extends n {
|
|
|
1382
1494
|
this.id = parseInt(e[2], 16), this.parentID = parseInt(e[3], 16), this.tetherID = parseInt(e[4], 16), this.animationState = parseInt(e[5], 16);
|
|
1383
1495
|
}
|
|
1384
1496
|
}
|
|
1385
|
-
class
|
|
1497
|
+
class Te extends i {
|
|
1386
1498
|
constructor(e) {
|
|
1387
1499
|
super("ActorControlExtra", e);
|
|
1388
1500
|
t(this, "id");
|
|
@@ -1394,7 +1506,7 @@ class He extends n {
|
|
|
1394
1506
|
this.id = parseInt(e[2], 16), this.category = parseInt(e[3], 16), this.param1 = parseInt(e[4], 16), this.param2 = parseInt(e[5], 16), this.param3 = parseInt(e[6], 16), this.param4 = parseInt(e[7], 16);
|
|
1395
1507
|
}
|
|
1396
1508
|
}
|
|
1397
|
-
class
|
|
1509
|
+
class Se extends i {
|
|
1398
1510
|
constructor(e) {
|
|
1399
1511
|
super("ActorControlSelfExtra", e);
|
|
1400
1512
|
t(this, "id");
|
|
@@ -1408,181 +1520,181 @@ class Oe extends n {
|
|
|
1408
1520
|
this.id = parseInt(e[2], 16), this.category = parseInt(e[3], 16), this.param1 = parseInt(e[4], 16), this.param2 = parseInt(e[5], 16), this.param3 = parseInt(e[6], 16), this.param4 = parseInt(e[7], 16), this.param5 = parseInt(e[8], 16), this.param6 = parseInt(e[9], 16);
|
|
1409
1521
|
}
|
|
1410
1522
|
}
|
|
1411
|
-
class
|
|
1523
|
+
class Ae extends i {
|
|
1412
1524
|
constructor(e) {
|
|
1413
1525
|
super("Unknown", e);
|
|
1414
1526
|
t(this, "rawLines");
|
|
1415
1527
|
this.rawLines = e;
|
|
1416
1528
|
}
|
|
1417
1529
|
}
|
|
1418
|
-
function
|
|
1530
|
+
function _e(r) {
|
|
1419
1531
|
switch (parseInt(r[0])) {
|
|
1420
1532
|
case 0:
|
|
1421
|
-
return new
|
|
1533
|
+
return new q(r);
|
|
1422
1534
|
case 1:
|
|
1423
|
-
return new
|
|
1535
|
+
return new _(r);
|
|
1424
1536
|
case 2:
|
|
1425
1537
|
return new z(r);
|
|
1426
1538
|
case 3:
|
|
1427
|
-
return new
|
|
1539
|
+
return new B(r);
|
|
1428
1540
|
case 4:
|
|
1429
|
-
return new
|
|
1541
|
+
return new U(r);
|
|
1430
1542
|
case 11:
|
|
1431
|
-
return new
|
|
1543
|
+
return new j(r);
|
|
1432
1544
|
case 12:
|
|
1433
|
-
return new
|
|
1545
|
+
return new V(r);
|
|
1434
1546
|
case 20:
|
|
1435
1547
|
return new W(r);
|
|
1436
1548
|
case 21:
|
|
1437
1549
|
case 22:
|
|
1438
|
-
return new j(r);
|
|
1439
|
-
case 23:
|
|
1440
1550
|
return new G(r);
|
|
1551
|
+
case 23:
|
|
1552
|
+
return new Y(r);
|
|
1441
1553
|
case 24:
|
|
1442
|
-
return new
|
|
1554
|
+
return new Z(r);
|
|
1443
1555
|
case 25:
|
|
1444
|
-
return new
|
|
1556
|
+
return new J(r);
|
|
1445
1557
|
case 26:
|
|
1446
|
-
return new
|
|
1558
|
+
return new X(r);
|
|
1447
1559
|
case 27:
|
|
1448
|
-
return new
|
|
1560
|
+
return new K(r);
|
|
1449
1561
|
case 28:
|
|
1450
|
-
return new
|
|
1562
|
+
return new $(r);
|
|
1451
1563
|
case 29:
|
|
1452
|
-
return new
|
|
1564
|
+
return new Q(r);
|
|
1453
1565
|
case 30:
|
|
1454
|
-
return new
|
|
1566
|
+
return new g(r);
|
|
1455
1567
|
case 31:
|
|
1456
|
-
return new
|
|
1568
|
+
return new ee(r);
|
|
1457
1569
|
case 33:
|
|
1458
|
-
return new
|
|
1570
|
+
return new te(r);
|
|
1459
1571
|
case 34:
|
|
1460
|
-
return new
|
|
1572
|
+
return new se(r);
|
|
1461
1573
|
case 35:
|
|
1462
|
-
return new
|
|
1574
|
+
return new re(r);
|
|
1463
1575
|
case 36:
|
|
1464
|
-
return new
|
|
1576
|
+
return new ae(r);
|
|
1465
1577
|
case 37:
|
|
1466
|
-
return new
|
|
1578
|
+
return new ne(r);
|
|
1467
1579
|
case 38:
|
|
1468
|
-
return new
|
|
1580
|
+
return new ie(r);
|
|
1469
1581
|
case 39:
|
|
1470
|
-
return new
|
|
1582
|
+
return new ce(r);
|
|
1471
1583
|
case 40:
|
|
1472
|
-
return new
|
|
1584
|
+
return new he(r);
|
|
1473
1585
|
case 41:
|
|
1474
|
-
return new
|
|
1586
|
+
return new pe(r);
|
|
1475
1587
|
case 42:
|
|
1476
|
-
return new
|
|
1588
|
+
return new oe(r);
|
|
1477
1589
|
case 251:
|
|
1478
|
-
return new
|
|
1590
|
+
return new de(r);
|
|
1479
1591
|
case 252:
|
|
1480
|
-
return new
|
|
1592
|
+
return new ue(r);
|
|
1481
1593
|
case 253:
|
|
1482
|
-
return new
|
|
1594
|
+
return new Ie(r);
|
|
1483
1595
|
case 254:
|
|
1484
|
-
return new
|
|
1596
|
+
return new me(r);
|
|
1485
1597
|
case 256:
|
|
1486
|
-
return new
|
|
1598
|
+
return new le(r);
|
|
1487
1599
|
case 257:
|
|
1488
|
-
return new
|
|
1600
|
+
return new we(r);
|
|
1489
1601
|
case 258:
|
|
1490
|
-
return new
|
|
1602
|
+
return new ye(r);
|
|
1491
1603
|
case 259:
|
|
1492
|
-
return new
|
|
1604
|
+
return new fe(r);
|
|
1493
1605
|
case 260:
|
|
1494
|
-
return new
|
|
1606
|
+
return new ve(r);
|
|
1495
1607
|
case 261:
|
|
1496
|
-
return new
|
|
1608
|
+
return new be(r);
|
|
1497
1609
|
case 262:
|
|
1498
|
-
return new
|
|
1610
|
+
return new ke(r);
|
|
1499
1611
|
case 263:
|
|
1500
1612
|
return new xe(r);
|
|
1501
1613
|
case 264:
|
|
1502
|
-
return new ke(r);
|
|
1503
|
-
case 265:
|
|
1504
1614
|
return new De(r);
|
|
1505
|
-
case
|
|
1615
|
+
case 265:
|
|
1506
1616
|
return new Pe(r);
|
|
1617
|
+
case 266:
|
|
1618
|
+
return new Ne(r);
|
|
1507
1619
|
case 267:
|
|
1508
|
-
return new
|
|
1620
|
+
return new Ee(r);
|
|
1509
1621
|
case 268:
|
|
1510
|
-
return new Ne(r);
|
|
1511
|
-
case 269:
|
|
1512
1622
|
return new Fe(r);
|
|
1513
|
-
case
|
|
1623
|
+
case 269:
|
|
1514
1624
|
return new Ce(r);
|
|
1625
|
+
case 270:
|
|
1626
|
+
return new Me(r);
|
|
1515
1627
|
case 271:
|
|
1516
|
-
return new
|
|
1628
|
+
return new He(r);
|
|
1517
1629
|
case 272:
|
|
1518
|
-
return new
|
|
1630
|
+
return new Oe(r);
|
|
1519
1631
|
case 273:
|
|
1520
|
-
return new
|
|
1632
|
+
return new Te(r);
|
|
1521
1633
|
case 274:
|
|
1522
|
-
return new
|
|
1634
|
+
return new Se(r);
|
|
1523
1635
|
default:
|
|
1524
|
-
return new
|
|
1636
|
+
return new Ae(r);
|
|
1525
1637
|
}
|
|
1526
1638
|
}
|
|
1527
|
-
let
|
|
1639
|
+
let Le = new R();
|
|
1528
1640
|
(function() {
|
|
1529
|
-
|
|
1641
|
+
Le.Connect();
|
|
1530
1642
|
})();
|
|
1531
1643
|
export {
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1644
|
+
De as AbilityExtra,
|
|
1645
|
+
Te as ActorControlExtra,
|
|
1646
|
+
Se as ActorControlSelfExtra,
|
|
1647
|
+
Me as ActorMove,
|
|
1648
|
+
He as ActorSetPos,
|
|
1649
|
+
B as AddCombatant,
|
|
1650
|
+
Ee as BattleTalk2,
|
|
1651
|
+
fe as CEDirector,
|
|
1540
1652
|
z as ChangePrimaryPlayer,
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1653
|
+
_ as ChangeZone,
|
|
1654
|
+
be as CombatantMemory,
|
|
1655
|
+
Pe as ContentFinderSettings,
|
|
1656
|
+
Fe as Countdown,
|
|
1657
|
+
Ce as CountdownCancel,
|
|
1658
|
+
de as Debug,
|
|
1659
|
+
me as Error,
|
|
1660
|
+
ye as FateDirector,
|
|
1661
|
+
q as GameLogLine,
|
|
1662
|
+
ve as InCombat,
|
|
1663
|
+
ae as LimitBreak,
|
|
1664
|
+
le as LineRegistration,
|
|
1665
|
+
i as LogLineBase,
|
|
1666
|
+
we as MapEffect,
|
|
1667
|
+
he as MapLog,
|
|
1556
1668
|
W as NetowrkStartsCasting,
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1669
|
+
G as NetworkAbility,
|
|
1670
|
+
ne as NetworkActionSync,
|
|
1671
|
+
te as NetworkActorControl,
|
|
1672
|
+
X as NetworkBuff,
|
|
1673
|
+
g as NetworkBuffRemove,
|
|
1674
|
+
Y as NetworkCancelAbility,
|
|
1675
|
+
J as NetworkDeath,
|
|
1676
|
+
Z as NetworkDoT,
|
|
1677
|
+
ee as NetworkGauge,
|
|
1678
|
+
se as NetworkNameToggle,
|
|
1679
|
+
$ as NetworkRaidMarker,
|
|
1680
|
+
ie as NetworkStatusEffects,
|
|
1681
|
+
K as NetworkTargetIcon,
|
|
1682
|
+
Q as NetworkTargetMarker,
|
|
1683
|
+
re as NetworkTether,
|
|
1684
|
+
ce as NetworkUpdateHP,
|
|
1685
|
+
Ne as NpcYell,
|
|
1686
|
+
R as OverlayToolkit,
|
|
1687
|
+
ue as PacketDump,
|
|
1688
|
+
_e as ParseLogLine,
|
|
1689
|
+
j as PartyList,
|
|
1690
|
+
V as PlayerStats,
|
|
1691
|
+
ke as RSVData,
|
|
1692
|
+
U as RemoveCombatant,
|
|
1693
|
+
Oe as SpawnNpcExtra,
|
|
1582
1694
|
xe as StartsUsingExtra,
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1695
|
+
oe as StatusList3,
|
|
1696
|
+
pe as SystemLogMessage,
|
|
1697
|
+
Ae as UnknownLogLine,
|
|
1698
|
+
Ie as Version,
|
|
1699
|
+
Le as default
|
|
1588
1700
|
};
|