ygopro-msg-encode 1.1.11 → 1.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +656 -480
- package/dist/index.cjs.map +3 -3
- package/dist/index.mjs +706 -530
- package/dist/index.mjs.map +3 -3
- package/dist/src/protos/msg/base.d.ts +3 -0
- package/dist/src/protos/msg/index.d.ts +1 -0
- package/dist/src/protos/msg/proto/chain-end.d.ts +4 -0
- package/dist/src/protos/msg/proto/chain-solved.d.ts +4 -0
- package/dist/src/protos/msg/proto/chained.d.ts +4 -0
- package/dist/src/protos/msg/proto/damage-step-end.d.ts +4 -0
- package/dist/src/protos/msg/proto/damage-step-start.d.ts +4 -0
- package/dist/src/protos/msg/proto/flipsummoned.d.ts +4 -0
- package/dist/src/protos/msg/proto/flipsummoning.d.ts +2 -0
- package/dist/src/protos/msg/proto/move.d.ts +2 -0
- package/dist/src/protos/msg/proto/new-phase.d.ts +4 -0
- package/dist/src/protos/msg/proto/new-turn.d.ts +4 -0
- package/dist/src/protos/msg/proto/pos-change.d.ts +2 -0
- package/dist/src/protos/msg/proto/select-battlecmd.d.ts +4 -0
- package/dist/src/protos/msg/proto/select-idlecmd.d.ts +4 -0
- package/dist/src/protos/msg/proto/shuffle-hand.d.ts +4 -0
- package/dist/src/protos/msg/proto/shuffle-set-card.d.ts +4 -0
- package/dist/src/protos/msg/proto/spsummoned.d.ts +4 -0
- package/dist/src/protos/msg/proto/summoned.d.ts +4 -0
- package/dist/src/protos/msg/proto/swap.d.ts +2 -0
- package/dist/src/protos/msg/proto/tag-swap.d.ts +4 -0
- package/dist/src/protos/msg/proto/update-card.d.ts +2 -0
- package/dist/src/protos/msg/query-location.d.ts +7 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1609,10 +1609,7 @@ var YGOProCtosExternalAddress = class extends YGOProCtosBase {
|
|
|
1609
1609
|
return this;
|
|
1610
1610
|
}
|
|
1611
1611
|
toPayload() {
|
|
1612
|
-
const text = this.hostname.length > CTOS_EXTERNAL_ADDRESS_MAX_HOSTNAME_LENGTH ? this.hostname.substring(
|
|
1613
|
-
0,
|
|
1614
|
-
CTOS_EXTERNAL_ADDRESS_MAX_HOSTNAME_LENGTH
|
|
1615
|
-
) : this.hostname;
|
|
1612
|
+
const text = this.hostname.length > CTOS_EXTERNAL_ADDRESS_MAX_HOSTNAME_LENGTH ? this.hostname.substring(0, CTOS_EXTERNAL_ADDRESS_MAX_HOSTNAME_LENGTH) : this.hostname;
|
|
1616
1613
|
const utf16 = new Uint16Array(text.length + 1);
|
|
1617
1614
|
for (let i = 0; i < text.length; i++) {
|
|
1618
1615
|
utf16[i] = text.charCodeAt(i);
|
|
@@ -1871,6 +1868,12 @@ var YGOProMsgBase = class extends PayloadBase {
|
|
|
1871
1868
|
getSendTargets() {
|
|
1872
1869
|
return SEND_TO_ALL;
|
|
1873
1870
|
}
|
|
1871
|
+
getRequireRefreshZones() {
|
|
1872
|
+
return [];
|
|
1873
|
+
}
|
|
1874
|
+
getRequireRefreshCards() {
|
|
1875
|
+
return [];
|
|
1876
|
+
}
|
|
1874
1877
|
};
|
|
1875
1878
|
|
|
1876
1879
|
// src/protos/msg/proto/add-counter.ts
|
|
@@ -2255,532 +2258,6 @@ __decorateClass([
|
|
|
2255
2258
|
BinaryField("u8", 0)
|
|
2256
2259
|
], YGOProMsgChainDisabled.prototype, "chainCount", 2);
|
|
2257
2260
|
|
|
2258
|
-
// src/protos/msg/proto/chain-end.ts
|
|
2259
|
-
var YGOProMsgChainEnd = class extends YGOProMsgBase {
|
|
2260
|
-
static {
|
|
2261
|
-
__name(this, "YGOProMsgChainEnd");
|
|
2262
|
-
}
|
|
2263
|
-
static {
|
|
2264
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_END;
|
|
2265
|
-
}
|
|
2266
|
-
};
|
|
2267
|
-
|
|
2268
|
-
// src/protos/msg/proto/chain-negated.ts
|
|
2269
|
-
var YGOProMsgChainNegated = class extends YGOProMsgBase {
|
|
2270
|
-
static {
|
|
2271
|
-
__name(this, "YGOProMsgChainNegated");
|
|
2272
|
-
}
|
|
2273
|
-
static {
|
|
2274
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_NEGATED;
|
|
2275
|
-
}
|
|
2276
|
-
};
|
|
2277
|
-
__decorateClass([
|
|
2278
|
-
BinaryField("u8", 0)
|
|
2279
|
-
], YGOProMsgChainNegated.prototype, "chainCount", 2);
|
|
2280
|
-
|
|
2281
|
-
// src/protos/msg/proto/chain-solved.ts
|
|
2282
|
-
var YGOProMsgChainSolved = class extends YGOProMsgBase {
|
|
2283
|
-
static {
|
|
2284
|
-
__name(this, "YGOProMsgChainSolved");
|
|
2285
|
-
}
|
|
2286
|
-
static {
|
|
2287
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_SOLVED;
|
|
2288
|
-
}
|
|
2289
|
-
};
|
|
2290
|
-
__decorateClass([
|
|
2291
|
-
BinaryField("u8", 0)
|
|
2292
|
-
], YGOProMsgChainSolved.prototype, "chainCount", 2);
|
|
2293
|
-
|
|
2294
|
-
// src/protos/msg/proto/chain-solving.ts
|
|
2295
|
-
var YGOProMsgChainSolving = class extends YGOProMsgBase {
|
|
2296
|
-
static {
|
|
2297
|
-
__name(this, "YGOProMsgChainSolving");
|
|
2298
|
-
}
|
|
2299
|
-
static {
|
|
2300
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_SOLVING;
|
|
2301
|
-
}
|
|
2302
|
-
};
|
|
2303
|
-
__decorateClass([
|
|
2304
|
-
BinaryField("u8", 0)
|
|
2305
|
-
], YGOProMsgChainSolving.prototype, "chainCount", 2);
|
|
2306
|
-
|
|
2307
|
-
// src/protos/msg/proto/chained.ts
|
|
2308
|
-
var YGOProMsgChained = class extends YGOProMsgBase {
|
|
2309
|
-
static {
|
|
2310
|
-
__name(this, "YGOProMsgChained");
|
|
2311
|
-
}
|
|
2312
|
-
static {
|
|
2313
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAINED;
|
|
2314
|
-
}
|
|
2315
|
-
};
|
|
2316
|
-
__decorateClass([
|
|
2317
|
-
BinaryField("u8", 0)
|
|
2318
|
-
], YGOProMsgChained.prototype, "chainCount", 2);
|
|
2319
|
-
|
|
2320
|
-
// src/protos/msg/proto/chaining.ts
|
|
2321
|
-
var YGOProMsgChaining = class extends YGOProMsgBase {
|
|
2322
|
-
static {
|
|
2323
|
-
__name(this, "YGOProMsgChaining");
|
|
2324
|
-
}
|
|
2325
|
-
static {
|
|
2326
|
-
this.identifier = OcgcoreCommonConstants.MSG_CHAINING;
|
|
2327
|
-
}
|
|
2328
|
-
};
|
|
2329
|
-
__decorateClass([
|
|
2330
|
-
BinaryField("i32", 0)
|
|
2331
|
-
], YGOProMsgChaining.prototype, "code", 2);
|
|
2332
|
-
__decorateClass([
|
|
2333
|
-
BinaryField("u8", 4)
|
|
2334
|
-
], YGOProMsgChaining.prototype, "controller", 2);
|
|
2335
|
-
__decorateClass([
|
|
2336
|
-
BinaryField("u8", 5)
|
|
2337
|
-
], YGOProMsgChaining.prototype, "location", 2);
|
|
2338
|
-
__decorateClass([
|
|
2339
|
-
BinaryField("u8", 6)
|
|
2340
|
-
], YGOProMsgChaining.prototype, "sequence", 2);
|
|
2341
|
-
__decorateClass([
|
|
2342
|
-
BinaryField("u8", 7)
|
|
2343
|
-
], YGOProMsgChaining.prototype, "subsequence", 2);
|
|
2344
|
-
__decorateClass([
|
|
2345
|
-
BinaryField("u8", 8)
|
|
2346
|
-
], YGOProMsgChaining.prototype, "chainCount", 2);
|
|
2347
|
-
__decorateClass([
|
|
2348
|
-
BinaryField("i32", 9)
|
|
2349
|
-
], YGOProMsgChaining.prototype, "desc", 2);
|
|
2350
|
-
__decorateClass([
|
|
2351
|
-
BinaryField("u8", 13)
|
|
2352
|
-
], YGOProMsgChaining.prototype, "chainPlayer", 2);
|
|
2353
|
-
|
|
2354
|
-
// src/protos/msg/proto/confirm-cards.ts
|
|
2355
|
-
var YGOProMsgConfirmCards_CardInfo = class {
|
|
2356
|
-
static {
|
|
2357
|
-
__name(this, "YGOProMsgConfirmCards_CardInfo");
|
|
2358
|
-
}
|
|
2359
|
-
};
|
|
2360
|
-
__decorateClass([
|
|
2361
|
-
BinaryField("i32", 0)
|
|
2362
|
-
], YGOProMsgConfirmCards_CardInfo.prototype, "code", 2);
|
|
2363
|
-
__decorateClass([
|
|
2364
|
-
BinaryField("u8", 4)
|
|
2365
|
-
], YGOProMsgConfirmCards_CardInfo.prototype, "controller", 2);
|
|
2366
|
-
__decorateClass([
|
|
2367
|
-
BinaryField("u8", 5)
|
|
2368
|
-
], YGOProMsgConfirmCards_CardInfo.prototype, "location", 2);
|
|
2369
|
-
__decorateClass([
|
|
2370
|
-
BinaryField("u8", 6)
|
|
2371
|
-
], YGOProMsgConfirmCards_CardInfo.prototype, "sequence", 2);
|
|
2372
|
-
var YGOProMsgConfirmCards = class extends YGOProMsgBase {
|
|
2373
|
-
static {
|
|
2374
|
-
__name(this, "YGOProMsgConfirmCards");
|
|
2375
|
-
}
|
|
2376
|
-
static {
|
|
2377
|
-
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_CARDS;
|
|
2378
|
-
}
|
|
2379
|
-
// 对方视角可能需要隐藏卡片信息
|
|
2380
|
-
opponentView() {
|
|
2381
|
-
const view = this.copy();
|
|
2382
|
-
view.cards = view.cards.map((card) => {
|
|
2383
|
-
const c = { ...card };
|
|
2384
|
-
if (!(c.code & 2147483648)) {
|
|
2385
|
-
c.code = 0;
|
|
2386
|
-
}
|
|
2387
|
-
return c;
|
|
2388
|
-
});
|
|
2389
|
-
return view;
|
|
2390
|
-
}
|
|
2391
|
-
getSendTargets() {
|
|
2392
|
-
if (this.cards.length > 0 && this.cards[0].location === 1) {
|
|
2393
|
-
return [this.player];
|
|
2394
|
-
}
|
|
2395
|
-
return SEND_TO_ALL;
|
|
2396
|
-
}
|
|
2397
|
-
};
|
|
2398
|
-
__decorateClass([
|
|
2399
|
-
BinaryField("u8", 0)
|
|
2400
|
-
], YGOProMsgConfirmCards.prototype, "player", 2);
|
|
2401
|
-
__decorateClass([
|
|
2402
|
-
BinaryField("u8", 1)
|
|
2403
|
-
], YGOProMsgConfirmCards.prototype, "skipPanel", 2);
|
|
2404
|
-
__decorateClass([
|
|
2405
|
-
BinaryField("u8", 2)
|
|
2406
|
-
], YGOProMsgConfirmCards.prototype, "count", 2);
|
|
2407
|
-
__decorateClass([
|
|
2408
|
-
BinaryField(() => YGOProMsgConfirmCards_CardInfo, 3, (obj) => obj.count)
|
|
2409
|
-
], YGOProMsgConfirmCards.prototype, "cards", 2);
|
|
2410
|
-
|
|
2411
|
-
// src/protos/msg/proto/confirm-decktop.ts
|
|
2412
|
-
var YGOProMsgConfirmDeckTop_CardInfo = class {
|
|
2413
|
-
static {
|
|
2414
|
-
__name(this, "YGOProMsgConfirmDeckTop_CardInfo");
|
|
2415
|
-
}
|
|
2416
|
-
};
|
|
2417
|
-
__decorateClass([
|
|
2418
|
-
BinaryField("i32", 0)
|
|
2419
|
-
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "code", 2);
|
|
2420
|
-
__decorateClass([
|
|
2421
|
-
BinaryField("u8", 4)
|
|
2422
|
-
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "controller", 2);
|
|
2423
|
-
__decorateClass([
|
|
2424
|
-
BinaryField("u8", 5)
|
|
2425
|
-
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "location", 2);
|
|
2426
|
-
__decorateClass([
|
|
2427
|
-
BinaryField("u8", 6)
|
|
2428
|
-
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "sequence", 2);
|
|
2429
|
-
var YGOProMsgConfirmDeckTop = class extends YGOProMsgBase {
|
|
2430
|
-
static {
|
|
2431
|
-
__name(this, "YGOProMsgConfirmDeckTop");
|
|
2432
|
-
}
|
|
2433
|
-
static {
|
|
2434
|
-
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_DECKTOP;
|
|
2435
|
-
}
|
|
2436
|
-
// 对方视角可能需要隐藏卡片信息
|
|
2437
|
-
opponentView() {
|
|
2438
|
-
const view = this.copy();
|
|
2439
|
-
view.cards = view.cards.map((card) => {
|
|
2440
|
-
const c = { ...card };
|
|
2441
|
-
if (!(c.code & 2147483648)) {
|
|
2442
|
-
c.code = 0;
|
|
2443
|
-
}
|
|
2444
|
-
return c;
|
|
2445
|
-
});
|
|
2446
|
-
return view;
|
|
2447
|
-
}
|
|
2448
|
-
// confirm-decktop 使用基类的 playerView (基于 player 字段)
|
|
2449
|
-
};
|
|
2450
|
-
__decorateClass([
|
|
2451
|
-
BinaryField("u8", 0)
|
|
2452
|
-
], YGOProMsgConfirmDeckTop.prototype, "player", 2);
|
|
2453
|
-
__decorateClass([
|
|
2454
|
-
BinaryField("u8", 1)
|
|
2455
|
-
], YGOProMsgConfirmDeckTop.prototype, "count", 2);
|
|
2456
|
-
__decorateClass([
|
|
2457
|
-
BinaryField(() => YGOProMsgConfirmDeckTop_CardInfo, 2, (obj) => obj.count)
|
|
2458
|
-
], YGOProMsgConfirmDeckTop.prototype, "cards", 2);
|
|
2459
|
-
|
|
2460
|
-
// src/protos/msg/proto/confirm-extratop.ts
|
|
2461
|
-
var YGOProMsgConfirmExtraTop_CardInfo = class {
|
|
2462
|
-
static {
|
|
2463
|
-
__name(this, "YGOProMsgConfirmExtraTop_CardInfo");
|
|
2464
|
-
}
|
|
2465
|
-
};
|
|
2466
|
-
__decorateClass([
|
|
2467
|
-
BinaryField("i32", 0)
|
|
2468
|
-
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "code", 2);
|
|
2469
|
-
__decorateClass([
|
|
2470
|
-
BinaryField("u8", 4)
|
|
2471
|
-
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "controller", 2);
|
|
2472
|
-
__decorateClass([
|
|
2473
|
-
BinaryField("u8", 5)
|
|
2474
|
-
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "location", 2);
|
|
2475
|
-
__decorateClass([
|
|
2476
|
-
BinaryField("u8", 6)
|
|
2477
|
-
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "sequence", 2);
|
|
2478
|
-
var YGOProMsgConfirmExtraTop = class extends YGOProMsgBase {
|
|
2479
|
-
static {
|
|
2480
|
-
__name(this, "YGOProMsgConfirmExtraTop");
|
|
2481
|
-
}
|
|
2482
|
-
static {
|
|
2483
|
-
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_EXTRATOP;
|
|
2484
|
-
}
|
|
2485
|
-
// 对方视角可能需要隐藏卡片信息
|
|
2486
|
-
opponentView() {
|
|
2487
|
-
const view = this.copy();
|
|
2488
|
-
view.cards = view.cards.map((card) => {
|
|
2489
|
-
const c = { ...card };
|
|
2490
|
-
if (!(c.code & 2147483648)) {
|
|
2491
|
-
c.code = 0;
|
|
2492
|
-
}
|
|
2493
|
-
return c;
|
|
2494
|
-
});
|
|
2495
|
-
return view;
|
|
2496
|
-
}
|
|
2497
|
-
// confirm-extratop 使用基类的 playerView (基于 player 字段)
|
|
2498
|
-
};
|
|
2499
|
-
__decorateClass([
|
|
2500
|
-
BinaryField("u8", 0)
|
|
2501
|
-
], YGOProMsgConfirmExtraTop.prototype, "player", 2);
|
|
2502
|
-
__decorateClass([
|
|
2503
|
-
BinaryField("u8", 1)
|
|
2504
|
-
], YGOProMsgConfirmExtraTop.prototype, "count", 2);
|
|
2505
|
-
__decorateClass([
|
|
2506
|
-
BinaryField(() => YGOProMsgConfirmExtraTop_CardInfo, 2, (obj) => obj.count)
|
|
2507
|
-
], YGOProMsgConfirmExtraTop.prototype, "cards", 2);
|
|
2508
|
-
|
|
2509
|
-
// src/protos/msg/proto/damage.ts
|
|
2510
|
-
var YGOProMsgDamage = class extends YGOProMsgBase {
|
|
2511
|
-
static {
|
|
2512
|
-
__name(this, "YGOProMsgDamage");
|
|
2513
|
-
}
|
|
2514
|
-
static {
|
|
2515
|
-
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE;
|
|
2516
|
-
}
|
|
2517
|
-
};
|
|
2518
|
-
__decorateClass([
|
|
2519
|
-
BinaryField("u8", 0)
|
|
2520
|
-
], YGOProMsgDamage.prototype, "player", 2);
|
|
2521
|
-
__decorateClass([
|
|
2522
|
-
BinaryField("i32", 1)
|
|
2523
|
-
], YGOProMsgDamage.prototype, "value", 2);
|
|
2524
|
-
|
|
2525
|
-
// src/protos/msg/proto/damage-step-end.ts
|
|
2526
|
-
var YGOProMsgDamageStepEnd = class extends YGOProMsgBase {
|
|
2527
|
-
static {
|
|
2528
|
-
__name(this, "YGOProMsgDamageStepEnd");
|
|
2529
|
-
}
|
|
2530
|
-
static {
|
|
2531
|
-
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE_STEP_END;
|
|
2532
|
-
}
|
|
2533
|
-
};
|
|
2534
|
-
|
|
2535
|
-
// src/protos/msg/proto/damage-step-start.ts
|
|
2536
|
-
var YGOProMsgDamageStepStart = class extends YGOProMsgBase {
|
|
2537
|
-
static {
|
|
2538
|
-
__name(this, "YGOProMsgDamageStepStart");
|
|
2539
|
-
}
|
|
2540
|
-
static {
|
|
2541
|
-
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE_STEP_START;
|
|
2542
|
-
}
|
|
2543
|
-
};
|
|
2544
|
-
|
|
2545
|
-
// src/protos/msg/proto/deck-top.ts
|
|
2546
|
-
var YGOProMsgDeckTop = class extends YGOProMsgBase {
|
|
2547
|
-
static {
|
|
2548
|
-
__name(this, "YGOProMsgDeckTop");
|
|
2549
|
-
}
|
|
2550
|
-
static {
|
|
2551
|
-
this.identifier = OcgcoreCommonConstants.MSG_DECK_TOP;
|
|
2552
|
-
}
|
|
2553
|
-
// 对方视角可能需要隐藏卡片信息
|
|
2554
|
-
opponentView() {
|
|
2555
|
-
const view = this.copy();
|
|
2556
|
-
if (!(view.code & 2147483648)) {
|
|
2557
|
-
view.code = 0;
|
|
2558
|
-
}
|
|
2559
|
-
return view;
|
|
2560
|
-
}
|
|
2561
|
-
// deck-top 使用基类的 playerView (基于 player 字段)
|
|
2562
|
-
};
|
|
2563
|
-
__decorateClass([
|
|
2564
|
-
BinaryField("u8", 0)
|
|
2565
|
-
], YGOProMsgDeckTop.prototype, "player", 2);
|
|
2566
|
-
__decorateClass([
|
|
2567
|
-
BinaryField("u8", 1)
|
|
2568
|
-
], YGOProMsgDeckTop.prototype, "sequence", 2);
|
|
2569
|
-
__decorateClass([
|
|
2570
|
-
BinaryField("i32", 2)
|
|
2571
|
-
], YGOProMsgDeckTop.prototype, "code", 2);
|
|
2572
|
-
|
|
2573
|
-
// src/protos/msg/proto/draw.ts
|
|
2574
|
-
var YGOProMsgDraw = class extends YGOProMsgBase {
|
|
2575
|
-
static {
|
|
2576
|
-
__name(this, "YGOProMsgDraw");
|
|
2577
|
-
}
|
|
2578
|
-
static {
|
|
2579
|
-
this.identifier = OcgcoreCommonConstants.MSG_DRAW;
|
|
2580
|
-
}
|
|
2581
|
-
// 对方视角需要隐藏抽到的卡(如果卡片标志位 0x80 未设置)
|
|
2582
|
-
opponentView() {
|
|
2583
|
-
const view = this.copy();
|
|
2584
|
-
view.cards = view.cards.map((card) => {
|
|
2585
|
-
if (!(card & 2147483648)) {
|
|
2586
|
-
return 0;
|
|
2587
|
-
}
|
|
2588
|
-
return card;
|
|
2589
|
-
});
|
|
2590
|
-
return view;
|
|
2591
|
-
}
|
|
2592
|
-
};
|
|
2593
|
-
__decorateClass([
|
|
2594
|
-
BinaryField("u8", 0)
|
|
2595
|
-
], YGOProMsgDraw.prototype, "player", 2);
|
|
2596
|
-
__decorateClass([
|
|
2597
|
-
BinaryField("u8", 1)
|
|
2598
|
-
], YGOProMsgDraw.prototype, "count", 2);
|
|
2599
|
-
__decorateClass([
|
|
2600
|
-
BinaryField("i32", 2, (obj) => obj.count)
|
|
2601
|
-
], YGOProMsgDraw.prototype, "cards", 2);
|
|
2602
|
-
|
|
2603
|
-
// src/protos/msg/proto/equip.ts
|
|
2604
|
-
var YGOProMsgEquip_CardLocation = class {
|
|
2605
|
-
static {
|
|
2606
|
-
__name(this, "YGOProMsgEquip_CardLocation");
|
|
2607
|
-
}
|
|
2608
|
-
};
|
|
2609
|
-
__decorateClass([
|
|
2610
|
-
BinaryField("u8", 0)
|
|
2611
|
-
], YGOProMsgEquip_CardLocation.prototype, "controller", 2);
|
|
2612
|
-
__decorateClass([
|
|
2613
|
-
BinaryField("u8", 1)
|
|
2614
|
-
], YGOProMsgEquip_CardLocation.prototype, "location", 2);
|
|
2615
|
-
__decorateClass([
|
|
2616
|
-
BinaryField("u8", 2)
|
|
2617
|
-
], YGOProMsgEquip_CardLocation.prototype, "sequence", 2);
|
|
2618
|
-
var YGOProMsgEquip = class extends YGOProMsgBase {
|
|
2619
|
-
static {
|
|
2620
|
-
__name(this, "YGOProMsgEquip");
|
|
2621
|
-
}
|
|
2622
|
-
static {
|
|
2623
|
-
this.identifier = OcgcoreCommonConstants.MSG_EQUIP;
|
|
2624
|
-
}
|
|
2625
|
-
};
|
|
2626
|
-
__decorateClass([
|
|
2627
|
-
BinaryField(() => YGOProMsgEquip_CardLocation, 0)
|
|
2628
|
-
], YGOProMsgEquip.prototype, "equip", 2);
|
|
2629
|
-
__decorateClass([
|
|
2630
|
-
BinaryField(() => YGOProMsgEquip_CardLocation, 3)
|
|
2631
|
-
], YGOProMsgEquip.prototype, "target", 2);
|
|
2632
|
-
__decorateClass([
|
|
2633
|
-
BinaryField("u8", 6)
|
|
2634
|
-
], YGOProMsgEquip.prototype, "position", 2);
|
|
2635
|
-
|
|
2636
|
-
// src/protos/msg/proto/field-disabled.ts
|
|
2637
|
-
var YGOProMsgFieldDisabled = class extends YGOProMsgBase {
|
|
2638
|
-
static {
|
|
2639
|
-
__name(this, "YGOProMsgFieldDisabled");
|
|
2640
|
-
}
|
|
2641
|
-
static {
|
|
2642
|
-
this.identifier = OcgcoreCommonConstants.MSG_FIELD_DISABLED;
|
|
2643
|
-
}
|
|
2644
|
-
};
|
|
2645
|
-
__decorateClass([
|
|
2646
|
-
BinaryField("u32", 0)
|
|
2647
|
-
], YGOProMsgFieldDisabled.prototype, "disabledField", 2);
|
|
2648
|
-
|
|
2649
|
-
// src/protos/msg/proto/flipsummoned.ts
|
|
2650
|
-
var YGOProMsgFlipSummoned = class extends YGOProMsgBase {
|
|
2651
|
-
static {
|
|
2652
|
-
__name(this, "YGOProMsgFlipSummoned");
|
|
2653
|
-
}
|
|
2654
|
-
static {
|
|
2655
|
-
this.identifier = OcgcoreCommonConstants.MSG_FLIPSUMMONED;
|
|
2656
|
-
}
|
|
2657
|
-
};
|
|
2658
|
-
|
|
2659
|
-
// src/protos/msg/proto/flipsummoning.ts
|
|
2660
|
-
var YGOProMsgFlipSummoning = class extends YGOProMsgBase {
|
|
2661
|
-
static {
|
|
2662
|
-
__name(this, "YGOProMsgFlipSummoning");
|
|
2663
|
-
}
|
|
2664
|
-
static {
|
|
2665
|
-
this.identifier = OcgcoreCommonConstants.MSG_FLIPSUMMONING;
|
|
2666
|
-
}
|
|
2667
|
-
};
|
|
2668
|
-
__decorateClass([
|
|
2669
|
-
BinaryField("i32", 0)
|
|
2670
|
-
], YGOProMsgFlipSummoning.prototype, "code", 2);
|
|
2671
|
-
__decorateClass([
|
|
2672
|
-
BinaryField("u8", 4)
|
|
2673
|
-
], YGOProMsgFlipSummoning.prototype, "controller", 2);
|
|
2674
|
-
__decorateClass([
|
|
2675
|
-
BinaryField("u8", 5)
|
|
2676
|
-
], YGOProMsgFlipSummoning.prototype, "location", 2);
|
|
2677
|
-
__decorateClass([
|
|
2678
|
-
BinaryField("u8", 6)
|
|
2679
|
-
], YGOProMsgFlipSummoning.prototype, "sequence", 2);
|
|
2680
|
-
__decorateClass([
|
|
2681
|
-
BinaryField("u8", 7)
|
|
2682
|
-
], YGOProMsgFlipSummoning.prototype, "position", 2);
|
|
2683
|
-
|
|
2684
|
-
// src/protos/msg/proto/hand-res.ts
|
|
2685
|
-
var YGOProMsgHandRes = class extends YGOProMsgBase {
|
|
2686
|
-
static {
|
|
2687
|
-
__name(this, "YGOProMsgHandRes");
|
|
2688
|
-
}
|
|
2689
|
-
static {
|
|
2690
|
-
this.identifier = OcgcoreCommonConstants.MSG_HAND_RES;
|
|
2691
|
-
}
|
|
2692
|
-
};
|
|
2693
|
-
__decorateClass([
|
|
2694
|
-
BinaryField("u8", 0)
|
|
2695
|
-
], YGOProMsgHandRes.prototype, "result", 2);
|
|
2696
|
-
|
|
2697
|
-
// src/protos/msg/proto/hint.ts
|
|
2698
|
-
var HINT_TYPES_SEND_TO_SELF = /* @__PURE__ */ new Set([1, 2, 3, 5]);
|
|
2699
|
-
var HINT_TYPES_SEND_TO_OPPONENT = /* @__PURE__ */ new Set([4, 6, 7, 8, 9, 11]);
|
|
2700
|
-
var YGOProMsgHint = class extends YGOProMsgBase {
|
|
2701
|
-
static {
|
|
2702
|
-
__name(this, "YGOProMsgHint");
|
|
2703
|
-
}
|
|
2704
|
-
static {
|
|
2705
|
-
this.identifier = OcgcoreCommonConstants.MSG_HINT;
|
|
2706
|
-
}
|
|
2707
|
-
getSendTargets() {
|
|
2708
|
-
if (HINT_TYPES_SEND_TO_SELF.has(this.type)) {
|
|
2709
|
-
return [this.player];
|
|
2710
|
-
}
|
|
2711
|
-
if (HINT_TYPES_SEND_TO_OPPONENT.has(this.type)) {
|
|
2712
|
-
return [1 - this.player, 7 /* OBSERVER */];
|
|
2713
|
-
}
|
|
2714
|
-
return SEND_TO_ALL;
|
|
2715
|
-
}
|
|
2716
|
-
};
|
|
2717
|
-
__decorateClass([
|
|
2718
|
-
BinaryField("u8", 0)
|
|
2719
|
-
], YGOProMsgHint.prototype, "type", 2);
|
|
2720
|
-
__decorateClass([
|
|
2721
|
-
BinaryField("u8", 1)
|
|
2722
|
-
], YGOProMsgHint.prototype, "player", 2);
|
|
2723
|
-
__decorateClass([
|
|
2724
|
-
BinaryField("i32", 2)
|
|
2725
|
-
], YGOProMsgHint.prototype, "desc", 2);
|
|
2726
|
-
|
|
2727
|
-
// src/protos/msg/proto/lpupdate.ts
|
|
2728
|
-
var YGOProMsgLpUpdate = class extends YGOProMsgBase {
|
|
2729
|
-
static {
|
|
2730
|
-
__name(this, "YGOProMsgLpUpdate");
|
|
2731
|
-
}
|
|
2732
|
-
static {
|
|
2733
|
-
this.identifier = OcgcoreCommonConstants.MSG_LPUPDATE;
|
|
2734
|
-
}
|
|
2735
|
-
};
|
|
2736
|
-
__decorateClass([
|
|
2737
|
-
BinaryField("u8", 0)
|
|
2738
|
-
], YGOProMsgLpUpdate.prototype, "player", 2);
|
|
2739
|
-
__decorateClass([
|
|
2740
|
-
BinaryField("i32", 1)
|
|
2741
|
-
], YGOProMsgLpUpdate.prototype, "lp", 2);
|
|
2742
|
-
|
|
2743
|
-
// src/protos/msg/proto/match-kill.ts
|
|
2744
|
-
var YGOProMsgMatchKill = class extends YGOProMsgBase {
|
|
2745
|
-
static {
|
|
2746
|
-
__name(this, "YGOProMsgMatchKill");
|
|
2747
|
-
}
|
|
2748
|
-
static {
|
|
2749
|
-
this.identifier = OcgcoreCommonConstants.MSG_MATCH_KILL;
|
|
2750
|
-
}
|
|
2751
|
-
};
|
|
2752
|
-
__decorateClass([
|
|
2753
|
-
BinaryField("i32", 0)
|
|
2754
|
-
], YGOProMsgMatchKill.prototype, "code", 2);
|
|
2755
|
-
|
|
2756
|
-
// src/protos/msg/proto/missed-effect.ts
|
|
2757
|
-
var YGOProMsgMissedEffect = class extends YGOProMsgBase {
|
|
2758
|
-
static {
|
|
2759
|
-
__name(this, "YGOProMsgMissedEffect");
|
|
2760
|
-
}
|
|
2761
|
-
static {
|
|
2762
|
-
this.identifier = OcgcoreCommonConstants.MSG_MISSED_EFFECT;
|
|
2763
|
-
}
|
|
2764
|
-
getSendTargets() {
|
|
2765
|
-
return [this.controller];
|
|
2766
|
-
}
|
|
2767
|
-
};
|
|
2768
|
-
__decorateClass([
|
|
2769
|
-
BinaryField("u8", 0)
|
|
2770
|
-
], YGOProMsgMissedEffect.prototype, "controller", 2);
|
|
2771
|
-
__decorateClass([
|
|
2772
|
-
BinaryField("u8", 1)
|
|
2773
|
-
], YGOProMsgMissedEffect.prototype, "location", 2);
|
|
2774
|
-
__decorateClass([
|
|
2775
|
-
BinaryField("u8", 2)
|
|
2776
|
-
], YGOProMsgMissedEffect.prototype, "sequence", 2);
|
|
2777
|
-
__decorateClass([
|
|
2778
|
-
BinaryField("u8", 3)
|
|
2779
|
-
], YGOProMsgMissedEffect.prototype, "position", 2);
|
|
2780
|
-
__decorateClass([
|
|
2781
|
-
BinaryField("i32", 4)
|
|
2782
|
-
], YGOProMsgMissedEffect.prototype, "code", 2);
|
|
2783
|
-
|
|
2784
2261
|
// src/vendor/script-constants.ts
|
|
2785
2262
|
var OcgcoreScriptConstants = {
|
|
2786
2263
|
ACTIVITY_ATTACK: 5,
|
|
@@ -3619,6 +3096,581 @@ var OcgcoreScriptConstants = {
|
|
|
3619
3096
|
TYPE_XYZ: 8388608
|
|
3620
3097
|
};
|
|
3621
3098
|
|
|
3099
|
+
// src/protos/msg/proto/chain-end.ts
|
|
3100
|
+
var YGOProMsgChainEnd = class extends YGOProMsgBase {
|
|
3101
|
+
static {
|
|
3102
|
+
__name(this, "YGOProMsgChainEnd");
|
|
3103
|
+
}
|
|
3104
|
+
static {
|
|
3105
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_END;
|
|
3106
|
+
}
|
|
3107
|
+
getRequireRefreshZones() {
|
|
3108
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
3109
|
+
return [
|
|
3110
|
+
{ player: 0, location },
|
|
3111
|
+
{ player: 1, location }
|
|
3112
|
+
];
|
|
3113
|
+
}
|
|
3114
|
+
};
|
|
3115
|
+
|
|
3116
|
+
// src/protos/msg/proto/chain-negated.ts
|
|
3117
|
+
var YGOProMsgChainNegated = class extends YGOProMsgBase {
|
|
3118
|
+
static {
|
|
3119
|
+
__name(this, "YGOProMsgChainNegated");
|
|
3120
|
+
}
|
|
3121
|
+
static {
|
|
3122
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_NEGATED;
|
|
3123
|
+
}
|
|
3124
|
+
};
|
|
3125
|
+
__decorateClass([
|
|
3126
|
+
BinaryField("u8", 0)
|
|
3127
|
+
], YGOProMsgChainNegated.prototype, "chainCount", 2);
|
|
3128
|
+
|
|
3129
|
+
// src/protos/msg/proto/chain-solved.ts
|
|
3130
|
+
var YGOProMsgChainSolved = class extends YGOProMsgBase {
|
|
3131
|
+
static {
|
|
3132
|
+
__name(this, "YGOProMsgChainSolved");
|
|
3133
|
+
}
|
|
3134
|
+
static {
|
|
3135
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_SOLVED;
|
|
3136
|
+
}
|
|
3137
|
+
getRequireRefreshZones() {
|
|
3138
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
3139
|
+
return [
|
|
3140
|
+
{ player: 0, location },
|
|
3141
|
+
{ player: 1, location }
|
|
3142
|
+
];
|
|
3143
|
+
}
|
|
3144
|
+
};
|
|
3145
|
+
__decorateClass([
|
|
3146
|
+
BinaryField("u8", 0)
|
|
3147
|
+
], YGOProMsgChainSolved.prototype, "chainCount", 2);
|
|
3148
|
+
|
|
3149
|
+
// src/protos/msg/proto/chain-solving.ts
|
|
3150
|
+
var YGOProMsgChainSolving = class extends YGOProMsgBase {
|
|
3151
|
+
static {
|
|
3152
|
+
__name(this, "YGOProMsgChainSolving");
|
|
3153
|
+
}
|
|
3154
|
+
static {
|
|
3155
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAIN_SOLVING;
|
|
3156
|
+
}
|
|
3157
|
+
};
|
|
3158
|
+
__decorateClass([
|
|
3159
|
+
BinaryField("u8", 0)
|
|
3160
|
+
], YGOProMsgChainSolving.prototype, "chainCount", 2);
|
|
3161
|
+
|
|
3162
|
+
// src/protos/msg/proto/chained.ts
|
|
3163
|
+
var YGOProMsgChained = class extends YGOProMsgBase {
|
|
3164
|
+
static {
|
|
3165
|
+
__name(this, "YGOProMsgChained");
|
|
3166
|
+
}
|
|
3167
|
+
static {
|
|
3168
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAINED;
|
|
3169
|
+
}
|
|
3170
|
+
getRequireRefreshZones() {
|
|
3171
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
3172
|
+
return [
|
|
3173
|
+
{ player: 0, location },
|
|
3174
|
+
{ player: 1, location }
|
|
3175
|
+
];
|
|
3176
|
+
}
|
|
3177
|
+
};
|
|
3178
|
+
__decorateClass([
|
|
3179
|
+
BinaryField("u8", 0)
|
|
3180
|
+
], YGOProMsgChained.prototype, "chainCount", 2);
|
|
3181
|
+
|
|
3182
|
+
// src/protos/msg/proto/chaining.ts
|
|
3183
|
+
var YGOProMsgChaining = class extends YGOProMsgBase {
|
|
3184
|
+
static {
|
|
3185
|
+
__name(this, "YGOProMsgChaining");
|
|
3186
|
+
}
|
|
3187
|
+
static {
|
|
3188
|
+
this.identifier = OcgcoreCommonConstants.MSG_CHAINING;
|
|
3189
|
+
}
|
|
3190
|
+
};
|
|
3191
|
+
__decorateClass([
|
|
3192
|
+
BinaryField("i32", 0)
|
|
3193
|
+
], YGOProMsgChaining.prototype, "code", 2);
|
|
3194
|
+
__decorateClass([
|
|
3195
|
+
BinaryField("u8", 4)
|
|
3196
|
+
], YGOProMsgChaining.prototype, "controller", 2);
|
|
3197
|
+
__decorateClass([
|
|
3198
|
+
BinaryField("u8", 5)
|
|
3199
|
+
], YGOProMsgChaining.prototype, "location", 2);
|
|
3200
|
+
__decorateClass([
|
|
3201
|
+
BinaryField("u8", 6)
|
|
3202
|
+
], YGOProMsgChaining.prototype, "sequence", 2);
|
|
3203
|
+
__decorateClass([
|
|
3204
|
+
BinaryField("u8", 7)
|
|
3205
|
+
], YGOProMsgChaining.prototype, "subsequence", 2);
|
|
3206
|
+
__decorateClass([
|
|
3207
|
+
BinaryField("u8", 8)
|
|
3208
|
+
], YGOProMsgChaining.prototype, "chainCount", 2);
|
|
3209
|
+
__decorateClass([
|
|
3210
|
+
BinaryField("i32", 9)
|
|
3211
|
+
], YGOProMsgChaining.prototype, "desc", 2);
|
|
3212
|
+
__decorateClass([
|
|
3213
|
+
BinaryField("u8", 13)
|
|
3214
|
+
], YGOProMsgChaining.prototype, "chainPlayer", 2);
|
|
3215
|
+
|
|
3216
|
+
// src/protos/msg/proto/confirm-cards.ts
|
|
3217
|
+
var YGOProMsgConfirmCards_CardInfo = class {
|
|
3218
|
+
static {
|
|
3219
|
+
__name(this, "YGOProMsgConfirmCards_CardInfo");
|
|
3220
|
+
}
|
|
3221
|
+
};
|
|
3222
|
+
__decorateClass([
|
|
3223
|
+
BinaryField("i32", 0)
|
|
3224
|
+
], YGOProMsgConfirmCards_CardInfo.prototype, "code", 2);
|
|
3225
|
+
__decorateClass([
|
|
3226
|
+
BinaryField("u8", 4)
|
|
3227
|
+
], YGOProMsgConfirmCards_CardInfo.prototype, "controller", 2);
|
|
3228
|
+
__decorateClass([
|
|
3229
|
+
BinaryField("u8", 5)
|
|
3230
|
+
], YGOProMsgConfirmCards_CardInfo.prototype, "location", 2);
|
|
3231
|
+
__decorateClass([
|
|
3232
|
+
BinaryField("u8", 6)
|
|
3233
|
+
], YGOProMsgConfirmCards_CardInfo.prototype, "sequence", 2);
|
|
3234
|
+
var YGOProMsgConfirmCards = class extends YGOProMsgBase {
|
|
3235
|
+
static {
|
|
3236
|
+
__name(this, "YGOProMsgConfirmCards");
|
|
3237
|
+
}
|
|
3238
|
+
static {
|
|
3239
|
+
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_CARDS;
|
|
3240
|
+
}
|
|
3241
|
+
// 对方视角可能需要隐藏卡片信息
|
|
3242
|
+
opponentView() {
|
|
3243
|
+
const view = this.copy();
|
|
3244
|
+
view.cards = view.cards.map((card) => {
|
|
3245
|
+
const c = { ...card };
|
|
3246
|
+
if (!(c.code & 2147483648)) {
|
|
3247
|
+
c.code = 0;
|
|
3248
|
+
}
|
|
3249
|
+
return c;
|
|
3250
|
+
});
|
|
3251
|
+
return view;
|
|
3252
|
+
}
|
|
3253
|
+
getSendTargets() {
|
|
3254
|
+
if (this.cards.length > 0 && this.cards[0].location === 1) {
|
|
3255
|
+
return [this.player];
|
|
3256
|
+
}
|
|
3257
|
+
return SEND_TO_ALL;
|
|
3258
|
+
}
|
|
3259
|
+
};
|
|
3260
|
+
__decorateClass([
|
|
3261
|
+
BinaryField("u8", 0)
|
|
3262
|
+
], YGOProMsgConfirmCards.prototype, "player", 2);
|
|
3263
|
+
__decorateClass([
|
|
3264
|
+
BinaryField("u8", 1)
|
|
3265
|
+
], YGOProMsgConfirmCards.prototype, "skipPanel", 2);
|
|
3266
|
+
__decorateClass([
|
|
3267
|
+
BinaryField("u8", 2)
|
|
3268
|
+
], YGOProMsgConfirmCards.prototype, "count", 2);
|
|
3269
|
+
__decorateClass([
|
|
3270
|
+
BinaryField(() => YGOProMsgConfirmCards_CardInfo, 3, (obj) => obj.count)
|
|
3271
|
+
], YGOProMsgConfirmCards.prototype, "cards", 2);
|
|
3272
|
+
|
|
3273
|
+
// src/protos/msg/proto/confirm-decktop.ts
|
|
3274
|
+
var YGOProMsgConfirmDeckTop_CardInfo = class {
|
|
3275
|
+
static {
|
|
3276
|
+
__name(this, "YGOProMsgConfirmDeckTop_CardInfo");
|
|
3277
|
+
}
|
|
3278
|
+
};
|
|
3279
|
+
__decorateClass([
|
|
3280
|
+
BinaryField("i32", 0)
|
|
3281
|
+
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "code", 2);
|
|
3282
|
+
__decorateClass([
|
|
3283
|
+
BinaryField("u8", 4)
|
|
3284
|
+
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "controller", 2);
|
|
3285
|
+
__decorateClass([
|
|
3286
|
+
BinaryField("u8", 5)
|
|
3287
|
+
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "location", 2);
|
|
3288
|
+
__decorateClass([
|
|
3289
|
+
BinaryField("u8", 6)
|
|
3290
|
+
], YGOProMsgConfirmDeckTop_CardInfo.prototype, "sequence", 2);
|
|
3291
|
+
var YGOProMsgConfirmDeckTop = class extends YGOProMsgBase {
|
|
3292
|
+
static {
|
|
3293
|
+
__name(this, "YGOProMsgConfirmDeckTop");
|
|
3294
|
+
}
|
|
3295
|
+
static {
|
|
3296
|
+
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_DECKTOP;
|
|
3297
|
+
}
|
|
3298
|
+
// 对方视角可能需要隐藏卡片信息
|
|
3299
|
+
opponentView() {
|
|
3300
|
+
const view = this.copy();
|
|
3301
|
+
view.cards = view.cards.map((card) => {
|
|
3302
|
+
const c = { ...card };
|
|
3303
|
+
if (!(c.code & 2147483648)) {
|
|
3304
|
+
c.code = 0;
|
|
3305
|
+
}
|
|
3306
|
+
return c;
|
|
3307
|
+
});
|
|
3308
|
+
return view;
|
|
3309
|
+
}
|
|
3310
|
+
// confirm-decktop 使用基类的 playerView (基于 player 字段)
|
|
3311
|
+
};
|
|
3312
|
+
__decorateClass([
|
|
3313
|
+
BinaryField("u8", 0)
|
|
3314
|
+
], YGOProMsgConfirmDeckTop.prototype, "player", 2);
|
|
3315
|
+
__decorateClass([
|
|
3316
|
+
BinaryField("u8", 1)
|
|
3317
|
+
], YGOProMsgConfirmDeckTop.prototype, "count", 2);
|
|
3318
|
+
__decorateClass([
|
|
3319
|
+
BinaryField(() => YGOProMsgConfirmDeckTop_CardInfo, 2, (obj) => obj.count)
|
|
3320
|
+
], YGOProMsgConfirmDeckTop.prototype, "cards", 2);
|
|
3321
|
+
|
|
3322
|
+
// src/protos/msg/proto/confirm-extratop.ts
|
|
3323
|
+
var YGOProMsgConfirmExtraTop_CardInfo = class {
|
|
3324
|
+
static {
|
|
3325
|
+
__name(this, "YGOProMsgConfirmExtraTop_CardInfo");
|
|
3326
|
+
}
|
|
3327
|
+
};
|
|
3328
|
+
__decorateClass([
|
|
3329
|
+
BinaryField("i32", 0)
|
|
3330
|
+
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "code", 2);
|
|
3331
|
+
__decorateClass([
|
|
3332
|
+
BinaryField("u8", 4)
|
|
3333
|
+
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "controller", 2);
|
|
3334
|
+
__decorateClass([
|
|
3335
|
+
BinaryField("u8", 5)
|
|
3336
|
+
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "location", 2);
|
|
3337
|
+
__decorateClass([
|
|
3338
|
+
BinaryField("u8", 6)
|
|
3339
|
+
], YGOProMsgConfirmExtraTop_CardInfo.prototype, "sequence", 2);
|
|
3340
|
+
var YGOProMsgConfirmExtraTop = class extends YGOProMsgBase {
|
|
3341
|
+
static {
|
|
3342
|
+
__name(this, "YGOProMsgConfirmExtraTop");
|
|
3343
|
+
}
|
|
3344
|
+
static {
|
|
3345
|
+
this.identifier = OcgcoreCommonConstants.MSG_CONFIRM_EXTRATOP;
|
|
3346
|
+
}
|
|
3347
|
+
// 对方视角可能需要隐藏卡片信息
|
|
3348
|
+
opponentView() {
|
|
3349
|
+
const view = this.copy();
|
|
3350
|
+
view.cards = view.cards.map((card) => {
|
|
3351
|
+
const c = { ...card };
|
|
3352
|
+
if (!(c.code & 2147483648)) {
|
|
3353
|
+
c.code = 0;
|
|
3354
|
+
}
|
|
3355
|
+
return c;
|
|
3356
|
+
});
|
|
3357
|
+
return view;
|
|
3358
|
+
}
|
|
3359
|
+
// confirm-extratop 使用基类的 playerView (基于 player 字段)
|
|
3360
|
+
};
|
|
3361
|
+
__decorateClass([
|
|
3362
|
+
BinaryField("u8", 0)
|
|
3363
|
+
], YGOProMsgConfirmExtraTop.prototype, "player", 2);
|
|
3364
|
+
__decorateClass([
|
|
3365
|
+
BinaryField("u8", 1)
|
|
3366
|
+
], YGOProMsgConfirmExtraTop.prototype, "count", 2);
|
|
3367
|
+
__decorateClass([
|
|
3368
|
+
BinaryField(() => YGOProMsgConfirmExtraTop_CardInfo, 2, (obj) => obj.count)
|
|
3369
|
+
], YGOProMsgConfirmExtraTop.prototype, "cards", 2);
|
|
3370
|
+
|
|
3371
|
+
// src/protos/msg/proto/damage.ts
|
|
3372
|
+
var YGOProMsgDamage = class extends YGOProMsgBase {
|
|
3373
|
+
static {
|
|
3374
|
+
__name(this, "YGOProMsgDamage");
|
|
3375
|
+
}
|
|
3376
|
+
static {
|
|
3377
|
+
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE;
|
|
3378
|
+
}
|
|
3379
|
+
};
|
|
3380
|
+
__decorateClass([
|
|
3381
|
+
BinaryField("u8", 0)
|
|
3382
|
+
], YGOProMsgDamage.prototype, "player", 2);
|
|
3383
|
+
__decorateClass([
|
|
3384
|
+
BinaryField("i32", 1)
|
|
3385
|
+
], YGOProMsgDamage.prototype, "value", 2);
|
|
3386
|
+
|
|
3387
|
+
// src/protos/msg/proto/damage-step-end.ts
|
|
3388
|
+
var YGOProMsgDamageStepEnd = class extends YGOProMsgBase {
|
|
3389
|
+
static {
|
|
3390
|
+
__name(this, "YGOProMsgDamageStepEnd");
|
|
3391
|
+
}
|
|
3392
|
+
static {
|
|
3393
|
+
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE_STEP_END;
|
|
3394
|
+
}
|
|
3395
|
+
getRequireRefreshZones() {
|
|
3396
|
+
return [
|
|
3397
|
+
{ player: 0, location: OcgcoreScriptConstants.LOCATION_MZONE },
|
|
3398
|
+
{ player: 1, location: OcgcoreScriptConstants.LOCATION_MZONE }
|
|
3399
|
+
];
|
|
3400
|
+
}
|
|
3401
|
+
};
|
|
3402
|
+
|
|
3403
|
+
// src/protos/msg/proto/damage-step-start.ts
|
|
3404
|
+
var YGOProMsgDamageStepStart = class extends YGOProMsgBase {
|
|
3405
|
+
static {
|
|
3406
|
+
__name(this, "YGOProMsgDamageStepStart");
|
|
3407
|
+
}
|
|
3408
|
+
static {
|
|
3409
|
+
this.identifier = OcgcoreCommonConstants.MSG_DAMAGE_STEP_START;
|
|
3410
|
+
}
|
|
3411
|
+
getRequireRefreshZones() {
|
|
3412
|
+
return [
|
|
3413
|
+
{ player: 0, location: OcgcoreScriptConstants.LOCATION_MZONE },
|
|
3414
|
+
{ player: 1, location: OcgcoreScriptConstants.LOCATION_MZONE }
|
|
3415
|
+
];
|
|
3416
|
+
}
|
|
3417
|
+
};
|
|
3418
|
+
|
|
3419
|
+
// src/protos/msg/proto/deck-top.ts
|
|
3420
|
+
var YGOProMsgDeckTop = class extends YGOProMsgBase {
|
|
3421
|
+
static {
|
|
3422
|
+
__name(this, "YGOProMsgDeckTop");
|
|
3423
|
+
}
|
|
3424
|
+
static {
|
|
3425
|
+
this.identifier = OcgcoreCommonConstants.MSG_DECK_TOP;
|
|
3426
|
+
}
|
|
3427
|
+
// 对方视角可能需要隐藏卡片信息
|
|
3428
|
+
opponentView() {
|
|
3429
|
+
const view = this.copy();
|
|
3430
|
+
if (!(view.code & 2147483648)) {
|
|
3431
|
+
view.code = 0;
|
|
3432
|
+
}
|
|
3433
|
+
return view;
|
|
3434
|
+
}
|
|
3435
|
+
// deck-top 使用基类的 playerView (基于 player 字段)
|
|
3436
|
+
};
|
|
3437
|
+
__decorateClass([
|
|
3438
|
+
BinaryField("u8", 0)
|
|
3439
|
+
], YGOProMsgDeckTop.prototype, "player", 2);
|
|
3440
|
+
__decorateClass([
|
|
3441
|
+
BinaryField("u8", 1)
|
|
3442
|
+
], YGOProMsgDeckTop.prototype, "sequence", 2);
|
|
3443
|
+
__decorateClass([
|
|
3444
|
+
BinaryField("i32", 2)
|
|
3445
|
+
], YGOProMsgDeckTop.prototype, "code", 2);
|
|
3446
|
+
|
|
3447
|
+
// src/protos/msg/proto/draw.ts
|
|
3448
|
+
var YGOProMsgDraw = class extends YGOProMsgBase {
|
|
3449
|
+
static {
|
|
3450
|
+
__name(this, "YGOProMsgDraw");
|
|
3451
|
+
}
|
|
3452
|
+
static {
|
|
3453
|
+
this.identifier = OcgcoreCommonConstants.MSG_DRAW;
|
|
3454
|
+
}
|
|
3455
|
+
// 对方视角需要隐藏抽到的卡(如果卡片标志位 0x80 未设置)
|
|
3456
|
+
opponentView() {
|
|
3457
|
+
const view = this.copy();
|
|
3458
|
+
view.cards = view.cards.map((card) => {
|
|
3459
|
+
if (!(card & 2147483648)) {
|
|
3460
|
+
return 0;
|
|
3461
|
+
}
|
|
3462
|
+
return card;
|
|
3463
|
+
});
|
|
3464
|
+
return view;
|
|
3465
|
+
}
|
|
3466
|
+
};
|
|
3467
|
+
__decorateClass([
|
|
3468
|
+
BinaryField("u8", 0)
|
|
3469
|
+
], YGOProMsgDraw.prototype, "player", 2);
|
|
3470
|
+
__decorateClass([
|
|
3471
|
+
BinaryField("u8", 1)
|
|
3472
|
+
], YGOProMsgDraw.prototype, "count", 2);
|
|
3473
|
+
__decorateClass([
|
|
3474
|
+
BinaryField("i32", 2, (obj) => obj.count)
|
|
3475
|
+
], YGOProMsgDraw.prototype, "cards", 2);
|
|
3476
|
+
|
|
3477
|
+
// src/protos/msg/proto/equip.ts
|
|
3478
|
+
var YGOProMsgEquip_CardLocation = class {
|
|
3479
|
+
static {
|
|
3480
|
+
__name(this, "YGOProMsgEquip_CardLocation");
|
|
3481
|
+
}
|
|
3482
|
+
};
|
|
3483
|
+
__decorateClass([
|
|
3484
|
+
BinaryField("u8", 0)
|
|
3485
|
+
], YGOProMsgEquip_CardLocation.prototype, "controller", 2);
|
|
3486
|
+
__decorateClass([
|
|
3487
|
+
BinaryField("u8", 1)
|
|
3488
|
+
], YGOProMsgEquip_CardLocation.prototype, "location", 2);
|
|
3489
|
+
__decorateClass([
|
|
3490
|
+
BinaryField("u8", 2)
|
|
3491
|
+
], YGOProMsgEquip_CardLocation.prototype, "sequence", 2);
|
|
3492
|
+
var YGOProMsgEquip = class extends YGOProMsgBase {
|
|
3493
|
+
static {
|
|
3494
|
+
__name(this, "YGOProMsgEquip");
|
|
3495
|
+
}
|
|
3496
|
+
static {
|
|
3497
|
+
this.identifier = OcgcoreCommonConstants.MSG_EQUIP;
|
|
3498
|
+
}
|
|
3499
|
+
};
|
|
3500
|
+
__decorateClass([
|
|
3501
|
+
BinaryField(() => YGOProMsgEquip_CardLocation, 0)
|
|
3502
|
+
], YGOProMsgEquip.prototype, "equip", 2);
|
|
3503
|
+
__decorateClass([
|
|
3504
|
+
BinaryField(() => YGOProMsgEquip_CardLocation, 3)
|
|
3505
|
+
], YGOProMsgEquip.prototype, "target", 2);
|
|
3506
|
+
__decorateClass([
|
|
3507
|
+
BinaryField("u8", 6)
|
|
3508
|
+
], YGOProMsgEquip.prototype, "position", 2);
|
|
3509
|
+
|
|
3510
|
+
// src/protos/msg/proto/field-disabled.ts
|
|
3511
|
+
var YGOProMsgFieldDisabled = class extends YGOProMsgBase {
|
|
3512
|
+
static {
|
|
3513
|
+
__name(this, "YGOProMsgFieldDisabled");
|
|
3514
|
+
}
|
|
3515
|
+
static {
|
|
3516
|
+
this.identifier = OcgcoreCommonConstants.MSG_FIELD_DISABLED;
|
|
3517
|
+
}
|
|
3518
|
+
};
|
|
3519
|
+
__decorateClass([
|
|
3520
|
+
BinaryField("u32", 0)
|
|
3521
|
+
], YGOProMsgFieldDisabled.prototype, "disabledField", 2);
|
|
3522
|
+
|
|
3523
|
+
// src/protos/msg/proto/flipsummoned.ts
|
|
3524
|
+
var YGOProMsgFlipSummoned = class extends YGOProMsgBase {
|
|
3525
|
+
static {
|
|
3526
|
+
__name(this, "YGOProMsgFlipSummoned");
|
|
3527
|
+
}
|
|
3528
|
+
static {
|
|
3529
|
+
this.identifier = OcgcoreCommonConstants.MSG_FLIPSUMMONED;
|
|
3530
|
+
}
|
|
3531
|
+
getRequireRefreshZones() {
|
|
3532
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE;
|
|
3533
|
+
return [
|
|
3534
|
+
{ player: 0, location },
|
|
3535
|
+
{ player: 1, location }
|
|
3536
|
+
];
|
|
3537
|
+
}
|
|
3538
|
+
};
|
|
3539
|
+
|
|
3540
|
+
// src/protos/msg/proto/flipsummoning.ts
|
|
3541
|
+
var YGOProMsgFlipSummoning = class extends YGOProMsgBase {
|
|
3542
|
+
static {
|
|
3543
|
+
__name(this, "YGOProMsgFlipSummoning");
|
|
3544
|
+
}
|
|
3545
|
+
static {
|
|
3546
|
+
this.identifier = OcgcoreCommonConstants.MSG_FLIPSUMMONING;
|
|
3547
|
+
}
|
|
3548
|
+
getRequireRefreshCards() {
|
|
3549
|
+
return [
|
|
3550
|
+
{
|
|
3551
|
+
player: this.controller,
|
|
3552
|
+
location: this.location,
|
|
3553
|
+
sequence: this.sequence
|
|
3554
|
+
}
|
|
3555
|
+
];
|
|
3556
|
+
}
|
|
3557
|
+
};
|
|
3558
|
+
__decorateClass([
|
|
3559
|
+
BinaryField("i32", 0)
|
|
3560
|
+
], YGOProMsgFlipSummoning.prototype, "code", 2);
|
|
3561
|
+
__decorateClass([
|
|
3562
|
+
BinaryField("u8", 4)
|
|
3563
|
+
], YGOProMsgFlipSummoning.prototype, "controller", 2);
|
|
3564
|
+
__decorateClass([
|
|
3565
|
+
BinaryField("u8", 5)
|
|
3566
|
+
], YGOProMsgFlipSummoning.prototype, "location", 2);
|
|
3567
|
+
__decorateClass([
|
|
3568
|
+
BinaryField("u8", 6)
|
|
3569
|
+
], YGOProMsgFlipSummoning.prototype, "sequence", 2);
|
|
3570
|
+
__decorateClass([
|
|
3571
|
+
BinaryField("u8", 7)
|
|
3572
|
+
], YGOProMsgFlipSummoning.prototype, "position", 2);
|
|
3573
|
+
|
|
3574
|
+
// src/protos/msg/proto/hand-res.ts
|
|
3575
|
+
var YGOProMsgHandRes = class extends YGOProMsgBase {
|
|
3576
|
+
static {
|
|
3577
|
+
__name(this, "YGOProMsgHandRes");
|
|
3578
|
+
}
|
|
3579
|
+
static {
|
|
3580
|
+
this.identifier = OcgcoreCommonConstants.MSG_HAND_RES;
|
|
3581
|
+
}
|
|
3582
|
+
};
|
|
3583
|
+
__decorateClass([
|
|
3584
|
+
BinaryField("u8", 0)
|
|
3585
|
+
], YGOProMsgHandRes.prototype, "result", 2);
|
|
3586
|
+
|
|
3587
|
+
// src/protos/msg/proto/hint.ts
|
|
3588
|
+
var HINT_TYPES_SEND_TO_SELF = /* @__PURE__ */ new Set([1, 2, 3, 5]);
|
|
3589
|
+
var HINT_TYPES_SEND_TO_OPPONENT = /* @__PURE__ */ new Set([4, 6, 7, 8, 9, 11]);
|
|
3590
|
+
var YGOProMsgHint = class extends YGOProMsgBase {
|
|
3591
|
+
static {
|
|
3592
|
+
__name(this, "YGOProMsgHint");
|
|
3593
|
+
}
|
|
3594
|
+
static {
|
|
3595
|
+
this.identifier = OcgcoreCommonConstants.MSG_HINT;
|
|
3596
|
+
}
|
|
3597
|
+
getSendTargets() {
|
|
3598
|
+
if (HINT_TYPES_SEND_TO_SELF.has(this.type)) {
|
|
3599
|
+
return [this.player];
|
|
3600
|
+
}
|
|
3601
|
+
if (HINT_TYPES_SEND_TO_OPPONENT.has(this.type)) {
|
|
3602
|
+
return [1 - this.player, 7 /* OBSERVER */];
|
|
3603
|
+
}
|
|
3604
|
+
return SEND_TO_ALL;
|
|
3605
|
+
}
|
|
3606
|
+
};
|
|
3607
|
+
__decorateClass([
|
|
3608
|
+
BinaryField("u8", 0)
|
|
3609
|
+
], YGOProMsgHint.prototype, "type", 2);
|
|
3610
|
+
__decorateClass([
|
|
3611
|
+
BinaryField("u8", 1)
|
|
3612
|
+
], YGOProMsgHint.prototype, "player", 2);
|
|
3613
|
+
__decorateClass([
|
|
3614
|
+
BinaryField("i32", 2)
|
|
3615
|
+
], YGOProMsgHint.prototype, "desc", 2);
|
|
3616
|
+
|
|
3617
|
+
// src/protos/msg/proto/lpupdate.ts
|
|
3618
|
+
var YGOProMsgLpUpdate = class extends YGOProMsgBase {
|
|
3619
|
+
static {
|
|
3620
|
+
__name(this, "YGOProMsgLpUpdate");
|
|
3621
|
+
}
|
|
3622
|
+
static {
|
|
3623
|
+
this.identifier = OcgcoreCommonConstants.MSG_LPUPDATE;
|
|
3624
|
+
}
|
|
3625
|
+
};
|
|
3626
|
+
__decorateClass([
|
|
3627
|
+
BinaryField("u8", 0)
|
|
3628
|
+
], YGOProMsgLpUpdate.prototype, "player", 2);
|
|
3629
|
+
__decorateClass([
|
|
3630
|
+
BinaryField("i32", 1)
|
|
3631
|
+
], YGOProMsgLpUpdate.prototype, "lp", 2);
|
|
3632
|
+
|
|
3633
|
+
// src/protos/msg/proto/match-kill.ts
|
|
3634
|
+
var YGOProMsgMatchKill = class extends YGOProMsgBase {
|
|
3635
|
+
static {
|
|
3636
|
+
__name(this, "YGOProMsgMatchKill");
|
|
3637
|
+
}
|
|
3638
|
+
static {
|
|
3639
|
+
this.identifier = OcgcoreCommonConstants.MSG_MATCH_KILL;
|
|
3640
|
+
}
|
|
3641
|
+
};
|
|
3642
|
+
__decorateClass([
|
|
3643
|
+
BinaryField("i32", 0)
|
|
3644
|
+
], YGOProMsgMatchKill.prototype, "code", 2);
|
|
3645
|
+
|
|
3646
|
+
// src/protos/msg/proto/missed-effect.ts
|
|
3647
|
+
var YGOProMsgMissedEffect = class extends YGOProMsgBase {
|
|
3648
|
+
static {
|
|
3649
|
+
__name(this, "YGOProMsgMissedEffect");
|
|
3650
|
+
}
|
|
3651
|
+
static {
|
|
3652
|
+
this.identifier = OcgcoreCommonConstants.MSG_MISSED_EFFECT;
|
|
3653
|
+
}
|
|
3654
|
+
getSendTargets() {
|
|
3655
|
+
return [this.controller];
|
|
3656
|
+
}
|
|
3657
|
+
};
|
|
3658
|
+
__decorateClass([
|
|
3659
|
+
BinaryField("u8", 0)
|
|
3660
|
+
], YGOProMsgMissedEffect.prototype, "controller", 2);
|
|
3661
|
+
__decorateClass([
|
|
3662
|
+
BinaryField("u8", 1)
|
|
3663
|
+
], YGOProMsgMissedEffect.prototype, "location", 2);
|
|
3664
|
+
__decorateClass([
|
|
3665
|
+
BinaryField("u8", 2)
|
|
3666
|
+
], YGOProMsgMissedEffect.prototype, "sequence", 2);
|
|
3667
|
+
__decorateClass([
|
|
3668
|
+
BinaryField("u8", 3)
|
|
3669
|
+
], YGOProMsgMissedEffect.prototype, "position", 2);
|
|
3670
|
+
__decorateClass([
|
|
3671
|
+
BinaryField("i32", 4)
|
|
3672
|
+
], YGOProMsgMissedEffect.prototype, "code", 2);
|
|
3673
|
+
|
|
3622
3674
|
// src/protos/msg/proto/move.ts
|
|
3623
3675
|
var YGOProMsgMove_CardLocation = class {
|
|
3624
3676
|
static {
|
|
@@ -3677,6 +3729,21 @@ var YGOProMsgMove = class extends YGOProMsgBase {
|
|
|
3677
3729
|
}
|
|
3678
3730
|
return this.opponentView();
|
|
3679
3731
|
}
|
|
3732
|
+
getRequireRefreshCards() {
|
|
3733
|
+
const current = this.current;
|
|
3734
|
+
const previous = this.previous;
|
|
3735
|
+
const shouldRefresh = current.location !== 0 && (current.location & OcgcoreScriptConstants.LOCATION_OVERLAY) === 0 && (current.location !== previous.location || current.controller !== previous.controller);
|
|
3736
|
+
if (!shouldRefresh) {
|
|
3737
|
+
return [];
|
|
3738
|
+
}
|
|
3739
|
+
return [
|
|
3740
|
+
{
|
|
3741
|
+
player: current.controller,
|
|
3742
|
+
location: current.location,
|
|
3743
|
+
sequence: current.sequence
|
|
3744
|
+
}
|
|
3745
|
+
];
|
|
3746
|
+
}
|
|
3680
3747
|
};
|
|
3681
3748
|
__decorateClass([
|
|
3682
3749
|
BinaryField("i32", 0)
|
|
@@ -3699,6 +3766,13 @@ var YGOProMsgNewPhase = class extends YGOProMsgBase {
|
|
|
3699
3766
|
static {
|
|
3700
3767
|
this.identifier = OcgcoreCommonConstants.MSG_NEW_PHASE;
|
|
3701
3768
|
}
|
|
3769
|
+
getRequireRefreshZones() {
|
|
3770
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
3771
|
+
return [
|
|
3772
|
+
{ player: 0, location },
|
|
3773
|
+
{ player: 1, location }
|
|
3774
|
+
];
|
|
3775
|
+
}
|
|
3702
3776
|
};
|
|
3703
3777
|
__decorateClass([
|
|
3704
3778
|
BinaryField("u16", 0)
|
|
@@ -3712,6 +3786,13 @@ var YGOProMsgNewTurn = class extends YGOProMsgBase {
|
|
|
3712
3786
|
static {
|
|
3713
3787
|
this.identifier = OcgcoreCommonConstants.MSG_NEW_TURN;
|
|
3714
3788
|
}
|
|
3789
|
+
getRequireRefreshZones() {
|
|
3790
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
3791
|
+
return [
|
|
3792
|
+
{ player: 0, location },
|
|
3793
|
+
{ player: 1, location }
|
|
3794
|
+
];
|
|
3795
|
+
}
|
|
3715
3796
|
};
|
|
3716
3797
|
__decorateClass([
|
|
3717
3798
|
BinaryField("u8", 0)
|
|
@@ -3774,6 +3855,19 @@ var YGOProMsgPosChange = class extends YGOProMsgBase {
|
|
|
3774
3855
|
static {
|
|
3775
3856
|
this.identifier = OcgcoreCommonConstants.MSG_POS_CHANGE;
|
|
3776
3857
|
}
|
|
3858
|
+
getRequireRefreshCards() {
|
|
3859
|
+
const shouldRefresh = (this.previousPosition & OcgcoreCommonConstants.POS_FACEDOWN) !== 0 && (this.currentPosition & OcgcoreCommonConstants.POS_FACEUP) !== 0;
|
|
3860
|
+
if (!shouldRefresh) {
|
|
3861
|
+
return [];
|
|
3862
|
+
}
|
|
3863
|
+
return [
|
|
3864
|
+
{
|
|
3865
|
+
player: this.card.controller,
|
|
3866
|
+
location: this.card.location,
|
|
3867
|
+
sequence: this.card.sequence
|
|
3868
|
+
}
|
|
3869
|
+
];
|
|
3870
|
+
}
|
|
3777
3871
|
};
|
|
3778
3872
|
__decorateClass([
|
|
3779
3873
|
BinaryField(() => YGOProMsgPosChange_CardLocation, 0)
|
|
@@ -4186,6 +4280,13 @@ var YGOProMsgSelectBattleCmd = class extends YGOProMsgResponseBase {
|
|
|
4186
4280
|
view.setUint32(0, sequence << 16 | type, true);
|
|
4187
4281
|
return buffer;
|
|
4188
4282
|
}
|
|
4283
|
+
getRequireRefreshZones() {
|
|
4284
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
4285
|
+
return [
|
|
4286
|
+
{ player: 0, location },
|
|
4287
|
+
{ player: 1, location }
|
|
4288
|
+
];
|
|
4289
|
+
}
|
|
4189
4290
|
};
|
|
4190
4291
|
__decorateClass([
|
|
4191
4292
|
BinaryField("u8", 0)
|
|
@@ -4714,6 +4815,13 @@ var YGOProMsgSelectIdleCmd = class extends YGOProMsgResponseBase {
|
|
|
4714
4815
|
view.setUint32(0, sequence << 16 | type, true);
|
|
4715
4816
|
return buffer;
|
|
4716
4817
|
}
|
|
4818
|
+
getRequireRefreshZones() {
|
|
4819
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
4820
|
+
return [
|
|
4821
|
+
{ player: 0, location },
|
|
4822
|
+
{ player: 1, location }
|
|
4823
|
+
];
|
|
4824
|
+
}
|
|
4717
4825
|
};
|
|
4718
4826
|
__decorateClass([
|
|
4719
4827
|
BinaryField("u8", 0)
|
|
@@ -5308,6 +5416,14 @@ var YGOProMsgShuffleHand = class extends YGOProMsgBase {
|
|
|
5308
5416
|
view.cards = view.cards.map(() => 0);
|
|
5309
5417
|
return view;
|
|
5310
5418
|
}
|
|
5419
|
+
getRequireRefreshZones() {
|
|
5420
|
+
return [
|
|
5421
|
+
{
|
|
5422
|
+
player: this.player,
|
|
5423
|
+
location: OcgcoreScriptConstants.LOCATION_HAND
|
|
5424
|
+
}
|
|
5425
|
+
];
|
|
5426
|
+
}
|
|
5311
5427
|
};
|
|
5312
5428
|
__decorateClass([
|
|
5313
5429
|
BinaryField("u8", 0)
|
|
@@ -5355,6 +5471,22 @@ var YGOProMsgShuffleSetCard = class extends YGOProMsgBase {
|
|
|
5355
5471
|
static {
|
|
5356
5472
|
this.identifier = OcgcoreCommonConstants.MSG_SHUFFLE_SET_CARD;
|
|
5357
5473
|
}
|
|
5474
|
+
getRequireRefreshZones() {
|
|
5475
|
+
let location = 0;
|
|
5476
|
+
if (this.location === OcgcoreScriptConstants.LOCATION_MZONE) {
|
|
5477
|
+
location = OcgcoreScriptConstants.LOCATION_MZONE;
|
|
5478
|
+
}
|
|
5479
|
+
if (this.location === OcgcoreScriptConstants.LOCATION_SZONE) {
|
|
5480
|
+
location = OcgcoreScriptConstants.LOCATION_SZONE;
|
|
5481
|
+
}
|
|
5482
|
+
if (location === 0) {
|
|
5483
|
+
return [];
|
|
5484
|
+
}
|
|
5485
|
+
return [
|
|
5486
|
+
{ player: 0, location },
|
|
5487
|
+
{ player: 1, location }
|
|
5488
|
+
];
|
|
5489
|
+
}
|
|
5358
5490
|
};
|
|
5359
5491
|
__decorateClass([
|
|
5360
5492
|
BinaryField("u8", 0)
|
|
@@ -5446,6 +5578,13 @@ var YGOProMsgSpSummoned = class extends YGOProMsgBase {
|
|
|
5446
5578
|
static {
|
|
5447
5579
|
this.identifier = OcgcoreCommonConstants.MSG_SPSUMMONED;
|
|
5448
5580
|
}
|
|
5581
|
+
getRequireRefreshZones() {
|
|
5582
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE;
|
|
5583
|
+
return [
|
|
5584
|
+
{ player: 0, location },
|
|
5585
|
+
{ player: 1, location }
|
|
5586
|
+
];
|
|
5587
|
+
}
|
|
5449
5588
|
};
|
|
5450
5589
|
|
|
5451
5590
|
// src/protos/msg/proto/spsummoning.ts
|
|
@@ -5557,6 +5696,13 @@ var YGOProMsgSummoned = class extends YGOProMsgBase {
|
|
|
5557
5696
|
static {
|
|
5558
5697
|
this.identifier = OcgcoreCommonConstants.MSG_SUMMONED;
|
|
5559
5698
|
}
|
|
5699
|
+
getRequireRefreshZones() {
|
|
5700
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE;
|
|
5701
|
+
return [
|
|
5702
|
+
{ player: 0, location },
|
|
5703
|
+
{ player: 1, location }
|
|
5704
|
+
];
|
|
5705
|
+
}
|
|
5560
5706
|
};
|
|
5561
5707
|
|
|
5562
5708
|
// src/protos/msg/proto/summoning.ts
|
|
@@ -5609,6 +5755,20 @@ var YGOProMsgSwap = class extends YGOProMsgBase {
|
|
|
5609
5755
|
static {
|
|
5610
5756
|
this.identifier = OcgcoreCommonConstants.MSG_SWAP;
|
|
5611
5757
|
}
|
|
5758
|
+
getRequireRefreshCards() {
|
|
5759
|
+
return [
|
|
5760
|
+
{
|
|
5761
|
+
player: this.card1.controller,
|
|
5762
|
+
location: this.card1.location,
|
|
5763
|
+
sequence: this.card1.sequence
|
|
5764
|
+
},
|
|
5765
|
+
{
|
|
5766
|
+
player: this.card2.controller,
|
|
5767
|
+
location: this.card2.location,
|
|
5768
|
+
sequence: this.card2.sequence
|
|
5769
|
+
}
|
|
5770
|
+
];
|
|
5771
|
+
}
|
|
5612
5772
|
};
|
|
5613
5773
|
__decorateClass([
|
|
5614
5774
|
BinaryField(() => YGOProMsgSwap_CardLocation, 0)
|
|
@@ -5653,6 +5813,13 @@ var YGOProMsgTagSwap = class extends YGOProMsgBase {
|
|
|
5653
5813
|
teammateView() {
|
|
5654
5814
|
return this.opponentView();
|
|
5655
5815
|
}
|
|
5816
|
+
getRequireRefreshZones() {
|
|
5817
|
+
const location = OcgcoreScriptConstants.LOCATION_MZONE | OcgcoreScriptConstants.LOCATION_SZONE | OcgcoreScriptConstants.LOCATION_HAND;
|
|
5818
|
+
return [
|
|
5819
|
+
{ player: 0, location },
|
|
5820
|
+
{ player: 1, location }
|
|
5821
|
+
];
|
|
5822
|
+
}
|
|
5656
5823
|
};
|
|
5657
5824
|
__decorateClass([
|
|
5658
5825
|
BinaryField("u8", 0)
|
|
@@ -5799,6 +5966,15 @@ var YGOProMsgUpdateCard = class extends YGOProMsgBase {
|
|
|
5799
5966
|
getSendTargets() {
|
|
5800
5967
|
return [];
|
|
5801
5968
|
}
|
|
5969
|
+
getRequireRefreshCards() {
|
|
5970
|
+
return [
|
|
5971
|
+
{
|
|
5972
|
+
player: this.controller,
|
|
5973
|
+
location: this.location,
|
|
5974
|
+
sequence: this.sequence
|
|
5975
|
+
}
|
|
5976
|
+
];
|
|
5977
|
+
}
|
|
5802
5978
|
};
|
|
5803
5979
|
|
|
5804
5980
|
// src/protos/msg/proto/update-data.ts
|