fleethub-core 1.9.0 → 1.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/node/fleethub_core.d.ts +355 -339
- package/node/fleethub_core.js +70 -70
- package/node/fleethub_core_bg.wasm +0 -0
- package/node/fleethub_core_bg.wasm.d.ts +36 -36
- package/package.json +1 -1
- package/pkg/fleethub_core.d.ts +355 -339
- package/pkg/fleethub_core_bg.js +70 -70
- package/pkg/fleethub_core_bg.wasm +0 -0
- package/pkg/fleethub_core_bg.wasm.d.ts +36 -36
package/node/fleethub_core.d.ts
CHANGED
|
@@ -8,6 +8,44 @@ export function parse_ship_conditions(value: ShipConditions): ShipConditions;
|
|
|
8
8
|
/**
|
|
9
9
|
*/
|
|
10
10
|
export function set_panic_hook(): void;
|
|
11
|
+
export type ShipKey = "s1" | "s2" | "s3" | "s4" | "s5" | "s6" | "s7";
|
|
12
|
+
|
|
13
|
+
export interface ShipConditions extends ShipPosition {
|
|
14
|
+
formation?: Formation;
|
|
15
|
+
amagiri_index?: number | null;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface ShipPosition {
|
|
19
|
+
org_type?: OrgType;
|
|
20
|
+
fleet_type?: FleetType;
|
|
21
|
+
fleet_len?: number;
|
|
22
|
+
index?: number;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export interface NodeState {
|
|
26
|
+
map?: number;
|
|
27
|
+
node?: NodeId;
|
|
28
|
+
phase?: number;
|
|
29
|
+
debuff?: boolean;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export type NodeId = string;
|
|
33
|
+
|
|
34
|
+
export interface CompMeta {
|
|
35
|
+
fleets: Record<FleetType, FleetMeta>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface FleetMeta {
|
|
39
|
+
id: string;
|
|
40
|
+
len: number;
|
|
41
|
+
ships: [string, ShipMeta | null][];
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface ShipMeta {
|
|
45
|
+
id: string;
|
|
46
|
+
ship_id: number;
|
|
47
|
+
}
|
|
48
|
+
|
|
11
49
|
export type GearCategory =
|
|
12
50
|
| "Fighter"
|
|
13
51
|
| "Bomber"
|
|
@@ -84,100 +122,32 @@ export type GearType =
|
|
|
84
122
|
| "CbRecon2"
|
|
85
123
|
| "SecondaryGun2";
|
|
86
124
|
|
|
87
|
-
export type GearAttr =
|
|
88
|
-
| "Unknown"
|
|
89
|
-
| "Abyssal"
|
|
90
|
-
| "HighAngleMount"
|
|
91
|
-
| "NightFighter"
|
|
92
|
-
| "NightAttacker"
|
|
93
|
-
| "HeavyBomber"
|
|
94
|
-
| "NightRecon"
|
|
95
|
-
| "MainGun"
|
|
96
|
-
| "Radar"
|
|
97
|
-
| "SurfaceRadar"
|
|
98
|
-
| "AirRadar"
|
|
99
|
-
| "DepthChargeProjector"
|
|
100
|
-
| "SynergisticDepthCharge"
|
|
101
|
-
| "AntiSubMortar"
|
|
102
|
-
| "AntiSubWeapon"
|
|
103
|
-
| "ApDepthCharge"
|
|
104
|
-
| "AntiSubAircraft"
|
|
105
|
-
| "LateModelBowTorpedo"
|
|
106
|
-
| "Seaplane"
|
|
107
|
-
| "CbAircraft"
|
|
108
|
-
| "LbAircraft"
|
|
109
|
-
| "JetAircraft"
|
|
110
|
-
| "Fighter"
|
|
111
|
-
| "Recon"
|
|
112
|
-
| "ObservationSeaplane"
|
|
113
|
-
| "CbFighterBomber"
|
|
114
|
-
| "AntiInstDiveBomber"
|
|
115
|
-
| "CbSwordfish"
|
|
116
|
-
| "SemiNightPlane"
|
|
117
|
-
| "HighAltitudeInterceptor"
|
|
118
|
-
| "HistoricalAircraftA1"
|
|
119
|
-
| "HistoricalAircraftA2"
|
|
120
|
-
| "HistoricalAircraftA3"
|
|
121
|
-
| "HistoricalAircraftB1"
|
|
122
|
-
| "HistoricalAircraftB2"
|
|
123
|
-
| "HistoricalAircraftB3"
|
|
124
|
-
| "HistoricalAircraftC1"
|
|
125
|
-
| "HistoricalAircraftC2"
|
|
126
|
-
| "HistoricalAircraftC3";
|
|
127
|
-
|
|
128
125
|
export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
|
|
129
126
|
|
|
130
|
-
export
|
|
131
|
-
formation: Record<Formation, NestedFormationDef>;
|
|
132
|
-
anti_air_cutin: Record<number, AntiAirCutinDef>;
|
|
133
|
-
day_cutin: Record<DayCutin, DayCutinDef>;
|
|
134
|
-
night_cutin: Record<NightCutin, NightCutinDef>;
|
|
135
|
-
}
|
|
127
|
+
export type TorpedoAttackType = null;
|
|
136
128
|
|
|
137
|
-
export
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
type_factor: number | null;
|
|
141
|
-
power_mod: number | null;
|
|
142
|
-
accuracy_mod: number | null;
|
|
143
|
-
}
|
|
129
|
+
export type NightPhaseAttackType =
|
|
130
|
+
| { t: "Night"; c: NightAttackType }
|
|
131
|
+
| { t: "Asw"; c: AswAttackType };
|
|
144
132
|
|
|
145
|
-
export
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
type_factor: number | null;
|
|
149
|
-
power_mod: number | null;
|
|
150
|
-
accuracy_mod: number | null;
|
|
151
|
-
}
|
|
133
|
+
export type DayPhaseAttackType =
|
|
134
|
+
| { t: "Shelling"; c: ShellingType }
|
|
135
|
+
| { t: "Asw"; c: AswAttackType };
|
|
152
136
|
|
|
153
|
-
export
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
}
|
|
137
|
+
export type AttackType =
|
|
138
|
+
| { t: "Asw"; c: AswAttackType }
|
|
139
|
+
| { t: "Shelling"; c: ShellingType }
|
|
140
|
+
| { t: "Night"; c: NightAttackType }
|
|
141
|
+
| { t: "Torpedo" }
|
|
142
|
+
| { t: "SupportShelling"; c: SupportShellingType };
|
|
160
143
|
|
|
161
|
-
export type
|
|
162
|
-
| FormationDef
|
|
163
|
-
| { top_half: FormationDef; bottom_half: FormationDef };
|
|
144
|
+
export type SupportShellingType = ShellingType;
|
|
164
145
|
|
|
165
|
-
export
|
|
166
|
-
tag: Formation;
|
|
167
|
-
protection_rate: number | null;
|
|
168
|
-
fleet_anti_air_mod: number;
|
|
169
|
-
shelling: FormationCombatModifiersDef;
|
|
170
|
-
torpedo: FormationCombatModifiersDef;
|
|
171
|
-
asw: FormationCombatModifiersDef;
|
|
172
|
-
night: FormationCombatModifiersDef;
|
|
173
|
-
support_shelling: FormationCombatModifiersDef;
|
|
174
|
-
}
|
|
146
|
+
export type NightAttackType = "Normal" | "Swordfish" | "Carrier";
|
|
175
147
|
|
|
176
|
-
export
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
evasion_mod?: number;
|
|
180
|
-
}
|
|
148
|
+
export type ShellingType = "Normal" | "Carrier";
|
|
149
|
+
|
|
150
|
+
export type AswAttackType = "DepthCharge" | "Aircraft";
|
|
181
151
|
|
|
182
152
|
export type AirStateRank = "Rank0" | "Rank1" | "Rank2" | "Rank3";
|
|
183
153
|
|
|
@@ -195,7 +165,7 @@ export interface MasterData extends MasterBattleDefinitions {
|
|
|
195
165
|
ships: MasterShip[];
|
|
196
166
|
ship_attrs: MasterAttrRule<ShipAttr>[];
|
|
197
167
|
ibonuses: MasterIBonuses;
|
|
198
|
-
|
|
168
|
+
equippability: MasterEquippability;
|
|
199
169
|
}
|
|
200
170
|
|
|
201
171
|
export interface NationalityDef {
|
|
@@ -209,6 +179,85 @@ export interface MasterAttrRule<T> {
|
|
|
209
179
|
expr: CompiledEvaler;
|
|
210
180
|
}
|
|
211
181
|
|
|
182
|
+
export type SpeedGroup = "A" | "B1" | "B2" | "C";
|
|
183
|
+
|
|
184
|
+
export interface NightFleetConditions {
|
|
185
|
+
night_contact_rank?: ContactRank | null;
|
|
186
|
+
starshell_index?: number | null;
|
|
187
|
+
searchlight_index?: number | null;
|
|
188
|
+
activates_large_searchlight?: boolean;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
export interface NightConditions {
|
|
192
|
+
player?: NightFleetConditions;
|
|
193
|
+
enemy?: NightFleetConditions;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export interface BattleConditions {
|
|
197
|
+
org_type: OrgType;
|
|
198
|
+
role: Role;
|
|
199
|
+
ship_index: number;
|
|
200
|
+
fleet_len: number;
|
|
201
|
+
formation: Formation;
|
|
202
|
+
fleet_los_mod: number | null;
|
|
203
|
+
night_conditions: NightFleetConditions;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
export interface MasterGear {
|
|
207
|
+
gear_id: number;
|
|
208
|
+
name: string;
|
|
209
|
+
types: GearTypeIdArray;
|
|
210
|
+
special_type?: number;
|
|
211
|
+
max_hp?: number;
|
|
212
|
+
firepower?: number;
|
|
213
|
+
armor?: number;
|
|
214
|
+
torpedo?: number;
|
|
215
|
+
anti_air?: number;
|
|
216
|
+
speed?: number;
|
|
217
|
+
bombing?: number;
|
|
218
|
+
asw?: number;
|
|
219
|
+
los?: number;
|
|
220
|
+
luck?: number;
|
|
221
|
+
accuracy?: number;
|
|
222
|
+
evasion?: number;
|
|
223
|
+
range?: number;
|
|
224
|
+
radius?: number;
|
|
225
|
+
cost?: number;
|
|
226
|
+
improvable?: boolean;
|
|
227
|
+
ship_anti_air_resist?: number;
|
|
228
|
+
fleet_anti_air_resist?: number;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export interface EquippabilityRule {
|
|
232
|
+
ship: CompiledEvaler;
|
|
233
|
+
keys?: string[];
|
|
234
|
+
include?: string;
|
|
235
|
+
exclude?: string;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
export interface MasterEquippability {
|
|
239
|
+
equip_stype: EquipStype[];
|
|
240
|
+
equip_exslot: number[];
|
|
241
|
+
equip_ship: MstEquipShip[];
|
|
242
|
+
equip_exslot_ship: MstEquipExslotShip[];
|
|
243
|
+
rules: EquippabilityRule[];
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
export interface MstEquipExslotShip {
|
|
247
|
+
api_slotitem_id: number;
|
|
248
|
+
api_ship_ids: number[];
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
export interface MstEquipShip {
|
|
252
|
+
api_ship_id: number;
|
|
253
|
+
api_equip_type: number[];
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
export interface EquipStype {
|
|
257
|
+
id: number;
|
|
258
|
+
equip_type: number[];
|
|
259
|
+
}
|
|
260
|
+
|
|
212
261
|
export interface OrgState {
|
|
213
262
|
id?: string;
|
|
214
263
|
f1?: FleetState;
|
|
@@ -334,6 +383,7 @@ export interface NodeAttackAnalyzerShipConfig extends NightFleetConditions {
|
|
|
334
383
|
export interface NodeAttackAnalyzerConfig {
|
|
335
384
|
air_state?: AirState;
|
|
336
385
|
engagement?: Engagement;
|
|
386
|
+
node_state?: NodeState;
|
|
337
387
|
left?: NodeAttackAnalyzerShipConfig;
|
|
338
388
|
right?: NodeAttackAnalyzerShipConfig;
|
|
339
389
|
}
|
|
@@ -361,6 +411,22 @@ export type Role = "Main" | "Escort";
|
|
|
361
411
|
|
|
362
412
|
export type MoraleState = "Sparkle" | "Normal" | "Orange" | "Red";
|
|
363
413
|
|
|
414
|
+
export interface AttackReport<T> {
|
|
415
|
+
style: T;
|
|
416
|
+
proc_rate: number | null;
|
|
417
|
+
attack_power: AttackPower | null;
|
|
418
|
+
attack_power_params: AttackPowerParams | null;
|
|
419
|
+
hits: number;
|
|
420
|
+
hit_rate: HitRate | null;
|
|
421
|
+
hit_rate_params: HitRateParams | null;
|
|
422
|
+
damage: DamageReport | null;
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
export interface MoveShipPayload {
|
|
426
|
+
current: [string, string, ShipKey];
|
|
427
|
+
target: [string | null, string, ShipKey];
|
|
428
|
+
}
|
|
429
|
+
|
|
364
430
|
export type NightCutinLike = NightCutin | FleetCutin;
|
|
365
431
|
|
|
366
432
|
export type DayCutinLike = DayCutin | FleetCutin;
|
|
@@ -402,21 +468,7 @@ export type DayCutin =
|
|
|
402
468
|
| "BBA"
|
|
403
469
|
| "BA";
|
|
404
470
|
|
|
405
|
-
export
|
|
406
|
-
style: T;
|
|
407
|
-
proc_rate: number | null;
|
|
408
|
-
attack_power: AttackPower | null;
|
|
409
|
-
attack_power_params: AttackPowerParams | null;
|
|
410
|
-
hits: number;
|
|
411
|
-
hit_rate: HitRate | null;
|
|
412
|
-
hit_rate_params: HitRateParams | null;
|
|
413
|
-
damage: DamageReport | null;
|
|
414
|
-
}
|
|
415
|
-
|
|
416
|
-
export interface MoveShipPayload {
|
|
417
|
-
current: [string, string, ShipKey];
|
|
418
|
-
target: [string | null, string, ShipKey];
|
|
419
|
-
}
|
|
471
|
+
export type ContactRank = "Rank1" | "Rank2" | "Rank3";
|
|
420
472
|
|
|
421
473
|
export type AirWaveType = "Jet" | "LandBase" | "Carrier";
|
|
422
474
|
|
|
@@ -457,16 +509,83 @@ export interface MasterIBonusRule {
|
|
|
457
509
|
formula: CompiledEvaler;
|
|
458
510
|
}
|
|
459
511
|
|
|
460
|
-
export
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
512
|
+
export interface BattleDefinitions {
|
|
513
|
+
formation: Record<Formation, NestedFormationDef>;
|
|
514
|
+
anti_air_cutin: Record<number, AntiAirCutinDef>;
|
|
515
|
+
day_cutin: Record<DayCutin, DayCutinDef>;
|
|
516
|
+
night_cutin: Record<NightCutin, NightCutinDef>;
|
|
517
|
+
historical_bonuses: HistoricalBonusDef[];
|
|
465
518
|
}
|
|
466
519
|
|
|
467
|
-
export
|
|
520
|
+
export interface NightCutinDef {
|
|
521
|
+
tag: NightCutin;
|
|
522
|
+
hits: number;
|
|
523
|
+
type_factor: number | null;
|
|
524
|
+
power_mod: number | null;
|
|
525
|
+
accuracy_mod: number | null;
|
|
526
|
+
}
|
|
468
527
|
|
|
469
|
-
export interface
|
|
528
|
+
export interface HistoricalBonusDef {
|
|
529
|
+
map?: number;
|
|
530
|
+
node?: NodeId;
|
|
531
|
+
phase?: number;
|
|
532
|
+
debuff?: boolean;
|
|
533
|
+
ship?: CompiledEvaler;
|
|
534
|
+
enemy?: CompiledEvaler;
|
|
535
|
+
power_mod?: number;
|
|
536
|
+
accuracy_mod?: number;
|
|
537
|
+
evasion_mod?: number;
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
export interface DayCutinDef {
|
|
541
|
+
tag: DayCutin;
|
|
542
|
+
hits: number;
|
|
543
|
+
type_factor: number | null;
|
|
544
|
+
power_mod: number | null;
|
|
545
|
+
accuracy_mod: number | null;
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
export interface AntiAirCutinDef {
|
|
549
|
+
id: number;
|
|
550
|
+
type_factor: number | null;
|
|
551
|
+
multiplier: number | null;
|
|
552
|
+
guaranteed: number | null;
|
|
553
|
+
sequential: boolean | null;
|
|
554
|
+
}
|
|
555
|
+
|
|
556
|
+
export type NestedFormationDef =
|
|
557
|
+
| FormationDef
|
|
558
|
+
| { top_half: FormationDef; bottom_half: FormationDef };
|
|
559
|
+
|
|
560
|
+
export interface FormationDef {
|
|
561
|
+
tag: Formation;
|
|
562
|
+
protection_rate: number | null;
|
|
563
|
+
fleet_anti_air_mod: number;
|
|
564
|
+
shelling: FormationCombatModifiersDef;
|
|
565
|
+
torpedo: FormationCombatModifiersDef;
|
|
566
|
+
asw: FormationCombatModifiersDef;
|
|
567
|
+
night: FormationCombatModifiersDef;
|
|
568
|
+
support_shelling: FormationCombatModifiersDef;
|
|
569
|
+
}
|
|
570
|
+
|
|
571
|
+
export interface FormationCombatModifiersDef {
|
|
572
|
+
power_mod?: number;
|
|
573
|
+
accuracy_mod?: number;
|
|
574
|
+
evasion_mod?: number;
|
|
575
|
+
}
|
|
576
|
+
|
|
577
|
+
export type Engagement = "GreenT" | "Parallel" | "HeadOn" | "RedT";
|
|
578
|
+
|
|
579
|
+
export type FhResult<T> = { Ok: T } | { Err: string };
|
|
580
|
+
|
|
581
|
+
export interface ShipAnalyzerConfig {
|
|
582
|
+
air_state?: AirState;
|
|
583
|
+
engagement?: Engagement;
|
|
584
|
+
left?: AttackAnalyzerShipConfig;
|
|
585
|
+
right?: AttackAnalyzerShipConfig;
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
export interface EBonuses {
|
|
470
589
|
firepower: number;
|
|
471
590
|
torpedo: number;
|
|
472
591
|
anti_air: number;
|
|
@@ -523,79 +642,104 @@ export type ShipAttr =
|
|
|
523
642
|
| "BattleshipSummerPrincess"
|
|
524
643
|
| "HeavyCruiserSummerPrincess";
|
|
525
644
|
|
|
526
|
-
export
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
645
|
+
export type OrgType =
|
|
646
|
+
| "Single"
|
|
647
|
+
| "CarrierTaskForce"
|
|
648
|
+
| "SurfaceTaskForce"
|
|
649
|
+
| "TransportEscort"
|
|
650
|
+
| "EnemySingle"
|
|
651
|
+
| "EnemyCombined";
|
|
532
652
|
|
|
533
|
-
export
|
|
534
|
-
|
|
535
|
-
|
|
653
|
+
export type GearAttr =
|
|
654
|
+
| "Unknown"
|
|
655
|
+
| "Abyssal"
|
|
656
|
+
| "HighAngleMount"
|
|
657
|
+
| "NightFighter"
|
|
658
|
+
| "NightAttacker"
|
|
659
|
+
| "HeavyBomber"
|
|
660
|
+
| "NightRecon"
|
|
661
|
+
| "MainGun"
|
|
662
|
+
| "Radar"
|
|
663
|
+
| "SurfaceRadar"
|
|
664
|
+
| "AirRadar"
|
|
665
|
+
| "DepthChargeProjector"
|
|
666
|
+
| "SynergisticDepthCharge"
|
|
667
|
+
| "AntiSubMortar"
|
|
668
|
+
| "AntiSubWeapon"
|
|
669
|
+
| "ApDepthCharge"
|
|
670
|
+
| "AntiSubAircraft"
|
|
671
|
+
| "LateModelBowTorpedo"
|
|
672
|
+
| "Seaplane"
|
|
673
|
+
| "CbAircraft"
|
|
674
|
+
| "LbAircraft"
|
|
675
|
+
| "JetAircraft"
|
|
676
|
+
| "Fighter"
|
|
677
|
+
| "Recon"
|
|
678
|
+
| "ObservationSeaplane"
|
|
679
|
+
| "CbFighterBomber"
|
|
680
|
+
| "AntiInstDiveBomber"
|
|
681
|
+
| "CbSwordfish"
|
|
682
|
+
| "SemiNightPlane"
|
|
683
|
+
| "HighAltitudeInterceptor";
|
|
536
684
|
|
|
537
|
-
export
|
|
538
|
-
id: string;
|
|
539
|
-
len: number;
|
|
540
|
-
ships: [string, ShipMeta | null][];
|
|
541
|
-
}
|
|
685
|
+
export type FleetKey = "f1" | "f2" | "f3" | "f4";
|
|
542
686
|
|
|
543
|
-
export interface
|
|
544
|
-
|
|
545
|
-
|
|
687
|
+
export interface SupportShellingSimulatorParams {
|
|
688
|
+
attacker_formation?: Formation;
|
|
689
|
+
target_formation?: Formation;
|
|
690
|
+
engagement: Engagement;
|
|
546
691
|
}
|
|
547
692
|
|
|
548
|
-
export
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
export type DayPhaseAttackType =
|
|
557
|
-
| { t: "Shelling"; c: ShellingType }
|
|
558
|
-
| { t: "Asw"; c: AswAttackType };
|
|
559
|
-
|
|
560
|
-
export type AttackType =
|
|
561
|
-
| { t: "Asw"; c: AswAttackType }
|
|
562
|
-
| { t: "Shelling"; c: ShellingType }
|
|
563
|
-
| { t: "Night"; c: NightAttackType }
|
|
564
|
-
| { t: "Torpedo" }
|
|
565
|
-
| { t: "SupportShelling"; c: SupportShellingType };
|
|
693
|
+
export interface MasterBattleDefinitions {
|
|
694
|
+
formation: NestedFormationDef[];
|
|
695
|
+
anti_air_cutin: AntiAirCutinDef[];
|
|
696
|
+
day_cutin: DayCutinDef[];
|
|
697
|
+
night_cutin: NightCutinDef[];
|
|
698
|
+
historical_bonuses?: HistoricalBonusDef[];
|
|
699
|
+
}
|
|
566
700
|
|
|
567
|
-
export
|
|
701
|
+
export interface AttackAnalyzerShipConfig
|
|
702
|
+
extends ShipConditions,
|
|
703
|
+
NightFleetConditions {
|
|
704
|
+
fleet_los_mod?: number | null;
|
|
705
|
+
}
|
|
568
706
|
|
|
569
|
-
export
|
|
707
|
+
export interface SupportShellingStyle {
|
|
708
|
+
tag: "SupportShellingStyle";
|
|
709
|
+
attack_type: SupportShellingType;
|
|
710
|
+
}
|
|
570
711
|
|
|
571
|
-
export type
|
|
712
|
+
export type NightPhaseAttackStyle = NightAttackStyle | AswAttackStyle;
|
|
572
713
|
|
|
573
|
-
export type
|
|
714
|
+
export type DayPhaseAttackStyle = ShellingStyle | AswAttackStyle;
|
|
574
715
|
|
|
575
|
-
export interface
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
engagement: Engagement;
|
|
716
|
+
export interface TorpedoAttackStyle {
|
|
717
|
+
tag: "TorpedoAttackStyle";
|
|
718
|
+
attack_type: TorpedoAttackType;
|
|
579
719
|
}
|
|
580
720
|
|
|
581
|
-
export
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
air_state?: AirState;
|
|
585
|
-
engagement?: Engagement;
|
|
586
|
-
left?: AttackAnalyzerShipConfig;
|
|
587
|
-
right?: AttackAnalyzerShipConfig;
|
|
721
|
+
export interface AswAttackStyle {
|
|
722
|
+
tag: "AswAttackStyle";
|
|
723
|
+
attack_type: AswAttackType;
|
|
588
724
|
}
|
|
589
725
|
|
|
590
|
-
export
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
726
|
+
export interface NightAttackStyle {
|
|
727
|
+
tag: "NightAttackStyle";
|
|
728
|
+
attack_type: NightAttackType;
|
|
729
|
+
cutin: NightCutinLike | null;
|
|
730
|
+
power_mod: number;
|
|
731
|
+
accuracy_mod: number;
|
|
732
|
+
hits: number;
|
|
733
|
+
}
|
|
597
734
|
|
|
598
|
-
export
|
|
735
|
+
export interface ShellingStyle {
|
|
736
|
+
tag: "ShellingStyle";
|
|
737
|
+
attack_type: ShellingType;
|
|
738
|
+
cutin: DayCutinLike | null;
|
|
739
|
+
power_mod: number;
|
|
740
|
+
accuracy_mod: number;
|
|
741
|
+
hits: number;
|
|
742
|
+
}
|
|
599
743
|
|
|
600
744
|
export interface NightContactChance {
|
|
601
745
|
rank1: number;
|
|
@@ -620,6 +764,32 @@ export interface NightCutinActionReport
|
|
|
620
764
|
cutin_term: number | null;
|
|
621
765
|
}
|
|
622
766
|
|
|
767
|
+
export interface FleetCutinReport<T> {
|
|
768
|
+
cutin: FleetCutin;
|
|
769
|
+
rate: number | null;
|
|
770
|
+
formation: Formation;
|
|
771
|
+
attacks: FleetCutinAttackReport<T>[];
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
export interface FleetCutinAttackReport<T> extends AttackReport<T> {
|
|
775
|
+
index: number;
|
|
776
|
+
ship_id: number;
|
|
777
|
+
power_mod: number;
|
|
778
|
+
}
|
|
779
|
+
|
|
780
|
+
export interface DamageReport {
|
|
781
|
+
miss_damage_min: number;
|
|
782
|
+
miss_damage_max: number;
|
|
783
|
+
normal_damage_min: number;
|
|
784
|
+
normal_damage_max: number;
|
|
785
|
+
critical_damage_min: number;
|
|
786
|
+
critical_damage_max: number;
|
|
787
|
+
normal_scratch_rate: number;
|
|
788
|
+
critical_scratch_rate: number;
|
|
789
|
+
damage_density: Histogram<number, number>;
|
|
790
|
+
damage_state_density: Histogram<DamageState, number>;
|
|
791
|
+
}
|
|
792
|
+
|
|
623
793
|
export interface CompAntiAirAnalysis {
|
|
624
794
|
fleet_adjusted_anti_air: number;
|
|
625
795
|
ships: AntiAirReport[];
|
|
@@ -638,44 +808,25 @@ export interface AntiAirReport {
|
|
|
638
808
|
anti_air_propellant_barrage_chance: number | null;
|
|
639
809
|
}
|
|
640
810
|
|
|
641
|
-
export type
|
|
642
|
-
|
|
643
|
-
export interface SupportShellingStyle {
|
|
644
|
-
tag: "SupportShellingStyle";
|
|
645
|
-
attack_type: SupportShellingType;
|
|
646
|
-
}
|
|
647
|
-
|
|
648
|
-
export type NightPhaseAttackStyle = NightAttackStyle | AswAttackStyle;
|
|
649
|
-
|
|
650
|
-
export type DayPhaseAttackStyle = ShellingStyle | AswAttackStyle;
|
|
811
|
+
export type CompiledEvaler = string;
|
|
651
812
|
|
|
652
|
-
export
|
|
653
|
-
tag: "TorpedoAttackStyle";
|
|
654
|
-
attack_type: TorpedoAttackType;
|
|
655
|
-
}
|
|
813
|
+
export type Formation = SingleFormation | CombinedFormation;
|
|
656
814
|
|
|
657
|
-
export
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
815
|
+
export type CombinedFormation =
|
|
816
|
+
| "Cruising1"
|
|
817
|
+
| "Cruising2"
|
|
818
|
+
| "Cruising3"
|
|
819
|
+
| "Cruising4";
|
|
661
820
|
|
|
662
|
-
export
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
}
|
|
821
|
+
export type SingleFormation =
|
|
822
|
+
| "LineAhead"
|
|
823
|
+
| "DoubleLine"
|
|
824
|
+
| "Diamond"
|
|
825
|
+
| "Echelon"
|
|
826
|
+
| "LineAbreast"
|
|
827
|
+
| "Vanguard";
|
|
670
828
|
|
|
671
|
-
export
|
|
672
|
-
tag: "ShellingStyle";
|
|
673
|
-
attack_type: ShellingType;
|
|
674
|
-
cutin: DayCutinLike | null;
|
|
675
|
-
power_mod: number;
|
|
676
|
-
accuracy_mod: number;
|
|
677
|
-
hits: number;
|
|
678
|
-
}
|
|
829
|
+
export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
|
|
679
830
|
|
|
680
831
|
export interface CustomPowerModifiers {
|
|
681
832
|
precap_mod?: AttackPowerModifier;
|
|
@@ -720,6 +871,7 @@ export interface AttackPowerParams {
|
|
|
720
871
|
armor_penetration: number;
|
|
721
872
|
remaining_ammo_mod: number;
|
|
722
873
|
special_enemy_mods: SpecialEnemyModifiers;
|
|
874
|
+
historical_mod: number;
|
|
723
875
|
custom_mods: CustomPowerModifiers;
|
|
724
876
|
}
|
|
725
877
|
|
|
@@ -734,56 +886,6 @@ export interface SpecialEnemyModifiers {
|
|
|
734
886
|
pt_mod: AttackPowerModifier;
|
|
735
887
|
}
|
|
736
888
|
|
|
737
|
-
export interface FleetCutinReport<T> {
|
|
738
|
-
cutin: FleetCutin;
|
|
739
|
-
rate: number | null;
|
|
740
|
-
formation: Formation;
|
|
741
|
-
attacks: FleetCutinAttackReport<T>[];
|
|
742
|
-
}
|
|
743
|
-
|
|
744
|
-
export interface FleetCutinAttackReport<T> extends AttackReport<T> {
|
|
745
|
-
index: number;
|
|
746
|
-
ship_id: number;
|
|
747
|
-
power_mod: number;
|
|
748
|
-
}
|
|
749
|
-
|
|
750
|
-
export interface DamageReport {
|
|
751
|
-
miss_damage_min: number;
|
|
752
|
-
miss_damage_max: number;
|
|
753
|
-
normal_damage_min: number;
|
|
754
|
-
normal_damage_max: number;
|
|
755
|
-
critical_damage_min: number;
|
|
756
|
-
critical_damage_max: number;
|
|
757
|
-
normal_scratch_rate: number;
|
|
758
|
-
critical_scratch_rate: number;
|
|
759
|
-
damage_density: Histogram<number, number>;
|
|
760
|
-
damage_state_density: Histogram<DamageState, number>;
|
|
761
|
-
}
|
|
762
|
-
|
|
763
|
-
export interface AttackAnalyzerShipConfig
|
|
764
|
-
extends ShipConditions,
|
|
765
|
-
NightFleetConditions {
|
|
766
|
-
fleet_los_mod?: number | null;
|
|
767
|
-
}
|
|
768
|
-
|
|
769
|
-
export type Histogram<K, V> = Partial<Record<K, V>>;
|
|
770
|
-
|
|
771
|
-
export type Formation = SingleFormation | CombinedFormation;
|
|
772
|
-
|
|
773
|
-
export type CombinedFormation =
|
|
774
|
-
| "Cruising1"
|
|
775
|
-
| "Cruising2"
|
|
776
|
-
| "Cruising3"
|
|
777
|
-
| "Cruising4";
|
|
778
|
-
|
|
779
|
-
export type SingleFormation =
|
|
780
|
-
| "LineAhead"
|
|
781
|
-
| "DoubleLine"
|
|
782
|
-
| "Diamond"
|
|
783
|
-
| "Echelon"
|
|
784
|
-
| "LineAbreast"
|
|
785
|
-
| "Vanguard";
|
|
786
|
-
|
|
787
889
|
export interface CompDayCutinAnalysis {
|
|
788
890
|
rank3_air_state: AirState;
|
|
789
891
|
rank2_air_state: AirState;
|
|
@@ -815,6 +917,8 @@ export interface AttackAnalysis {
|
|
|
815
917
|
support_shelling: ActionReport<SupportShellingStyle>;
|
|
816
918
|
}
|
|
817
919
|
|
|
920
|
+
export type Histogram<K, V> = Partial<Record<K, V>>;
|
|
921
|
+
|
|
818
922
|
export type SpecialEnemyType =
|
|
819
923
|
| "None"
|
|
820
924
|
| "SoftSkinned"
|
|
@@ -861,43 +965,6 @@ export interface MasterShip {
|
|
|
861
965
|
|
|
862
966
|
export type StatInterval = [number | null, number | null];
|
|
863
967
|
|
|
864
|
-
export interface EquippabilityRule {
|
|
865
|
-
ship: CompiledEvaler;
|
|
866
|
-
keys?: string[];
|
|
867
|
-
include?: string;
|
|
868
|
-
exclude?: string;
|
|
869
|
-
}
|
|
870
|
-
|
|
871
|
-
export interface MasterEquippability {
|
|
872
|
-
equip_stype: EquipStype[];
|
|
873
|
-
equip_exslot: number[];
|
|
874
|
-
equip_ship: MstEquipShip[];
|
|
875
|
-
equip_exslot_ship: MstEquipExslotShip[];
|
|
876
|
-
rules: EquippabilityRule[];
|
|
877
|
-
}
|
|
878
|
-
|
|
879
|
-
export interface MstEquipExslotShip {
|
|
880
|
-
api_slotitem_id: number;
|
|
881
|
-
api_ship_ids: number[];
|
|
882
|
-
}
|
|
883
|
-
|
|
884
|
-
export interface MstEquipShip {
|
|
885
|
-
api_ship_id: number;
|
|
886
|
-
api_equip_type: number[];
|
|
887
|
-
}
|
|
888
|
-
|
|
889
|
-
export interface EquipStype {
|
|
890
|
-
id: number;
|
|
891
|
-
equip_type: number[];
|
|
892
|
-
}
|
|
893
|
-
|
|
894
|
-
export interface MasterBattleDefinitions {
|
|
895
|
-
formation: NestedFormationDef[];
|
|
896
|
-
anti_air_cutin: AntiAirCutinDef[];
|
|
897
|
-
day_cutin: DayCutinDef[];
|
|
898
|
-
night_cutin: NightCutinDef[];
|
|
899
|
-
}
|
|
900
|
-
|
|
901
968
|
export interface HitRate {
|
|
902
969
|
normal: number;
|
|
903
970
|
critical: number;
|
|
@@ -954,57 +1021,6 @@ export interface CompAnalysis {
|
|
|
954
1021
|
anti_air: CompAntiAirAnalysis;
|
|
955
1022
|
}
|
|
956
1023
|
|
|
957
|
-
export type CompiledEvaler = string;
|
|
958
|
-
|
|
959
|
-
export type SpeedGroup = "A" | "B1" | "B2" | "C";
|
|
960
|
-
|
|
961
|
-
export interface NightFleetConditions {
|
|
962
|
-
night_contact_rank?: ContactRank | null;
|
|
963
|
-
starshell_index?: number | null;
|
|
964
|
-
searchlight_index?: number | null;
|
|
965
|
-
activates_large_searchlight?: boolean;
|
|
966
|
-
}
|
|
967
|
-
|
|
968
|
-
export interface NightConditions {
|
|
969
|
-
player?: NightFleetConditions;
|
|
970
|
-
enemy?: NightFleetConditions;
|
|
971
|
-
}
|
|
972
|
-
|
|
973
|
-
export interface BattleConditions {
|
|
974
|
-
org_type: OrgType;
|
|
975
|
-
role: Role;
|
|
976
|
-
ship_index: number;
|
|
977
|
-
fleet_len: number;
|
|
978
|
-
formation: Formation;
|
|
979
|
-
fleet_los_mod: number | null;
|
|
980
|
-
night_conditions: NightFleetConditions;
|
|
981
|
-
}
|
|
982
|
-
|
|
983
|
-
export interface MasterGear {
|
|
984
|
-
gear_id: number;
|
|
985
|
-
name: string;
|
|
986
|
-
types: GearTypeIdArray;
|
|
987
|
-
special_type?: number;
|
|
988
|
-
max_hp?: number;
|
|
989
|
-
firepower?: number;
|
|
990
|
-
armor?: number;
|
|
991
|
-
torpedo?: number;
|
|
992
|
-
anti_air?: number;
|
|
993
|
-
speed?: number;
|
|
994
|
-
bombing?: number;
|
|
995
|
-
asw?: number;
|
|
996
|
-
los?: number;
|
|
997
|
-
luck?: number;
|
|
998
|
-
accuracy?: number;
|
|
999
|
-
evasion?: number;
|
|
1000
|
-
range?: number;
|
|
1001
|
-
radius?: number;
|
|
1002
|
-
cost?: number;
|
|
1003
|
-
improvable?: boolean;
|
|
1004
|
-
ship_anti_air_resist?: number;
|
|
1005
|
-
fleet_anti_air_resist?: number;
|
|
1006
|
-
}
|
|
1007
|
-
|
|
1008
1024
|
/**
|
|
1009
1025
|
*/
|
|
1010
1026
|
export class AirSquadron {
|