fleethub-core 1.3.0 → 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,9 +5,6 @@
5
5
  * @returns {boolean}
6
6
  */
7
7
  export function air_squadron_can_equip(gear: Gear): boolean;
8
- /**
9
- */
10
- export function set_panic_hook(): void;
11
8
  /**
12
9
  * @param {OrgType} org_type
13
10
  * @returns {boolean}
@@ -28,6 +25,9 @@ export function org_type_is_player(org_type: OrgType): boolean;
28
25
  * @returns {Side}
29
26
  */
30
27
  export function org_type_side(org_type: OrgType): Side;
28
+ /**
29
+ */
30
+ export function set_panic_hook(): void;
31
31
  export type CompDayCutinRateInfo = {
32
32
  main: FleetDayCutinRateInfo;
33
33
  escort: FleetDayCutinRateInfo | null;
@@ -63,59 +63,101 @@ export type DamageInfo = {
63
63
  damage_state_map: NumMap<DamageState, number>;
64
64
  };
65
65
 
66
- export type GearTypes = [number, number, number, number, number];
66
+ export type AirWaveType = "Jet" | "LandBase" | "Carrier";
67
67
 
68
- export type MasterGear = {
69
- gear_id: number;
70
- name: string;
71
- types: GearTypes;
72
- special_type?: number;
73
- max_hp?: number;
74
- firepower?: number;
75
- armor?: number;
76
- torpedo?: number;
77
- anti_air?: number;
78
- speed?: number;
79
- bombing?: number;
80
- asw?: number;
81
- los?: number;
82
- luck?: number;
83
- accuracy?: number;
84
- evasion?: number;
85
- range?: number;
86
- radius?: number;
87
- cost?: number;
88
- improvable?: boolean;
89
- adjusted_anti_air_resistance?: number;
90
- fleet_anti_air_resistance?: number;
68
+ export type SimulatorResult = {
69
+ items: SimulatorResultItem[];
70
+ sunk_vec: [number, number, number][];
91
71
  };
92
72
 
93
- export type MasterVariantDef = { tag: string; id: number; name: string };
73
+ export type SimulatorResultItem = {
74
+ id: string;
75
+ role: Role;
76
+ index: number;
77
+ damage_state_map: Record<DamageState, number>;
78
+ };
94
79
 
95
- export type MasterAttrRule = { tag: string; name: string; expr: string };
80
+ export type FleetNightCutinRateInfo = {
81
+ night_contact_chance: NightContactChance;
82
+ ships: ShipNightCutinRateInfo[];
83
+ };
96
84
 
97
- export type MasterIBonusRule = { expr: string; formula: string };
85
+ export type ShipNightCutinRateInfo = {
86
+ ship_id: number;
87
+ normal: NightCutinRateInfo;
88
+ chuuha: NightCutinRateInfo;
89
+ };
98
90
 
99
- export type MasterIBonuses = {
100
- shelling_power: MasterIBonusRule[];
101
- carrier_shelling_power: MasterIBonusRule[];
102
- shelling_accuracy: MasterIBonusRule[];
103
- torpedo_power: MasterIBonusRule[];
104
- torpedo_accuracy: MasterIBonusRule[];
105
- torpedo_evasion: MasterIBonusRule[];
106
- asw_power: MasterIBonusRule[];
107
- asw_accuracy: MasterIBonusRule[];
108
- night_power: MasterIBonusRule[];
109
- night_accuracy: MasterIBonusRule[];
110
- defense_power: MasterIBonusRule[];
111
- contact_selection: MasterIBonusRule[];
112
- fighter_power: MasterIBonusRule[];
113
- adjusted_anti_air: MasterIBonusRule[];
114
- fleet_anti_air: MasterIBonusRule[];
115
- elos: MasterIBonusRule[];
91
+ export type NightCutinRateInfo = {
92
+ cutin_term: number | null;
93
+ rates: [NightCutin | null, number | null][];
116
94
  };
117
95
 
118
- export type StatInterval = [number | null, number | null];
96
+ export type NightContactChance = {
97
+ rank1: number;
98
+ rank2: number;
99
+ rank3: number;
100
+ total: number;
101
+ };
102
+
103
+ export type NumMap<K, V> = Partial<Record<K, V>>;
104
+
105
+ export type CompMeta = { fleets: Record<FleetType, FleetMeta> };
106
+
107
+ export type FleetMeta = {
108
+ id: string;
109
+ len: number;
110
+ ships: [string, ShipMeta | null][];
111
+ };
112
+
113
+ export type ShipMeta = { id: string; ship_id: number };
114
+
115
+ export type ContactRank = "Rank1" | "Rank2" | "Rank3";
116
+
117
+ export type WarfareContext = {
118
+ attacker_env: WarfareShipEnvironment;
119
+ target_env: WarfareShipEnvironment;
120
+ engagement: Engagement;
121
+ air_state: AirState;
122
+ custom_mods: CustomModifiers;
123
+ };
124
+
125
+ export type WarfareShipEnvironment = {
126
+ org_type: OrgType;
127
+ role: Role;
128
+ ship_index: number;
129
+ fleet_len: number;
130
+ formation: Formation;
131
+ fleet_los_mod: number | null;
132
+ };
133
+
134
+ export type AswAttackType = "DepthCharge" | "Aircraft";
135
+
136
+ export type MasterData = {
137
+ gears: MasterGear[];
138
+ gear_attrs: MasterAttrRule[];
139
+ ships: MasterShip[];
140
+ ship_attrs: MasterAttrRule[];
141
+ equippable: MasterEquippable;
142
+ ibonuses: MasterIBonuses;
143
+ config: BattleConfig;
144
+ };
145
+
146
+ export type MasterEquippable = {
147
+ equip_stype: EquipStype[];
148
+ equip_exslot: number[];
149
+ equip_ship: MstEquipShip[];
150
+ equip_exslot_ship: MstEquipExslotShip[];
151
+ };
152
+
153
+ export type MstEquipExslotShip = {
154
+ api_slotitem_id: number;
155
+ api_ship_ids: number[];
156
+ };
157
+
158
+ export type MstEquipShip = { api_ship_id: number; api_equip_type: number[] };
159
+
160
+ export type EquipStype = { id: number; equip_type: number[] };
119
161
 
120
162
  export type MasterShip = {
121
163
  ship_id: number;
@@ -140,70 +182,140 @@ export type MasterShip = {
140
182
  next_id?: number;
141
183
  next_level?: number;
142
184
  slotnum: number;
143
- slots: Array<number | null>;
185
+ slots: SlotSizeVec;
144
186
  stock: Array<GearState>;
145
187
  speed_group?: SpeedGroup;
146
188
  useful?: boolean;
147
189
  };
148
190
 
149
- export type EquipStype = { id: number; equip_type: number[] };
150
-
151
- export type MstEquipShip = { api_ship_id: number; api_equip_type: number[] };
152
-
153
- export type MstEquipExslotShip = {
154
- api_slotitem_id: number;
155
- api_ship_ids: number[];
156
- };
191
+ export type StatInterval = [number | null, number | null];
157
192
 
158
- export type MasterEquippable = {
159
- equip_stype: EquipStype[];
160
- equip_exslot: number[];
161
- equip_ship: MstEquipShip[];
162
- equip_exslot_ship: MstEquipExslotShip[];
193
+ export type MasterIBonuses = {
194
+ shelling_power: MasterIBonusRule[];
195
+ carrier_shelling_power: MasterIBonusRule[];
196
+ shelling_accuracy: MasterIBonusRule[];
197
+ torpedo_power: MasterIBonusRule[];
198
+ torpedo_accuracy: MasterIBonusRule[];
199
+ torpedo_evasion: MasterIBonusRule[];
200
+ asw_power: MasterIBonusRule[];
201
+ asw_accuracy: MasterIBonusRule[];
202
+ night_power: MasterIBonusRule[];
203
+ night_accuracy: MasterIBonusRule[];
204
+ defense_power: MasterIBonusRule[];
205
+ contact_selection: MasterIBonusRule[];
206
+ fighter_power: MasterIBonusRule[];
207
+ adjusted_anti_air: MasterIBonusRule[];
208
+ fleet_anti_air: MasterIBonusRule[];
209
+ elos: MasterIBonusRule[];
163
210
  };
164
211
 
165
- export type MasterData = {
166
- gears: MasterGear[];
167
- gear_attrs: MasterAttrRule[];
168
- ships: MasterShip[];
169
- ship_attrs: MasterAttrRule[];
170
- equippable: MasterEquippable;
171
- ibonuses: MasterIBonuses;
172
- config: BattleConfig;
173
- };
212
+ export type MasterIBonusRule = { expr: string; formula: string };
174
213
 
175
- export type ContactRank = "Rank1" | "Rank2" | "Rank3";
214
+ export type MasterAttrRule = { tag: string; name: string; expr: string };
176
215
 
177
- export type SimulatorResult = {
178
- items: SimulatorResultItem[];
179
- sunk_vec: [number, number, number][];
180
- };
216
+ export type MasterVariantDef = { tag: string; id: number; name: string };
181
217
 
182
- export type SimulatorResultItem = {
183
- id: string;
184
- role: Role;
185
- index: number;
186
- damage_state_map: Record<DamageState, number>;
218
+ export type MasterGear = {
219
+ gear_id: number;
220
+ name: string;
221
+ types: GearTypeIdArray;
222
+ special_type?: number;
223
+ max_hp?: number;
224
+ firepower?: number;
225
+ armor?: number;
226
+ torpedo?: number;
227
+ anti_air?: number;
228
+ speed?: number;
229
+ bombing?: number;
230
+ asw?: number;
231
+ los?: number;
232
+ luck?: number;
233
+ accuracy?: number;
234
+ evasion?: number;
235
+ range?: number;
236
+ radius?: number;
237
+ cost?: number;
238
+ improvable?: boolean;
239
+ adjusted_anti_air_resistance?: number;
240
+ fleet_anti_air_resistance?: number;
187
241
  };
188
242
 
189
- export type AswAttackType = "DepthCharge" | "Aircraft";
190
-
191
- export type SpecialEnemyType =
192
- | "None"
193
- | "SoftSkinned"
194
- | "Pillbox"
195
- | "IsolatedIsland"
196
- | "SupplyDepot"
197
- | "HarbourSummerPrincess"
198
- | "PtImp"
199
- | "BattleshipSummerPrincess"
200
- | "HeavyCruiserSummerPrincess";
201
-
202
- export type MoraleState = "Sparkle" | "Normal" | "Orange" | "Red";
243
+ export type GearCategory =
244
+ | "Fighter"
245
+ | "Bomber"
246
+ | "Recon"
247
+ | "MainGun"
248
+ | "Secondary"
249
+ | "Torpedo"
250
+ | "AntiSub"
251
+ | "Radar"
252
+ | "Landing"
253
+ | "Ration"
254
+ | "LandBased"
255
+ | "Misc";
203
256
 
204
- export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
257
+ export type GearType =
258
+ | "Unknown"
259
+ | "SmallMainGun"
260
+ | "MediumMainGun"
261
+ | "LargeMainGun"
262
+ | "SecondaryGun"
263
+ | "Torpedo"
264
+ | "CbFighter"
265
+ | "CbDiveBomber"
266
+ | "CbTorpedoBomber"
267
+ | "CbRecon"
268
+ | "ReconSeaplane"
269
+ | "SeaplaneBomber"
270
+ | "SmallRadar"
271
+ | "LargeRadar"
272
+ | "Sonar"
273
+ | "DepthCharge"
274
+ | "ExtraArmor"
275
+ | "Engine"
276
+ | "AntiAirShell"
277
+ | "ApShell"
278
+ | "VtFuze"
279
+ | "AntiAirGun"
280
+ | "MidgetSubmarine"
281
+ | "EmergencyRepair"
282
+ | "LandingCraft"
283
+ | "Rotorcraft"
284
+ | "AntiSubPatrolAircraft"
285
+ | "MediumArmor"
286
+ | "LargeArmor"
287
+ | "Searchlight"
288
+ | "SupplyContainer"
289
+ | "ShipRepairFacility"
290
+ | "SubmarineTorpedo"
291
+ | "Starshell"
292
+ | "CommandFacility"
293
+ | "AviationPersonnel"
294
+ | "AntiAirFireDirector"
295
+ | "AntiGroundEquipment"
296
+ | "LargeMainGun2"
297
+ | "ShipPersonnel"
298
+ | "LargeSonar"
299
+ | "LargeFlyingBoat"
300
+ | "LargeSearchlight"
301
+ | "CombatRation"
302
+ | "Supplies"
303
+ | "SeaplaneFighter"
304
+ | "AmphibiousTank"
305
+ | "LbAttacker"
306
+ | "LbFighter"
307
+ | "LbRecon"
308
+ | "TransportationMaterial"
309
+ | "SubmarineEquipment"
310
+ | "LargeLbAircraft"
311
+ | "JetFighter"
312
+ | "JetFighterBomber"
313
+ | "JetTorpedoBomber"
314
+ | "JetRecon"
315
+ | "LargeRadar2"
316
+ | "CbRecon2";
205
317
 
206
- export type SpeedGroup = "A" | "B1" | "B2" | "C";
318
+ export type GearTypeIdArray = [number, number, number, number, number];
207
319
 
208
320
  export type ShipAttr =
209
321
  | "Abyssal"
@@ -220,6 +332,36 @@ export type ShipAttr =
220
332
  | "BattleshipSummerPrincess"
221
333
  | "HeavyCruiserSummerPrincess";
222
334
 
335
+ export type GearAttr =
336
+ | "Abyssal"
337
+ | "HighAngleMount"
338
+ | "NightFighter"
339
+ | "NightAttacker"
340
+ | "HeavyBomber"
341
+ | "MainGun"
342
+ | "Radar"
343
+ | "SurfaceRadar"
344
+ | "AirRadar"
345
+ | "DepthChargeProjector"
346
+ | "AdditionalDepthCharge"
347
+ | "AntiSubMortar"
348
+ | "AntiSubWeapon"
349
+ | "AntiSubAircraft"
350
+ | "LateModelBowTorpedo"
351
+ | "Seaplane"
352
+ | "CbAircraft"
353
+ | "LbAircraft"
354
+ | "JetAircraft"
355
+ | "Fighter"
356
+ | "Recon"
357
+ | "ObservationSeaplane"
358
+ | "CbFighterBomber"
359
+ | "AntiInstDiveBomber"
360
+ | "NightRecon"
361
+ | "CbSwordfish"
362
+ | "SemiNightPlane"
363
+ | "HighAltitudeInterceptor";
364
+
223
365
  export type ShipType =
224
366
  | "Unknown"
225
367
  | "DE"
@@ -245,106 +387,37 @@ export type ShipType =
245
387
  | "CT"
246
388
  | "AO";
247
389
 
248
- export type ShipCategory =
249
- | "Battleship"
250
- | "AircraftCarrier"
251
- | "HeavyCruiser"
252
- | "LightCruiser"
253
- | "Destroyer"
254
- | "CoastalDefenseShip"
255
- | "Submarine"
256
- | "AuxiliaryShip";
257
-
258
- export type WarfareContext = {
259
- attacker_env: WarfareShipEnvironment;
260
- target_env: WarfareShipEnvironment;
261
- engagement: Engagement;
262
- air_state: AirState;
263
- custom_mods: CustomModifiers;
264
- };
265
-
266
- export type WarfareShipEnvironment = {
267
- org_type: OrgType;
268
- role: Role;
269
- ship_index: number;
270
- fleet_len: number;
271
- formation: Formation;
272
- fleet_los_mod: number | null;
273
- };
274
-
275
- export type ShellingSpecialAttack =
276
- | { DayCutin: DayCutin }
277
- | { FleetCutin: FleetCutin };
278
-
279
- export type DayCutin =
280
- | "MainMain"
281
- | "MainAp"
282
- | "MainRadar"
283
- | "MainSec"
284
- | "DoubleAttack"
285
- | "FBA"
286
- | "BBA"
287
- | "BA"
288
- | "Zuiun"
289
- | "AirSea";
290
-
291
- export type CompMeta = { fleets: Record<FleetType, FleetMeta> };
292
-
293
- export type FleetMeta = {
294
- id: string;
295
- len: number;
296
- ships: [string, ShipMeta | null][];
297
- };
298
-
299
- export type ShipMeta = { id: string; ship_id: number };
300
-
301
- export type Engagement = "GreenT" | "Parallel" | "HeadOn" | "RedT";
302
-
303
- export type AttackPower = {
304
- precap: number;
305
- is_capped: boolean;
306
- capped: number;
307
- normal: number;
308
- critical: number;
309
- armor_penetration: number;
310
- remaining_ammo_mod: number;
311
- };
312
-
313
- export type AttackPowerParams = {
314
- basic: number;
315
- cap: number;
316
- precap_mod: AttackPowerModifier;
317
- postcap_mod: AttackPowerModifier;
318
- ap_shell_mod: number | null;
319
- carrier_power: number | null;
320
- proficiency_critical_mod: number | null;
321
- armor_penetration: number;
322
- remaining_ammo_mod: number;
323
- special_enemy_mods: SpecialEnemyModifiers;
324
- custom_mods: CustomModifiers;
325
- };
390
+ export type ShipCategory =
391
+ | "Battleship"
392
+ | "AircraftCarrier"
393
+ | "HeavyCruiser"
394
+ | "LightCruiser"
395
+ | "Destroyer"
396
+ | "CoastalDefenseShip"
397
+ | "Submarine"
398
+ | "AuxiliaryShip";
326
399
 
327
- export type CustomModifiers = {
328
- precap_mod: AttackPowerModifier;
329
- postcap_mod: AttackPowerModifier;
330
- };
400
+ export type ShellingSpecialAttack =
401
+ | { DayCutin: DayCutin }
402
+ | { FleetCutin: FleetCutin };
331
403
 
332
- export type SpecialEnemyModifiers = {
333
- precap_general_mod: AttackPowerModifier;
334
- stype_mod: AttackPowerModifier;
335
- landing_craft_synergy_mod: AttackPowerModifier;
336
- toku_daihatsu_tank_mod: AttackPowerModifier;
337
- m4a1dd_mod: AttackPowerModifier;
338
- honi_mod: AttackPowerModifier;
339
- postcap_general_mod: AttackPowerModifier;
340
- pt_mod: AttackPowerModifier;
341
- };
404
+ export type DayCutin =
405
+ | "MainMain"
406
+ | "MainAp"
407
+ | "MainRadar"
408
+ | "MainSec"
409
+ | "DoubleAttack"
410
+ | "FBA"
411
+ | "BBA"
412
+ | "BA"
413
+ | "Zuiun"
414
+ | "AirSea";
342
415
 
343
- export type AttackPowerModifier = { a: number; b: number };
416
+ export type Engagement = "GreenT" | "Parallel" | "HeadOn" | "RedT";
344
417
 
345
418
  export type EBonusFnGearInput = {
346
419
  gear_id: number;
347
- types: GearTypes;
420
+ types: GearTypeIdArray;
348
421
  firepower: number;
349
422
  torpedo: number;
350
423
  anti_air: number;
@@ -402,6 +475,48 @@ export type NightSituation = {
402
475
  searchlight: boolean;
403
476
  };
404
477
 
478
+ export type AttackPower = {
479
+ precap: number;
480
+ is_capped: boolean;
481
+ capped: number;
482
+ normal: number;
483
+ critical: number;
484
+ armor_penetration: number;
485
+ remaining_ammo_mod: number;
486
+ };
487
+
488
+ export type AttackPowerParams = {
489
+ basic: number;
490
+ cap: number;
491
+ precap_mod: AttackPowerModifier;
492
+ postcap_mod: AttackPowerModifier;
493
+ ap_shell_mod: number | null;
494
+ carrier_power: number | null;
495
+ proficiency_critical_mod: number | null;
496
+ armor_penetration: number;
497
+ remaining_ammo_mod: number;
498
+ special_enemy_mods: SpecialEnemyModifiers;
499
+ custom_mods: CustomModifiers;
500
+ };
501
+
502
+ export type CustomModifiers = {
503
+ precap_mod: AttackPowerModifier;
504
+ postcap_mod: AttackPowerModifier;
505
+ };
506
+
507
+ export type SpecialEnemyModifiers = {
508
+ precap_general_mod: AttackPowerModifier;
509
+ stype_mod: AttackPowerModifier;
510
+ landing_craft_synergy_mod: AttackPowerModifier;
511
+ toku_daihatsu_tank_mod: AttackPowerModifier;
512
+ m4a1dd_mod: AttackPowerModifier;
513
+ honi_mod: AttackPowerModifier;
514
+ postcap_general_mod: AttackPowerModifier;
515
+ pt_mod: AttackPowerModifier;
516
+ };
517
+
518
+ export type AttackPowerModifier = { a: number; b: number };
519
+
405
520
  export type GearState = {
406
521
  id?: string;
407
522
  gear_id: number;
@@ -501,8 +616,6 @@ export type ShipKey = "s1" | "s2" | "s3" | "s4" | "s5" | "s6" | "s7";
501
616
 
502
617
  export type ShipStateMap = Record<ShipKey, ShipState>;
503
618
 
504
- export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
505
-
506
619
  export type CompAntiAirInfo = {
507
620
  fleet_anti_air: number;
508
621
  ships: ShipAntiAirInfo[];
@@ -519,111 +632,6 @@ export type ShipAntiAirInfo = {
519
632
  anti_air_propellant_barrage_chance: number | null;
520
633
  };
521
634
 
522
- export type GearAttr =
523
- | "Abyssal"
524
- | "HighAngleMount"
525
- | "NightFighter"
526
- | "NightAttacker"
527
- | "HeavyBomber"
528
- | "MainGun"
529
- | "Radar"
530
- | "SurfaceRadar"
531
- | "AirRadar"
532
- | "DepthChargeProjector"
533
- | "AdditionalDepthCharge"
534
- | "AntiSubMortar"
535
- | "AntiSubWeapon"
536
- | "AntiSubAircraft"
537
- | "LateModelBowTorpedo"
538
- | "Seaplane"
539
- | "CbAircraft"
540
- | "LbAircraft"
541
- | "JetAircraft"
542
- | "Fighter"
543
- | "Recon"
544
- | "ObservationSeaplane"
545
- | "CbFighterBomber"
546
- | "AntiInstDiveBomber"
547
- | "NightRecon"
548
- | "CbSwordfish"
549
- | "SemiNightPlane"
550
- | "HighAltitudeInterceptor";
551
-
552
- export type GearCategory =
553
- | "Fighter"
554
- | "Bomber"
555
- | "Recon"
556
- | "MainGun"
557
- | "Secondary"
558
- | "Torpedo"
559
- | "AntiSub"
560
- | "Radar"
561
- | "Landing"
562
- | "Ration"
563
- | "LandBased"
564
- | "Misc";
565
-
566
- export type GearType =
567
- | "Unknown"
568
- | "SmallMainGun"
569
- | "MediumMainGun"
570
- | "LargeMainGun"
571
- | "SecondaryGun"
572
- | "Torpedo"
573
- | "CbFighter"
574
- | "CbDiveBomber"
575
- | "CbTorpedoBomber"
576
- | "CbRecon"
577
- | "ReconSeaplane"
578
- | "SeaplaneBomber"
579
- | "SmallRadar"
580
- | "LargeRadar"
581
- | "Sonar"
582
- | "DepthCharge"
583
- | "ExtraArmor"
584
- | "Engine"
585
- | "AntiAirShell"
586
- | "ApShell"
587
- | "VtFuze"
588
- | "AntiAirGun"
589
- | "MidgetSubmarine"
590
- | "EmergencyRepair"
591
- | "LandingCraft"
592
- | "Rotorcraft"
593
- | "AntiSubPatrolAircraft"
594
- | "MediumArmor"
595
- | "LargeArmor"
596
- | "Searchlight"
597
- | "SupplyContainer"
598
- | "ShipRepairFacility"
599
- | "SubmarineTorpedo"
600
- | "Starshell"
601
- | "CommandFacility"
602
- | "AviationPersonnel"
603
- | "AntiAirFireDirector"
604
- | "AntiGroundEquipment"
605
- | "LargeMainGun2"
606
- | "ShipPersonnel"
607
- | "LargeSonar"
608
- | "LargeFlyingBoat"
609
- | "LargeSearchlight"
610
- | "CombatRation"
611
- | "Supplies"
612
- | "SeaplaneFighter"
613
- | "AmphibiousTank"
614
- | "LbAttacker"
615
- | "LbFighter"
616
- | "LbRecon"
617
- | "TransportationMaterial"
618
- | "SubmarineEquipment"
619
- | "LargeLbAircraft"
620
- | "JetFighter"
621
- | "JetFighterBomber"
622
- | "JetTorpedoBomber"
623
- | "JetRecon"
624
- | "LargeRadar2"
625
- | "CbRecon2";
626
-
627
635
  export type Formation = SingleFormation | CombinedFormation;
628
636
 
629
637
  export type CombinedFormation =
@@ -640,6 +648,18 @@ export type SingleFormation =
640
648
  | "LineAbreast"
641
649
  | "Vanguard";
642
650
 
651
+ export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
652
+
653
+ export type ShellingAttackType = "Normal" | "Carrier";
654
+
655
+ export type NightBattleAttackType =
656
+ | { t: "NightAttack"; c: NightAttackType }
657
+ | { t: "Asw"; c: AswAttackType };
658
+
659
+ export type DayBattleAttackType =
660
+ | { t: "Shelling"; c: ShellingAttackType }
661
+ | { t: "Asw"; c: AswAttackType };
662
+
643
663
  export type FleetCutinAnalysis = {
644
664
  shelling: FleetCutinInfo[];
645
665
  night: FleetCutinInfo[];
@@ -693,19 +713,11 @@ export type AirstrikeContactChance = {
693
713
  total: number;
694
714
  };
695
715
 
696
- export type ShellingAttackType = "Normal" | "Carrier";
697
-
698
- export type NightBattleAttackType =
699
- | { t: "NightAttack"; c: NightAttackType }
700
- | { t: "Asw"; c: AswAttackType };
701
-
702
- export type DayBattleAttackType =
703
- | { t: "Shelling"; c: ShellingAttackType }
704
- | { t: "Asw"; c: AswAttackType };
705
-
706
716
  import * as bindings from "../bindings";
707
717
  export * from "../bindings";
708
718
 
719
+ export type SlotSizeVec = (number | null)[];
720
+
709
721
  export type NightAttackType = "Normal" | "ArkRoyal" | "Carrier";
710
722
 
711
723
  export type NightSpecialAttack =
@@ -766,6 +778,23 @@ export type WarfareAnalyzerShipEnvironment = {
766
778
  custom_mods: CustomModifiers;
767
779
  };
768
780
 
781
+ export type SpecialEnemyType =
782
+ | "None"
783
+ | "SoftSkinned"
784
+ | "Pillbox"
785
+ | "IsolatedIsland"
786
+ | "SupplyDepot"
787
+ | "HarbourSummerPrincess"
788
+ | "PtImp"
789
+ | "BattleshipSummerPrincess"
790
+ | "HeavyCruiserSummerPrincess";
791
+
792
+ export type MoraleState = "Sparkle" | "Normal" | "Orange" | "Red";
793
+
794
+ export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
795
+
796
+ export type SpeedGroup = "A" | "B1" | "B2" | "C";
797
+
769
798
  export type FleetCutin =
770
799
  | "NelsonTouch"
771
800
  | "NagatoCutin"
@@ -824,31 +853,6 @@ export type FormationWarfareDef = {
824
853
  evasion_mod: number | null;
825
854
  };
826
855
 
827
- export type AirWaveType = "Jet" | "LandBase" | "Carrier";
828
-
829
- export type FleetNightCutinRateInfo = {
830
- night_contact_chance: NightContactChance;
831
- ships: ShipNightCutinRateInfo[];
832
- };
833
-
834
- export type ShipNightCutinRateInfo = {
835
- ship_id: number;
836
- normal: NightCutinRateInfo;
837
- chuuha: NightCutinRateInfo;
838
- };
839
-
840
- export type NightCutinRateInfo = {
841
- cutin_term: number | null;
842
- rates: [NightCutin | null, number | null][];
843
- };
844
-
845
- export type NightContactChance = {
846
- rank1: number;
847
- rank2: number;
848
- rank3: number;
849
- total: number;
850
- };
851
-
852
856
  /**
853
857
  */
854
858
  export class AirSquadron {
@@ -1427,9 +1431,8 @@ export class Gear {
1427
1431
  */
1428
1432
  torpedo: number;
1429
1433
  /**
1430
- * @returns {any}
1431
1434
  */
1432
- readonly types: any;
1435
+ types: Uint8Array;
1433
1436
  /**
1434
1437
  */
1435
1438
  xxh3: BigInt;
@@ -1948,6 +1951,9 @@ export class Ship {
1948
1951
  * @returns {number}
1949
1952
  */
1950
1953
  readonly slotnum: number;
1954
+ /**
1955
+ */
1956
+ slots: SlotSizeVec;
1951
1957
  /**
1952
1958
  * @returns {number}
1953
1959
  */