fleethub-core 1.6.2 → 1.7.2

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.
@@ -3,46 +3,6 @@
3
3
  /**
4
4
  */
5
5
  export function set_panic_hook(): void;
6
- export interface EBonuses {
7
- firepower: number;
8
- torpedo: number;
9
- anti_air: number;
10
- armor: number;
11
- evasion: number;
12
- asw: number;
13
- los: number;
14
- bombing: number;
15
- accuracy: number;
16
- range: number;
17
- }
18
-
19
- export interface ShipInput {
20
- ship_id: number;
21
- ctype: number;
22
- stype: number;
23
- yomi: string;
24
- }
25
-
26
- export interface GearInput {
27
- gear_id: number;
28
- types: GearTypeIdArray;
29
- firepower: number;
30
- torpedo: number;
31
- anti_air: number;
32
- armor: number;
33
- evasion: number;
34
- asw: number;
35
- los: number;
36
- bombing: number;
37
- accuracy: number;
38
- range: number;
39
- radius: number;
40
- stars: number;
41
- ace: number;
42
- }
43
-
44
- export type GearVecInput = GearInput[];
45
-
46
6
  export type ShipType =
47
7
  | "Unknown"
48
8
  | "DE"
@@ -78,46 +38,50 @@ export type ShipCategory =
78
38
  | "Submarine"
79
39
  | "AuxiliaryShip";
80
40
 
81
- export type AirStateRank = "Rank0" | "Rank1" | "Rank2" | "Rank3";
41
+ export type ShellingSpecialAttack =
42
+ | { DayCutin: DayCutin }
43
+ | { FleetCutin: FleetCutin };
82
44
 
83
- export type AirState =
84
- | "AirSupremacy"
85
- | "AirSuperiority"
86
- | "AirParity"
87
- | "AirDenial"
88
- | "AirIncapability";
45
+ export type DayCutin =
46
+ | "MainMain"
47
+ | "MainAp"
48
+ | "MainRadar"
49
+ | "MainSec"
50
+ | "DoubleAttack"
51
+ | "FBA"
52
+ | "BBA"
53
+ | "BA"
54
+ | "Zuiun"
55
+ | "AirSea";
89
56
 
90
- export interface FleetCutinAnalysis {
91
- shelling: FleetCutinInfo[];
92
- night: FleetCutinInfo[];
57
+ export interface ShellingSupportSimulatorParams {
58
+ attacker_formation: Formation;
59
+ target_formation: Formation;
60
+ engagement: Engagement;
61
+ custom_mods: CustomModifiers;
93
62
  }
94
63
 
95
- export interface FleetCutinInfo {
96
- cutin: FleetCutin;
97
- rate: number | null;
98
- formation: Formation;
99
- items: FleetCutinInfoItem[];
100
- }
64
+ export type ShellingAttackType = "Normal" | "Carrier";
101
65
 
102
- export interface FleetCutinInfoItem {
103
- ship_id: number;
104
- cutin: FleetCutin;
105
- fleet_cutin_mod: number;
106
- stats: AttackStats;
107
- }
66
+ export type AirWaveType = "Jet" | "LandBase" | "Carrier";
108
67
 
109
- export interface DamageInfo {
110
- miss_damage_min: number;
111
- miss_damage_max: number;
112
- normal_damage_min: number;
113
- normal_damage_max: number;
114
- critical_damage_min: number;
115
- critical_damage_max: number;
116
- normal_scratch_rate: number;
117
- critical_scratch_rate: number;
118
- damage_map: NumMap<number, number>;
119
- damage_state_map: NumMap<DamageState, number>;
120
- }
68
+ export type AswAttackType = "DepthCharge" | "Aircraft";
69
+
70
+ export type OrgType =
71
+ | "Single"
72
+ | "CarrierTaskForce"
73
+ | "SurfaceTaskForce"
74
+ | "TransportEscort"
75
+ | "EnemySingle"
76
+ | "EnemyCombined";
77
+
78
+ export type FleetCutin =
79
+ | "NelsonTouch"
80
+ | "NagatoCutin"
81
+ | "ColoradoCutin"
82
+ | "KongouCutin"
83
+ | "Yamato2ShipCutin"
84
+ | "Yamato3ShipCutin";
121
85
 
122
86
  export interface WarfareContext {
123
87
  attacker_env: WarfareShipEnvironment;
@@ -136,6 +100,23 @@ export interface WarfareShipEnvironment {
136
100
  fleet_los_mod: number | null;
137
101
  }
138
102
 
103
+ export type Role = "Main" | "Escort";
104
+
105
+ export interface CompMeta {
106
+ fleets: Record<FleetType, FleetMeta>;
107
+ }
108
+
109
+ export interface FleetMeta {
110
+ id: string;
111
+ len: number;
112
+ ships: [string, ShipMeta | null][];
113
+ }
114
+
115
+ export interface ShipMeta {
116
+ id: string;
117
+ ship_id: number;
118
+ }
119
+
139
120
  export interface AttackPower {
140
121
  precap: number;
141
122
  is_capped: boolean;
@@ -182,29 +163,6 @@ export interface AttackPowerModifier {
182
163
  b: number;
183
164
  }
184
165
 
185
- export type OrgType =
186
- | "Single"
187
- | "CarrierTaskForce"
188
- | "SurfaceTaskForce"
189
- | "TransportEscort"
190
- | "EnemySingle"
191
- | "EnemyCombined";
192
-
193
- export interface CompMeta {
194
- fleets: Record<FleetType, FleetMeta>;
195
- }
196
-
197
- export interface FleetMeta {
198
- id: string;
199
- len: number;
200
- ships: [string, ShipMeta | null][];
201
- }
202
-
203
- export interface ShipMeta {
204
- id: string;
205
- ship_id: number;
206
- }
207
-
208
166
  export interface MasterData {
209
167
  gears: MasterGear[];
210
168
  gear_attrs: MasterAttrRule<GearAttr>[];
@@ -231,25 +189,29 @@ export interface MasterAttrRule<T> {
231
189
  expr: string;
232
190
  }
233
191
 
234
- export type NumMap<K, V> = Partial<Record<K, V>>;
192
+ export interface CompDayCutinRateInfo {
193
+ main: FleetDayCutinRateInfo;
194
+ escort: FleetDayCutinRateInfo | null;
195
+ }
235
196
 
236
- export type ShellingSpecialAttack =
237
- | { DayCutin: DayCutin }
238
- | { FleetCutin: FleetCutin };
197
+ export interface FleetDayCutinRateInfo {
198
+ fleet_los_mod: number | null;
199
+ ships: ShipDayCutinRateInfo[];
200
+ }
239
201
 
240
- export type DayCutin =
241
- | "MainMain"
242
- | "MainAp"
243
- | "MainRadar"
244
- | "MainSec"
245
- | "DoubleAttack"
246
- | "FBA"
247
- | "BBA"
248
- | "BA"
249
- | "Zuiun"
250
- | "AirSea";
202
+ export interface ShipDayCutinRateInfo {
203
+ ship_id: number;
204
+ air_supremacy: DayCutinRateInfo;
205
+ air_superiority: DayCutinRateInfo;
206
+ }
251
207
 
252
- export type Role = "Main" | "Escort";
208
+ export interface DayCutinRateInfo {
209
+ observation_term: number | null;
210
+ rates: [DayCutin | null, number | null][];
211
+ total_cutin_rate: number | null;
212
+ }
213
+
214
+ export type NumMap<K, V> = Partial<Record<K, V>>;
253
215
 
254
216
  export type GearCategory =
255
217
  | "Fighter"
@@ -328,52 +290,54 @@ export type GearType =
328
290
 
329
291
  export type Engagement = "GreenT" | "Parallel" | "HeadOn" | "RedT";
330
292
 
331
- export interface ShellingSupportSimulatorParams {
332
- attacker_formation: Formation;
333
- target_formation: Formation;
334
- engagement: Engagement;
335
- custom_mods: CustomModifiers;
293
+ export interface EBonuses {
294
+ firepower: number;
295
+ torpedo: number;
296
+ anti_air: number;
297
+ armor: number;
298
+ evasion: number;
299
+ asw: number;
300
+ los: number;
301
+ bombing: number;
302
+ accuracy: number;
303
+ range: number;
336
304
  }
337
305
 
338
- export type ShellingAttackType = "Normal" | "Carrier";
339
-
340
- export interface CompDayCutinRateInfo {
341
- main: FleetDayCutinRateInfo;
342
- escort: FleetDayCutinRateInfo | null;
306
+ export interface ShipInput {
307
+ ship_id: number;
308
+ ctype: number;
309
+ stype: number;
310
+ yomi: string;
343
311
  }
344
312
 
345
- export interface FleetDayCutinRateInfo {
346
- fleet_los_mod: number | null;
347
- ships: ShipDayCutinRateInfo[];
313
+ export interface GearInput {
314
+ gear_id: number;
315
+ types: GearTypeIdArray;
316
+ firepower: number;
317
+ torpedo: number;
318
+ anti_air: number;
319
+ armor: number;
320
+ evasion: number;
321
+ asw: number;
322
+ los: number;
323
+ bombing: number;
324
+ accuracy: number;
325
+ range: number;
326
+ radius: number;
327
+ stars: number;
328
+ ace: number;
348
329
  }
349
330
 
350
- export interface ShipDayCutinRateInfo {
351
- ship_id: number;
352
- air_supremacy: DayCutinRateInfo;
353
- air_superiority: DayCutinRateInfo;
354
- }
331
+ export type GearVecInput = GearInput[];
355
332
 
356
- export interface DayCutinRateInfo {
357
- observation_term: number | null;
358
- rates: [DayCutin | null, number | null][];
359
- total_cutin_rate: number | null;
360
- }
333
+ export type AirStateRank = "Rank0" | "Rank1" | "Rank2" | "Rank3";
361
334
 
362
- export type ShipAttr =
363
- | "Unknown"
364
- | "Abyssal"
365
- | "NightCarrier"
366
- | "Installation"
367
- | "RoyalNavy"
368
- | "Kai2"
369
- | "TurbineSpeedBonus"
370
- | "Pillbox"
371
- | "IsolatedIsland"
372
- | "HarbourSummerPrincess"
373
- | "SupplyDepot"
374
- | "PtImp"
375
- | "BattleshipSummerPrincess"
376
- | "HeavyCruiserSummerPrincess";
335
+ export type AirState =
336
+ | "AirSupremacy"
337
+ | "AirSuperiority"
338
+ | "AirParity"
339
+ | "AirDenial"
340
+ | "AirIncapability";
377
341
 
378
342
  export interface MasterIBonuses {
379
343
  shelling_power: MasterIBonusRule[];
@@ -405,6 +369,104 @@ export interface NightSituation {
405
369
  searchlight: boolean;
406
370
  }
407
371
 
372
+ export interface FleetCutinAnalysis {
373
+ shelling: FleetCutinInfo[];
374
+ night: FleetCutinInfo[];
375
+ }
376
+
377
+ export interface FleetCutinInfo {
378
+ cutin: FleetCutin;
379
+ rate: number | null;
380
+ formation: Formation;
381
+ items: FleetCutinInfoItem[];
382
+ }
383
+
384
+ export interface FleetCutinInfoItem {
385
+ ship_id: number;
386
+ cutin: FleetCutin;
387
+ fleet_cutin_mod: number;
388
+ stats: AttackStats;
389
+ }
390
+
391
+ export interface DamageInfo {
392
+ miss_damage_min: number;
393
+ miss_damage_max: number;
394
+ normal_damage_min: number;
395
+ normal_damage_max: number;
396
+ critical_damage_min: number;
397
+ critical_damage_max: number;
398
+ normal_scratch_rate: number;
399
+ critical_scratch_rate: number;
400
+ damage_map: NumMap<number, number>;
401
+ damage_state_map: NumMap<DamageState, number>;
402
+ }
403
+
404
+ export type ShipAttr =
405
+ | "Unknown"
406
+ | "Abyssal"
407
+ | "NightCarrier"
408
+ | "Installation"
409
+ | "RoyalNavy"
410
+ | "Kai2"
411
+ | "TurbineSpeedBonus"
412
+ | "Pillbox"
413
+ | "IsolatedIsland"
414
+ | "HarbourSummerPrincess"
415
+ | "SupplyDepot"
416
+ | "PtImp"
417
+ | "BattleshipSummerPrincess"
418
+ | "HeavyCruiserSummerPrincess";
419
+
420
+ export type Formation = SingleFormation | CombinedFormation;
421
+
422
+ export type CombinedFormation =
423
+ | "Cruising1"
424
+ | "Cruising2"
425
+ | "Cruising3"
426
+ | "Cruising4";
427
+
428
+ export type SingleFormation =
429
+ | "LineAhead"
430
+ | "DoubleLine"
431
+ | "Diamond"
432
+ | "Echelon"
433
+ | "LineAbreast"
434
+ | "Vanguard";
435
+
436
+ export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
437
+
438
+ export interface CompAntiAirInfo {
439
+ fleet_adjusted_anti_air: number;
440
+ ships: ShipAntiAirInfo[];
441
+ anti_air_cutin_chance: [number, number][];
442
+ }
443
+
444
+ export interface ShipAntiAirInfo {
445
+ ship_id: number;
446
+ adjusted_anti_air: number | null;
447
+ proportional_shotdown_rate: number | null;
448
+ fixed_shotdown_number: number | null;
449
+ guaranteed: number | null;
450
+ anti_air_cutin_chance: [number, number][];
451
+ anti_air_propellant_barrage_chance: number | null;
452
+ }
453
+
454
+ export interface CompContactChanceInfo {
455
+ single: AirstrikeContactChance[] | null;
456
+ combined: AirstrikeContactChance[] | null;
457
+ }
458
+
459
+ export interface AirstrikeContactChance {
460
+ air_state: AirState;
461
+ trigger_rate: number;
462
+ rank3: number;
463
+ rank2: number;
464
+ rank1: number;
465
+ total: number;
466
+ }
467
+
468
+ export type SlotSizeVec = (number | null)[];
469
+
408
470
  export type GearAttr =
409
471
  | "Unknown"
410
472
  | "Abyssal"
@@ -436,23 +498,75 @@ export type GearAttr =
436
498
  | "SemiNightPlane"
437
499
  | "HighAltitudeInterceptor";
438
500
 
439
- export type Formation = SingleFormation | CombinedFormation;
501
+ export interface MasterGear {
502
+ gear_id: number;
503
+ name: string;
504
+ types: GearTypeIdArray;
505
+ special_type?: number;
506
+ max_hp?: number;
507
+ firepower?: number;
508
+ armor?: number;
509
+ torpedo?: number;
510
+ anti_air?: number;
511
+ speed?: number;
512
+ bombing?: number;
513
+ asw?: number;
514
+ los?: number;
515
+ luck?: number;
516
+ accuracy?: number;
517
+ evasion?: number;
518
+ range?: number;
519
+ radius?: number;
520
+ cost?: number;
521
+ improvable?: boolean;
522
+ ship_anti_air_resistance?: number;
523
+ fleet_anti_air_resistance?: number;
524
+ }
525
+
526
+ export interface MasterEquippable {
527
+ equip_stype: EquipStype[];
528
+ equip_exslot: number[];
529
+ equip_ship: MstEquipShip[];
530
+ equip_exslot_ship: MstEquipExslotShip[];
531
+ }
532
+
533
+ export interface MstEquipExslotShip {
534
+ api_slotitem_id: number;
535
+ api_ship_ids: number[];
536
+ }
537
+
538
+ export interface MstEquipShip {
539
+ api_ship_id: number;
540
+ api_equip_type: number[];
541
+ }
542
+
543
+ export interface EquipStype {
544
+ id: number;
545
+ equip_type: number[];
546
+ }
547
+
548
+ export interface HitRate {
549
+ total: number;
550
+ normal: number;
551
+ critical: number;
552
+ }
440
553
 
441
- export type CombinedFormation =
442
- | "Cruising1"
443
- | "Cruising2"
444
- | "Cruising3"
445
- | "Cruising4";
554
+ export interface HitRateParams {
555
+ accuracy_term: number;
556
+ evasion_term: number;
557
+ target_morale_mod: number;
558
+ critical_rate_constant: number;
559
+ critical_percentage_bonus: number;
560
+ hit_percentage_bonus: number;
561
+ }
446
562
 
447
- export type SingleFormation =
448
- | "LineAhead"
449
- | "DoubleLine"
450
- | "Diamond"
451
- | "Echelon"
452
- | "LineAbreast"
453
- | "Vanguard";
563
+ export type NightBattleAttackType =
564
+ | { t: "NightAttack"; c: NightAttackType }
565
+ | { t: "Asw"; c: AswAttackType };
454
566
 
455
- export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
567
+ export type DayBattleAttackType =
568
+ | { t: "Shelling"; c: ShellingAttackType }
569
+ | { t: "Asw"; c: AswAttackType };
456
570
 
457
571
  export interface AttackInfo<AttackType, Cutin> {
458
572
  attack_type: AttackType;
@@ -475,36 +589,6 @@ export interface AttackStats {
475
589
  damage: DamageInfo | null;
476
590
  }
477
591
 
478
- export interface CompAntiAirInfo {
479
- fleet_adjusted_anti_air: number;
480
- ships: ShipAntiAirInfo[];
481
- anti_air_cutin_chance: [number, number][];
482
- }
483
-
484
- export interface ShipAntiAirInfo {
485
- ship_id: number;
486
- adjusted_anti_air: number | null;
487
- proportional_shotdown_rate: number | null;
488
- fixed_shotdown_number: number | null;
489
- guaranteed: number | null;
490
- anti_air_cutin_chance: [number, number][];
491
- anti_air_propellant_barrage_chance: number | null;
492
- }
493
-
494
- export interface CompContactChanceInfo {
495
- single: AirstrikeContactChance[] | null;
496
- combined: AirstrikeContactChance[] | null;
497
- }
498
-
499
- export interface AirstrikeContactChance {
500
- air_state: AirState;
501
- trigger_rate: number;
502
- rank3: number;
503
- rank2: number;
504
- rank1: number;
505
- total: number;
506
- }
507
-
508
592
  export type ShipStateMap = Record<ShipKey, ShipState>;
509
593
 
510
594
  export type ShipKey = "s1" | "s2" | "s3" | "s4" | "s5" | "s6" | "s7";
@@ -555,7 +639,7 @@ export interface FleetState {
555
639
  s7?: ShipState;
556
640
  }
557
641
 
558
- export interface ShipState {
642
+ export interface ShipState extends GearVecState, SlotSizeVecState {
559
643
  id?: string;
560
644
  ship_id: number;
561
645
  level?: number;
@@ -572,26 +656,23 @@ export interface ShipState {
572
656
  asw_mod?: number;
573
657
  los_mod?: number;
574
658
  luck_mod?: number;
575
- g1?: GearState;
576
- g2?: GearState;
577
- g3?: GearState;
578
- g4?: GearState;
579
- g5?: GearState;
580
- gx?: GearState;
659
+ }
660
+
661
+ export interface SlotSizeVecState {
581
662
  ss1?: number;
582
663
  ss2?: number;
583
664
  ss3?: number;
584
665
  ss4?: number;
585
666
  ss5?: number;
586
- overrides?: ShipOverrides;
587
667
  }
588
668
 
589
- export interface ShipOverrides {
590
- naked_max_hp?: number;
591
- naked_luck?: number;
592
- naked_evasion?: number;
593
- naked_asw?: number;
594
- naked_los?: number;
669
+ export interface GearVecState {
670
+ g1?: GearState;
671
+ g2?: GearState;
672
+ g3?: GearState;
673
+ g4?: GearState;
674
+ g5?: GearState;
675
+ gx?: GearState;
595
676
  }
596
677
 
597
678
  export interface GearState {
@@ -601,32 +682,6 @@ export interface GearState {
601
682
  stars?: number;
602
683
  }
603
684
 
604
- export interface MasterEquippable {
605
- equip_stype: EquipStype[];
606
- equip_exslot: number[];
607
- equip_ship: MstEquipShip[];
608
- equip_exslot_ship: MstEquipExslotShip[];
609
- }
610
-
611
- export interface MstEquipExslotShip {
612
- api_slotitem_id: number;
613
- api_ship_ids: number[];
614
- }
615
-
616
- export interface MstEquipShip {
617
- api_ship_id: number;
618
- api_equip_type: number[];
619
- }
620
-
621
- export interface EquipStype {
622
- id: number;
623
- equip_type: number[];
624
- }
625
-
626
- export type SlotSizeVec = (number | null)[];
627
-
628
- export type Side = "Player" | "Enemy";
629
-
630
685
  export type NightAttackType = "Normal" | "ArkRoyal" | "Carrier";
631
686
 
632
687
  export type NightSpecialAttack =
@@ -650,6 +705,32 @@ export type NightCutin =
650
705
  | "Cvci1_18"
651
706
  | "Photobomber";
652
707
 
708
+ export interface WarfareInfo {
709
+ day: AttackInfo<DayBattleAttackType, DayCutin | null> | null;
710
+ closing_torpedo: AttackInfo<null, null> | null;
711
+ night: AttackInfo<NightBattleAttackType, NightCutin | null> | null;
712
+ shelling_support: AttackInfo<null, null> | null;
713
+ opening_asw: AttackInfo<null, null> | null;
714
+ }
715
+
716
+ export interface WarfareAnalyzerContext {
717
+ attacker_env: WarfareAnalyzerShipEnvironment;
718
+ target_env: WarfareAnalyzerShipEnvironment;
719
+ engagement: Engagement;
720
+ air_state: AirState;
721
+ }
722
+
723
+ export interface WarfareAnalyzerShipEnvironment {
724
+ org_type: OrgType;
725
+ role: Role;
726
+ ship_index: number;
727
+ fleet_len: number;
728
+ formation: Formation;
729
+ fleet_los_mod: number | null;
730
+ night_situation: NightSituation;
731
+ custom_mods: CustomModifiers;
732
+ }
733
+
653
734
  export interface BattleConfig {
654
735
  formation: Record<Formation, NestedFormationDef>;
655
736
  anti_air_cutin: Record<number, AntiAirCutinDef>;
@@ -702,56 +783,6 @@ export interface FormationWarfareDef {
702
783
  evasion_mod: number | null;
703
784
  }
704
785
 
705
- export interface MasterGear {
706
- gear_id: number;
707
- name: string;
708
- types: GearTypeIdArray;
709
- special_type?: number;
710
- max_hp?: number;
711
- firepower?: number;
712
- armor?: number;
713
- torpedo?: number;
714
- anti_air?: number;
715
- speed?: number;
716
- bombing?: number;
717
- asw?: number;
718
- los?: number;
719
- luck?: number;
720
- accuracy?: number;
721
- evasion?: number;
722
- range?: number;
723
- radius?: number;
724
- cost?: number;
725
- improvable?: boolean;
726
- ship_anti_air_resistance?: number;
727
- fleet_anti_air_resistance?: number;
728
- }
729
-
730
- export interface HitRate {
731
- total: number;
732
- normal: number;
733
- critical: number;
734
- }
735
-
736
- export interface HitRateParams {
737
- accuracy_term: number;
738
- evasion_term: number;
739
- target_morale_mod: number;
740
- critical_rate_constant: number;
741
- critical_percentage_bonus: number;
742
- hit_percentage_bonus: number;
743
- }
744
-
745
- export type NightBattleAttackType =
746
- | { t: "NightAttack"; c: NightAttackType }
747
- | { t: "Asw"; c: AswAttackType };
748
-
749
- export type DayBattleAttackType =
750
- | { t: "Shelling"; c: ShellingAttackType }
751
- | { t: "Asw"; c: AswAttackType };
752
-
753
- export type GearTypeIdArray = [number, number, number, number, number];
754
-
755
786
  export interface MasterShip {
756
787
  ship_id: number;
757
788
  name: string;
@@ -769,6 +800,7 @@ export interface MasterShip {
769
800
  los: StatInterval;
770
801
  luck: StatInterval;
771
802
  torpedo_accuracy?: number;
803
+ basic_evasion_term?: number;
772
804
  speed: number;
773
805
  range?: number;
774
806
  fuel?: number;
@@ -784,31 +816,9 @@ export interface MasterShip {
784
816
 
785
817
  export type StatInterval = [number | null, number | null];
786
818
 
787
- export interface WarfareInfo {
788
- day: AttackInfo<DayBattleAttackType, DayCutin | null> | null;
789
- closing_torpedo: AttackInfo<null, null> | null;
790
- night: AttackInfo<NightBattleAttackType, NightCutin | null> | null;
791
- shelling_support: AttackInfo<null, null> | null;
792
- opening_asw: AttackInfo<null, null> | null;
793
- }
794
-
795
- export interface WarfareAnalyzerContext {
796
- attacker_env: WarfareAnalyzerShipEnvironment;
797
- target_env: WarfareAnalyzerShipEnvironment;
798
- engagement: Engagement;
799
- air_state: AirState;
800
- }
819
+ export type GearTypeIdArray = [number, number, number, number, number];
801
820
 
802
- export interface WarfareAnalyzerShipEnvironment {
803
- org_type: OrgType;
804
- role: Role;
805
- ship_index: number;
806
- fleet_len: number;
807
- formation: Formation;
808
- fleet_los_mod: number | null;
809
- night_situation: NightSituation;
810
- custom_mods: CustomModifiers;
811
- }
821
+ export type Side = "Player" | "Enemy";
812
822
 
813
823
  export type SpecialEnemyType =
814
824
  | "None"
@@ -827,16 +837,8 @@ export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
827
837
 
828
838
  export type SpeedGroup = "A" | "B1" | "B2" | "C";
829
839
 
830
- export type FleetCutin =
831
- | "NelsonTouch"
832
- | "NagatoCutin"
833
- | "ColoradoCutin"
834
- | "KongouCutin";
835
-
836
840
  export type ContactRank = "Rank1" | "Rank2" | "Rank3";
837
841
 
838
- export type AirWaveType = "Jet" | "LandBase" | "Carrier";
839
-
840
842
  export interface SimulatorResult {
841
843
  items: SimulatorResultItem[];
842
844
  sunk_vec: [number, number, number][];
@@ -849,8 +851,6 @@ export interface SimulatorResultItem {
849
851
  damage_state_map: Record<DamageState, number>;
850
852
  }
851
853
 
852
- export type AswAttackType = "DepthCharge" | "Aircraft";
853
-
854
854
  export interface FleetNightCutinRateInfo {
855
855
  night_contact_chance: NightContactChance;
856
856
  ships: ShipNightCutinRateInfo[];
@@ -914,7 +914,7 @@ export class AirSquadron {
914
914
  mode: AirSquadronMode;
915
915
  /**
916
916
  */
917
- xxh3: BigInt;
917
+ xxh3: bigint;
918
918
  }
919
919
  /**
920
920
  */
@@ -1241,7 +1241,6 @@ export class Fleet {
1241
1241
  */
1242
1242
  reset_battle_state(): void;
1243
1243
  /**
1244
- * @returns {number | undefined}
1245
1244
  */
1246
1245
  readonly fleet_los_mod: number | undefined;
1247
1246
  /**
@@ -1252,7 +1251,7 @@ export class Fleet {
1252
1251
  len: number;
1253
1252
  /**
1254
1253
  */
1255
- xxh3: BigInt;
1254
+ xxh3: bigint;
1256
1255
  }
1257
1256
  /**
1258
1257
  */
@@ -1271,6 +1270,10 @@ export class Gear {
1271
1270
  * @returns {GearCategory}
1272
1271
  */
1273
1272
  category(): GearCategory;
1273
+ /**
1274
+ * @returns {boolean}
1275
+ */
1276
+ is_high_angle_mount(): boolean;
1274
1277
  /**
1275
1278
  * @returns {boolean}
1276
1279
  */
@@ -1366,14 +1369,12 @@ export class Gear {
1366
1369
  */
1367
1370
  accuracy: number;
1368
1371
  /**
1369
- * @returns {number}
1370
1372
  */
1371
1373
  readonly ace: number;
1372
1374
  /**
1373
1375
  */
1374
1376
  anti_air: number;
1375
1377
  /**
1376
- * @returns {number}
1377
1378
  */
1378
1379
  readonly anti_bomber: number;
1379
1380
  /**
@@ -1410,11 +1411,9 @@ export class Gear {
1410
1411
  */
1411
1412
  gear_type: GearType;
1412
1413
  /**
1413
- * @returns {number}
1414
1414
  */
1415
1415
  readonly gear_type_id: number;
1416
1416
  /**
1417
- * @returns {number}
1418
1417
  */
1419
1418
  readonly icon_id: number;
1420
1419
  /**
@@ -1424,7 +1423,6 @@ export class Gear {
1424
1423
  */
1425
1424
  improvable: boolean;
1426
1425
  /**
1427
- * @returns {number}
1428
1426
  */
1429
1427
  readonly interception: number;
1430
1428
  /**
@@ -1449,7 +1447,6 @@ export class Gear {
1449
1447
  */
1450
1448
  ship_anti_air_resistance: number;
1451
1449
  /**
1452
- * @returns {number}
1453
1450
  */
1454
1451
  readonly special_type_id: number;
1455
1452
  /**
@@ -1466,7 +1463,7 @@ export class Gear {
1466
1463
  types: Uint8Array;
1467
1464
  /**
1468
1465
  */
1469
- xxh3: BigInt;
1466
+ xxh3: bigint;
1470
1467
  }
1471
1468
  /**
1472
1469
  */
@@ -1659,7 +1656,7 @@ export class Org {
1659
1656
  sortie: string;
1660
1657
  /**
1661
1658
  */
1662
- xxh3: BigInt;
1659
+ xxh3: bigint;
1663
1660
  }
1664
1661
  /**
1665
1662
  */
@@ -1855,27 +1852,28 @@ export class Ship {
1855
1852
  * @returns {number | undefined}
1856
1853
  */
1857
1854
  elos(node_divaricated_factor: number): number | undefined;
1855
+ /**
1856
+ * 確殺攻撃力
1857
+ * @returns {number | undefined}
1858
+ */
1859
+ ohko_power(): number | undefined;
1858
1860
  /**
1859
1861
  * @param {number} value
1860
1862
  */
1861
1863
  take_damage(value: number): void;
1862
1864
  /**
1863
- * @returns {number}
1864
1865
  */
1865
1866
  readonly accuracy: number;
1866
1867
  /**
1867
1868
  */
1868
1869
  ammo: number;
1869
1870
  /**
1870
- * @returns {number | undefined}
1871
1871
  */
1872
1872
  readonly anti_air: number | undefined;
1873
1873
  /**
1874
- * @returns {number | undefined}
1875
1874
  */
1876
1875
  readonly armor: number | undefined;
1877
1876
  /**
1878
- * @returns {number | undefined}
1879
1877
  */
1880
1878
  readonly asw: number | undefined;
1881
1879
  /**
@@ -1885,11 +1883,9 @@ export class Ship {
1885
1883
  */
1886
1884
  current_hp: number;
1887
1885
  /**
1888
- * @returns {number | undefined}
1889
1886
  */
1890
1887
  readonly evasion: number | undefined;
1891
1888
  /**
1892
- * @returns {number | undefined}
1893
1889
  */
1894
1890
  readonly firepower: number | undefined;
1895
1891
  /**
@@ -1898,78 +1894,64 @@ export class Ship {
1898
1894
  /**
1899
1895
  */
1900
1896
  id: string;
1897
+ /**
1898
+ */
1899
+ readonly innate_torpedo_accuracy: number;
1901
1900
  /**
1902
1901
  */
1903
1902
  level: number;
1904
1903
  /**
1905
- * @returns {number | undefined}
1906
1904
  */
1907
1905
  readonly los: number | undefined;
1908
1906
  /**
1909
- * @returns {number | undefined}
1910
1907
  */
1911
1908
  readonly luck: number | undefined;
1912
1909
  /**
1913
- * @returns {number}
1914
1910
  */
1915
1911
  readonly max_ammo: number;
1916
1912
  /**
1917
- * @returns {number}
1918
1913
  */
1919
1914
  readonly max_fuel: number;
1920
1915
  /**
1921
- * @returns {number | undefined}
1922
1916
  */
1923
1917
  readonly max_hp: number | undefined;
1924
1918
  /**
1925
1919
  */
1926
1920
  morale: number;
1927
1921
  /**
1928
- * @returns {number | undefined}
1929
1922
  */
1930
1923
  readonly naked_anti_air: number | undefined;
1931
1924
  /**
1932
- * @returns {number | undefined}
1933
1925
  */
1934
1926
  readonly naked_armor: number | undefined;
1935
1927
  /**
1936
- * @returns {number | undefined}
1937
1928
  */
1938
1929
  readonly naked_asw: number | undefined;
1939
1930
  /**
1940
- * @returns {number | undefined}
1941
1931
  */
1942
1932
  readonly naked_evasion: number | undefined;
1943
1933
  /**
1944
- * @returns {number | undefined}
1945
1934
  */
1946
1935
  readonly naked_firepower: number | undefined;
1947
1936
  /**
1948
- * @returns {number | undefined}
1949
1937
  */
1950
1938
  readonly naked_los: number | undefined;
1951
1939
  /**
1952
- * @returns {number | undefined}
1953
1940
  */
1954
1941
  readonly naked_range: number | undefined;
1955
1942
  /**
1956
- * @returns {number}
1957
1943
  */
1958
1944
  readonly naked_speed: number;
1959
1945
  /**
1960
- * @returns {number | undefined}
1961
1946
  */
1962
1947
  readonly naked_torpedo: number | undefined;
1963
1948
  /**
1964
- * @returns {string}
1965
1949
  */
1966
1950
  readonly name: string;
1967
1951
  /**
1968
- * @returns {number}
1969
1952
  */
1970
1953
  readonly next_id: number;
1971
1954
  /**
1972
- * @returns {number | undefined}
1973
1955
  */
1974
1956
  readonly range: number | undefined;
1975
1957
  /**
@@ -1979,41 +1961,30 @@ export class Ship {
1979
1961
  */
1980
1962
  ship_type: ShipType;
1981
1963
  /**
1982
- * @returns {number}
1983
1964
  */
1984
1965
  readonly slotnum: number;
1985
1966
  /**
1986
1967
  */
1987
1968
  slots: SlotSizeVec;
1988
1969
  /**
1989
- * @returns {number}
1990
1970
  */
1991
1971
  readonly sort_id: number;
1992
1972
  /**
1993
- * @returns {number}
1994
1973
  */
1995
1974
  readonly speed: number;
1996
1975
  /**
1997
- * @returns {number}
1998
1976
  */
1999
1977
  readonly stype: number;
2000
1978
  /**
2001
- * @returns {number | undefined}
2002
1979
  */
2003
1980
  readonly torpedo: number | undefined;
2004
1981
  /**
2005
- * @returns {number}
2006
- */
2007
- readonly torpedo_accuracy_mod: number;
2008
- /**
2009
- * @returns {boolean}
2010
1982
  */
2011
1983
  readonly useful: boolean;
2012
1984
  /**
2013
1985
  */
2014
- xxh3: BigInt;
1986
+ xxh3: bigint;
2015
1987
  /**
2016
- * @returns {string}
2017
1988
  */
2018
1989
  readonly yomi: string;
2019
1990
  }