fleethub-core 1.12.7 → 1.12.9
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 +703 -704
- package/node/fleethub_core.js +57 -57
- package/node/fleethub_core_bg.wasm +0 -0
- package/node/fleethub_core_bg.wasm.d.ts +159 -159
- package/package.json +2 -5
- package/pkg/fleethub_core.d.ts +703 -704
- package/pkg/fleethub_core_bg.js +57 -57
- package/pkg/fleethub_core_bg.wasm +0 -0
- package/pkg/fleethub_core_bg.wasm.d.ts +159 -159
package/pkg/fleethub_core.d.ts
CHANGED
|
@@ -2,501 +2,80 @@
|
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
export function parse_ship_conditions(value: ShipConditions): ShipConditions;
|
|
4
4
|
export function set_panic_hook(): void;
|
|
5
|
+
export interface MasterBattleDefinitions {
|
|
6
|
+
formation: NestedFormationDef[];
|
|
7
|
+
anti_air_cutin: AntiAirCutinDef[];
|
|
8
|
+
day_cutin: DayCutinDef[];
|
|
9
|
+
night_cutin: NightCutinDef[];
|
|
10
|
+
historical_bonuses?: HistoricalBonusDef[];
|
|
11
|
+
}
|
|
5
12
|
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
gear_attrs: MasterAttrRule<GearAttr>[];
|
|
12
|
-
ships: MasterShip[];
|
|
13
|
-
ship_attrs: MasterAttrRule<ShipAttr>[];
|
|
14
|
-
ibonuses: MasterIBonuses;
|
|
15
|
-
equippability: MasterEquippability;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export interface NationalityDef {
|
|
19
|
-
id: number;
|
|
20
|
-
ctypes: number[];
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export interface MasterAttrRule<T> {
|
|
24
|
-
tag: T;
|
|
25
|
-
name: string;
|
|
26
|
-
expr: CompiledEvaler;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export interface AttackAnalyzerShipConfig
|
|
30
|
-
extends ShipConditions,
|
|
31
|
-
NightFleetConditions {
|
|
32
|
-
balloons?: number;
|
|
33
|
-
fleet_los_mod?: number | null;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
export type AirSquadronMode = "Sortie" | "AirDefense";
|
|
37
|
-
|
|
38
|
-
export interface AirSquadronState extends GearVecState, SlotSizeVecState {
|
|
39
|
-
id?: string;
|
|
40
|
-
mode?: AirSquadronMode;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export interface BattleConditions {
|
|
44
|
-
org_type: OrgType;
|
|
45
|
-
role: Role;
|
|
46
|
-
ship_index: number;
|
|
47
|
-
fleet_len: number;
|
|
48
|
-
formation: Formation;
|
|
49
|
-
fleet_los_mod: number | null;
|
|
50
|
-
night_conditions: NightFleetConditions;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
export interface NightConditions {
|
|
54
|
-
player?: NightFleetConditions;
|
|
55
|
-
enemy?: NightFleetConditions;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export interface NightFleetConditions {
|
|
59
|
-
night_contact_rank?: ContactRank | null;
|
|
60
|
-
starshell_index?: number | null;
|
|
61
|
-
searchlight_index?: number | null;
|
|
62
|
-
activates_large_searchlight?: boolean;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
export type GearAttr =
|
|
66
|
-
| "Unknown"
|
|
67
|
-
| "HighAngleMount"
|
|
68
|
-
| "NightFighter"
|
|
69
|
-
| "NightAttacker"
|
|
70
|
-
| "HeavyBomber"
|
|
71
|
-
| "NightRecon"
|
|
72
|
-
| "MainGun"
|
|
73
|
-
| "Radar"
|
|
74
|
-
| "SurfaceRadar"
|
|
75
|
-
| "AirRadar"
|
|
76
|
-
| "DepthChargeProjector"
|
|
77
|
-
| "SynergisticDepthCharge"
|
|
78
|
-
| "AntiSubMortar"
|
|
79
|
-
| "AntiSubWeapon"
|
|
80
|
-
| "ApDepthCharge"
|
|
81
|
-
| "AntiSubAircraft"
|
|
82
|
-
| "LateModelBowTorpedo"
|
|
83
|
-
| "Seaplane"
|
|
84
|
-
| "CbAircraft"
|
|
85
|
-
| "LbAircraft"
|
|
86
|
-
| "JetAircraft"
|
|
87
|
-
| "Fighter"
|
|
88
|
-
| "Recon"
|
|
89
|
-
| "ObservationSeaplane"
|
|
90
|
-
| "CbFighterBomber"
|
|
91
|
-
| "AntiInstDiveBomber"
|
|
92
|
-
| "CbSwordfish"
|
|
93
|
-
| "SemiNightPlane"
|
|
94
|
-
| "HighAltitudeInterceptor";
|
|
95
|
-
|
|
96
|
-
export interface ShipPosition {
|
|
97
|
-
org_type?: OrgType;
|
|
98
|
-
fleet_type?: FleetType;
|
|
99
|
-
fleet_len?: number;
|
|
100
|
-
index?: number;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
export type Histogram<K extends keyof any, V> = Partial<Record<K, V>>;
|
|
104
|
-
|
|
105
|
-
export interface MasterGear {
|
|
106
|
-
gear_id: number;
|
|
107
|
-
name: string;
|
|
108
|
-
types: GearTypeIdArray;
|
|
109
|
-
special_type?: number;
|
|
110
|
-
max_hp?: number;
|
|
111
|
-
firepower?: number;
|
|
112
|
-
armor?: number;
|
|
113
|
-
torpedo?: number;
|
|
114
|
-
anti_air?: number;
|
|
115
|
-
speed?: number;
|
|
116
|
-
bombing?: number;
|
|
117
|
-
asw?: number;
|
|
118
|
-
los?: number;
|
|
119
|
-
luck?: number;
|
|
120
|
-
accuracy?: number;
|
|
121
|
-
evasion?: number;
|
|
122
|
-
range?: number;
|
|
123
|
-
radius?: number;
|
|
124
|
-
cost?: number;
|
|
125
|
-
improvable?: boolean;
|
|
126
|
-
ship_anti_air_resist?: number;
|
|
127
|
-
fleet_anti_air_resist?: number;
|
|
128
|
-
historical_aircraft_group?: number;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
export interface CompAnalyzerConfig {
|
|
132
|
-
engagement: Engagement;
|
|
133
|
-
formation: Formation;
|
|
134
|
-
anti_air_cutin: number | null;
|
|
135
|
-
ship_anti_air_resist: number;
|
|
136
|
-
fleet_anti_air_resist: number;
|
|
137
|
-
left_night_fleet_conditions: NightFleetConditions;
|
|
138
|
-
right_night_fleet_conditions: NightFleetConditions;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
export interface CompNightAnalysis {
|
|
142
|
-
night_cutin: CompNightCutinAnalysis;
|
|
143
|
-
fleet_cutin: FleetCutinReport<NightAttackStyle>[];
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
export interface CompDayAnalysis {
|
|
147
|
-
day_cutin: CompDayCutinAnalysis;
|
|
148
|
-
fleet_cutin: FleetCutinReport<ShellingStyle>[];
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
export interface CompAnalysis {
|
|
152
|
-
day: CompDayAnalysis;
|
|
153
|
-
night: CompNightAnalysis;
|
|
154
|
-
contact: ContactAnalysis;
|
|
155
|
-
anti_air: CompAntiAirAnalysis;
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
export type SpeedGroup = "A" | "B1" | "B2" | "C";
|
|
159
|
-
|
|
160
|
-
export type FhResult<T> = { Ok: T } | { Err: string };
|
|
161
|
-
|
|
162
|
-
export interface MasterShip {
|
|
163
|
-
ship_id: number;
|
|
164
|
-
name: string;
|
|
165
|
-
yomi: string;
|
|
166
|
-
stype: number;
|
|
167
|
-
ctype: number;
|
|
168
|
-
nationality?: number;
|
|
169
|
-
sort_id?: number;
|
|
170
|
-
max_hp: StatInterval;
|
|
171
|
-
firepower: StatInterval;
|
|
172
|
-
armor: StatInterval;
|
|
173
|
-
torpedo: StatInterval;
|
|
174
|
-
evasion: StatInterval;
|
|
175
|
-
anti_air: StatInterval;
|
|
176
|
-
asw: StatInterval;
|
|
177
|
-
los: StatInterval;
|
|
178
|
-
luck: StatInterval;
|
|
179
|
-
torpedo_accuracy?: number;
|
|
180
|
-
basic_evasion_term?: number;
|
|
181
|
-
speed: number;
|
|
182
|
-
range?: number;
|
|
183
|
-
fuel?: number;
|
|
184
|
-
ammo?: number;
|
|
185
|
-
next_id?: number;
|
|
186
|
-
next_level?: number;
|
|
187
|
-
slotnum: number;
|
|
188
|
-
slots: SlotSizeVec;
|
|
189
|
-
stock: GearState[];
|
|
190
|
-
speed_group?: SpeedGroup;
|
|
191
|
-
useful?: boolean;
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
export type StatInterval = [number | null, number | null];
|
|
195
|
-
|
|
196
|
-
export interface MasterIBonuses {
|
|
197
|
-
shelling_power: MasterIBonusRule[];
|
|
198
|
-
shelling_accuracy: MasterIBonusRule[];
|
|
199
|
-
shelling_aerial_power: MasterIBonusRule[];
|
|
200
|
-
torpedo_power: MasterIBonusRule[];
|
|
201
|
-
torpedo_accuracy: MasterIBonusRule[];
|
|
202
|
-
torpedo_evasion: MasterIBonusRule[];
|
|
203
|
-
asw_power: MasterIBonusRule[];
|
|
204
|
-
asw_accuracy: MasterIBonusRule[];
|
|
205
|
-
night_power: MasterIBonusRule[];
|
|
206
|
-
night_aerial_power: MasterIBonusRule[];
|
|
207
|
-
night_accuracy: MasterIBonusRule[];
|
|
208
|
-
defense_power: MasterIBonusRule[];
|
|
209
|
-
contact_selection: MasterIBonusRule[];
|
|
210
|
-
fighter_power: MasterIBonusRule[];
|
|
211
|
-
ship_anti_air: MasterIBonusRule[];
|
|
212
|
-
fleet_anti_air: MasterIBonusRule[];
|
|
213
|
-
elos: MasterIBonusRule[];
|
|
214
|
-
}
|
|
215
|
-
|
|
216
|
-
export interface MasterIBonusRule {
|
|
217
|
-
expr: CompiledEvaler;
|
|
218
|
-
formula: CompiledEvaler;
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
export type ShipAttr =
|
|
222
|
-
| "Unknown"
|
|
223
|
-
| "NightCarrier"
|
|
224
|
-
| "Installation"
|
|
225
|
-
| "RoyalNavy"
|
|
226
|
-
| "Kai2"
|
|
227
|
-
| "TurbineSpeedBonus"
|
|
228
|
-
| "NewModelBoilerSpeedBonus"
|
|
229
|
-
| "Pillbox"
|
|
230
|
-
| "IsolatedIsland"
|
|
231
|
-
| "HarbourSummerPrincess"
|
|
232
|
-
| "SupplyDepot"
|
|
233
|
-
| "NewSupplyDepot"
|
|
234
|
-
| "PtImp"
|
|
235
|
-
| "BattleshipSummerPrincess"
|
|
236
|
-
| "HeavyCruiserSummerPrincess"
|
|
237
|
-
| "AnchorageWaterDemonVacationMode"
|
|
238
|
-
| "FrenchBattleshipPrincess"
|
|
239
|
-
| "DockPrincess"
|
|
240
|
-
| "SummerAircraftCarrierDemon";
|
|
241
|
-
|
|
242
|
-
export interface MoveShipPayload {
|
|
243
|
-
current: [string, string, ShipKey];
|
|
244
|
-
target: [string | null, string, ShipKey];
|
|
245
|
-
}
|
|
246
|
-
|
|
247
|
-
export type GearVecInput = GearInput[];
|
|
248
|
-
|
|
249
|
-
export interface GearInput {
|
|
250
|
-
gear_id: number;
|
|
251
|
-
types: GearTypeIdArray;
|
|
252
|
-
firepower: number;
|
|
253
|
-
torpedo: number;
|
|
254
|
-
anti_air: number;
|
|
255
|
-
armor: number;
|
|
256
|
-
evasion: number;
|
|
257
|
-
asw: number;
|
|
258
|
-
los: number;
|
|
259
|
-
bombing: number;
|
|
260
|
-
accuracy: number;
|
|
261
|
-
range: number;
|
|
262
|
-
radius: number;
|
|
263
|
-
stars: number;
|
|
264
|
-
ace: number;
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
export interface ShipInput {
|
|
268
|
-
ship_id: number;
|
|
269
|
-
ctype: number;
|
|
270
|
-
stype: number;
|
|
271
|
-
yomi: string;
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
export interface EBonuses {
|
|
275
|
-
firepower: number;
|
|
276
|
-
torpedo: number;
|
|
277
|
-
anti_air: number;
|
|
278
|
-
armor: number;
|
|
279
|
-
evasion: number;
|
|
280
|
-
asw: number;
|
|
281
|
-
los: number;
|
|
282
|
-
bombing: number;
|
|
283
|
-
accuracy: number;
|
|
284
|
-
range: number;
|
|
285
|
-
}
|
|
286
|
-
|
|
287
|
-
export interface SimulatorResult {
|
|
288
|
-
items: SimulatorResultItem[];
|
|
289
|
-
sunk_vec: [number, number, number][];
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
export interface SimulatorResultItem {
|
|
293
|
-
id: string;
|
|
294
|
-
fleet_type: FleetType;
|
|
295
|
-
index: number;
|
|
296
|
-
damage_state_map: Record<DamageState, number>;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
export interface ShellingStyle {
|
|
300
|
-
tag: "ShellingStyle";
|
|
301
|
-
attack_type: ShellingType;
|
|
302
|
-
cutin: DayCutinLike | null;
|
|
303
|
-
power_mod: number;
|
|
304
|
-
accuracy_mod: number;
|
|
305
|
-
hits: number;
|
|
306
|
-
}
|
|
307
|
-
|
|
308
|
-
export interface NightAttackStyle {
|
|
309
|
-
tag: "NightAttackStyle";
|
|
310
|
-
attack_type: NightAttackType;
|
|
311
|
-
cutin: NightCutinLike | null;
|
|
312
|
-
power_mod: number;
|
|
313
|
-
accuracy_mod: number;
|
|
314
|
-
hits: number;
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
export interface AswAttackStyle {
|
|
318
|
-
tag: "AswAttackStyle";
|
|
319
|
-
attack_type: AswAttackType;
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
export interface TorpedoAttackStyle {
|
|
323
|
-
tag: "TorpedoAttackStyle";
|
|
324
|
-
attack_type: TorpedoAttackType;
|
|
325
|
-
}
|
|
326
|
-
|
|
327
|
-
export type DayPhaseAttackStyle = ShellingStyle | AswAttackStyle;
|
|
328
|
-
|
|
329
|
-
export type NightPhaseAttackStyle = NightAttackStyle | AswAttackStyle;
|
|
330
|
-
|
|
331
|
-
export interface SupportShellingStyle {
|
|
332
|
-
tag: "SupportShellingStyle";
|
|
333
|
-
attack_type: SupportShellingType;
|
|
334
|
-
}
|
|
335
|
-
|
|
336
|
-
export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
|
|
337
|
-
|
|
338
|
-
export interface ShipMeta {
|
|
339
|
-
id: string;
|
|
340
|
-
ship_id: number;
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
export interface FleetMeta {
|
|
344
|
-
id: string;
|
|
345
|
-
len: number;
|
|
346
|
-
ships: [string, ShipMeta | null][];
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
export interface CompMeta {
|
|
350
|
-
fleets: Record<FleetType, FleetMeta>;
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
export interface OrgState {
|
|
354
|
-
id?: string;
|
|
355
|
-
f1?: FleetState;
|
|
356
|
-
f2?: FleetState;
|
|
357
|
-
f3?: FleetState;
|
|
358
|
-
f4?: FleetState;
|
|
359
|
-
a1?: AirSquadronState;
|
|
360
|
-
a2?: AirSquadronState;
|
|
361
|
-
a3?: AirSquadronState;
|
|
362
|
-
hq_level?: number;
|
|
363
|
-
org_type?: OrgType;
|
|
364
|
-
sortie?: FleetKey;
|
|
365
|
-
route_sup?: FleetKey;
|
|
366
|
-
boss_sup?: FleetKey;
|
|
367
|
-
}
|
|
368
|
-
|
|
369
|
-
export type FleetKey = "f1" | "f2" | "f3" | "f4";
|
|
370
|
-
|
|
371
|
-
export type OrgType =
|
|
372
|
-
| "Single"
|
|
373
|
-
| "CarrierTaskForce"
|
|
374
|
-
| "SurfaceTaskForce"
|
|
375
|
-
| "TransportEscort"
|
|
376
|
-
| "EnemySingle"
|
|
377
|
-
| "EnemyCombined";
|
|
378
|
-
|
|
379
|
-
export interface SlotSizeVecState {
|
|
380
|
-
ss1?: number;
|
|
381
|
-
ss2?: number;
|
|
382
|
-
ss3?: number;
|
|
383
|
-
ss4?: number;
|
|
384
|
-
ss5?: number;
|
|
13
|
+
export interface FleetCutinReport<T> {
|
|
14
|
+
cutin: FleetCutin;
|
|
15
|
+
rate: number | null;
|
|
16
|
+
formation: Formation;
|
|
17
|
+
attacks: FleetCutinAttackReport<T>[];
|
|
385
18
|
}
|
|
386
19
|
|
|
387
|
-
export interface
|
|
388
|
-
|
|
20
|
+
export interface FleetCutinAttackReport<T> extends AttackReport<T> {
|
|
21
|
+
index: number;
|
|
389
22
|
ship_id: number;
|
|
390
|
-
|
|
391
|
-
current_hp?: number;
|
|
392
|
-
morale?: number;
|
|
393
|
-
ammo?: number;
|
|
394
|
-
fuel?: number;
|
|
395
|
-
max_hp_mod?: number;
|
|
396
|
-
firepower_mod?: number;
|
|
397
|
-
torpedo_mod?: number;
|
|
398
|
-
armor_mod?: number;
|
|
399
|
-
anti_air_mod?: number;
|
|
400
|
-
evasion_mod?: number;
|
|
401
|
-
asw_mod?: number;
|
|
402
|
-
los_mod?: number;
|
|
403
|
-
luck_mod?: number;
|
|
404
|
-
day_gunfit_accuracy?: number;
|
|
405
|
-
night_gunfit_accuracy?: number;
|
|
406
|
-
custom_power_mods?: CustomPowerModifiers;
|
|
23
|
+
power_mod: number;
|
|
407
24
|
}
|
|
408
25
|
|
|
409
|
-
export
|
|
410
|
-
|
|
411
|
-
|
|
26
|
+
export interface ActionReport<T> {
|
|
27
|
+
data: Record<string, AttackReport<T>>;
|
|
28
|
+
damage_state_density: Histogram<DamageState, number> | null;
|
|
29
|
+
is_active: boolean;
|
|
30
|
+
}
|
|
412
31
|
|
|
413
|
-
export type
|
|
32
|
+
export type SpeedGroup = "A" | "B1" | "B2" | "C";
|
|
414
33
|
|
|
415
|
-
export type
|
|
34
|
+
export type CompiledEvaler = string;
|
|
416
35
|
|
|
417
|
-
export interface
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
36
|
+
export interface EquippabilityRule {
|
|
37
|
+
ship: CompiledEvaler;
|
|
38
|
+
keys?: string[];
|
|
39
|
+
include?: string;
|
|
40
|
+
exclude?: string;
|
|
422
41
|
}
|
|
423
42
|
|
|
424
|
-
export
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
export type CombinedFormation =
|
|
433
|
-
| "Cruising1"
|
|
434
|
-
| "Cruising2"
|
|
435
|
-
| "Cruising3"
|
|
436
|
-
| "Cruising4";
|
|
437
|
-
|
|
438
|
-
export type Formation = SingleFormation | CombinedFormation;
|
|
43
|
+
export interface MasterEquippability {
|
|
44
|
+
equip_stype: MstStype[];
|
|
45
|
+
equip_exslot: number[];
|
|
46
|
+
equip_ship: Record<number, MstEquipShip>;
|
|
47
|
+
equip_exslot_ship: Record<number, MstEquipExslotShip>;
|
|
48
|
+
rules: EquippabilityRule[];
|
|
49
|
+
}
|
|
439
50
|
|
|
440
|
-
export
|
|
51
|
+
export interface MstEquipExslotShip {
|
|
52
|
+
api_ctypes: Record<number, number> | null;
|
|
53
|
+
api_ship_ids: Record<number, number> | null;
|
|
54
|
+
api_stypes: Record<number, number> | null;
|
|
55
|
+
}
|
|
441
56
|
|
|
442
|
-
export type
|
|
57
|
+
export type MstEquipShip = Record<number, MstEquipShipValue>;
|
|
443
58
|
|
|
444
|
-
export type
|
|
445
|
-
| "None"
|
|
446
|
-
| "SoftSkinned"
|
|
447
|
-
| "Pillbox"
|
|
448
|
-
| "IsolatedIsland"
|
|
449
|
-
| "SupplyDepot"
|
|
450
|
-
| "NewSupplyDepot"
|
|
451
|
-
| "HarbourSummerPrincess"
|
|
452
|
-
| "PtImp"
|
|
453
|
-
| "BattleshipSummerPrincess"
|
|
454
|
-
| "HeavyCruiserSummerPrincess"
|
|
455
|
-
| "FrenchBattleshipPrincess"
|
|
456
|
-
| "AnchorageWaterDemonVacationMode"
|
|
457
|
-
| "DockPrincess"
|
|
458
|
-
| "SummerAircraftCarrierDemon";
|
|
59
|
+
export type MstEquipShipValue = null | number[];
|
|
459
60
|
|
|
460
|
-
export interface
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
total: number;
|
|
61
|
+
export interface MstStype {
|
|
62
|
+
api_id: number;
|
|
63
|
+
api_equip_type: Record<number, number>;
|
|
464
64
|
}
|
|
465
65
|
|
|
466
|
-
export
|
|
467
|
-
accuracy_term: number;
|
|
468
|
-
evasion_term: number;
|
|
469
|
-
target_morale_mod: number;
|
|
470
|
-
critical_rate_constant: number;
|
|
471
|
-
critical_percentage_bonus: number;
|
|
472
|
-
hit_percentage_bonus: number;
|
|
473
|
-
}
|
|
66
|
+
export type Histogram<K extends keyof any, V> = Partial<Record<K, V>>;
|
|
474
67
|
|
|
475
|
-
export
|
|
476
|
-
precap: number;
|
|
477
|
-
is_capped: boolean;
|
|
478
|
-
capped: number;
|
|
479
|
-
normal: number;
|
|
480
|
-
critical: number;
|
|
481
|
-
armor_penetration: number;
|
|
482
|
-
remaining_ammo_mod: number;
|
|
483
|
-
}
|
|
68
|
+
export type FhResult<T> = { Ok: T } | { Err: string };
|
|
484
69
|
|
|
485
|
-
export interface
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
armor_penetration: number;
|
|
495
|
-
remaining_ammo_mod: number;
|
|
496
|
-
balloon_mod: number;
|
|
497
|
-
special_enemy_mods: SpecialEnemyModifiers;
|
|
498
|
-
historical_mod: AttackPowerModifier;
|
|
499
|
-
custom_mods: CustomPowerModifiers;
|
|
70
|
+
export interface AttackReport<T> {
|
|
71
|
+
style: T;
|
|
72
|
+
proc_rate: number | null;
|
|
73
|
+
attack_power: AttackPower | null;
|
|
74
|
+
attack_power_params: AttackPowerParams | null;
|
|
75
|
+
hits: number;
|
|
76
|
+
hit_rate: HitRate | null;
|
|
77
|
+
hit_rate_params: HitRateParams | null;
|
|
78
|
+
damage: DamageReport | null;
|
|
500
79
|
}
|
|
501
80
|
|
|
502
81
|
export interface CompAntiAirAnalysis {
|
|
@@ -517,6 +96,8 @@ export interface AntiAirReport {
|
|
|
517
96
|
anti_air_propellant_barrage_chance: number | null;
|
|
518
97
|
}
|
|
519
98
|
|
|
99
|
+
export type AirWaveType = "Jet" | "LandBase" | "Carrier";
|
|
100
|
+
|
|
520
101
|
export interface AttackPowerModifier {
|
|
521
102
|
a?: number;
|
|
522
103
|
b?: number;
|
|
@@ -619,194 +200,297 @@ export interface BattleDefinitions {
|
|
|
619
200
|
|
|
620
201
|
export type ContactRank = "Rank1" | "Rank2" | "Rank3";
|
|
621
202
|
|
|
622
|
-
export
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
| "MainSec"
|
|
629
|
-
| "DoubleAttack"
|
|
630
|
-
| "FBA"
|
|
631
|
-
| "BBA"
|
|
632
|
-
| "BA";
|
|
203
|
+
export interface GearState {
|
|
204
|
+
id?: string;
|
|
205
|
+
gear_id: number;
|
|
206
|
+
exp?: number;
|
|
207
|
+
stars?: number;
|
|
208
|
+
}
|
|
633
209
|
|
|
634
|
-
export
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
| "NightZuiun"
|
|
643
|
-
| "DoubleAttack"
|
|
644
|
-
| "TorpTorpMain"
|
|
645
|
-
| "TorpTorpTorp"
|
|
646
|
-
| "MainMainSec"
|
|
647
|
-
| "MainMainMain"
|
|
648
|
-
| "SubTorpTorp"
|
|
649
|
-
| "SubRadarTorp"
|
|
650
|
-
| "Cvci1_25"
|
|
651
|
-
| "Cvci1_20"
|
|
652
|
-
| "Cvci1_18"
|
|
653
|
-
| "Photobomber";
|
|
210
|
+
export interface GearVecState {
|
|
211
|
+
g1?: GearState;
|
|
212
|
+
g2?: GearState;
|
|
213
|
+
g3?: GearState;
|
|
214
|
+
g4?: GearState;
|
|
215
|
+
g5?: GearState;
|
|
216
|
+
gx?: GearState;
|
|
217
|
+
}
|
|
654
218
|
|
|
655
|
-
export
|
|
656
|
-
|
|
657
|
-
|
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
219
|
+
export interface MoveShipPayload {
|
|
220
|
+
current: [string, string, ShipKey];
|
|
221
|
+
target: [string | null, string, ShipKey];
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
export type GearVecInput = GearInput[];
|
|
225
|
+
|
|
226
|
+
export interface GearInput {
|
|
227
|
+
gear_id: number;
|
|
228
|
+
types: GearTypeIdArray;
|
|
229
|
+
firepower: number;
|
|
230
|
+
torpedo: number;
|
|
231
|
+
anti_air: number;
|
|
232
|
+
armor: number;
|
|
233
|
+
evasion: number;
|
|
234
|
+
asw: number;
|
|
235
|
+
los: number;
|
|
236
|
+
bombing: number;
|
|
237
|
+
accuracy: number;
|
|
238
|
+
range: number;
|
|
239
|
+
radius: number;
|
|
240
|
+
stars: number;
|
|
241
|
+
ace: number;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
export interface ShipInput {
|
|
245
|
+
ship_id: number;
|
|
246
|
+
ctype: number;
|
|
247
|
+
stype: number;
|
|
248
|
+
yomi: string;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
export interface EBonuses {
|
|
252
|
+
firepower: number;
|
|
253
|
+
torpedo: number;
|
|
254
|
+
anti_air: number;
|
|
255
|
+
armor: number;
|
|
256
|
+
evasion: number;
|
|
257
|
+
asw: number;
|
|
258
|
+
los: number;
|
|
259
|
+
bombing: number;
|
|
260
|
+
accuracy: number;
|
|
261
|
+
range: number;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
export interface SimulatorResult {
|
|
265
|
+
items: SimulatorResultItem[];
|
|
266
|
+
sunk_vec: [number, number, number][];
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
export interface SimulatorResultItem {
|
|
270
|
+
id: string;
|
|
271
|
+
fleet_type: FleetType;
|
|
272
|
+
index: number;
|
|
273
|
+
damage_state_map: Record<DamageState, number>;
|
|
274
|
+
}
|
|
662
275
|
|
|
663
|
-
export
|
|
276
|
+
export interface HitRate {
|
|
277
|
+
normal: number;
|
|
278
|
+
critical: number;
|
|
279
|
+
total: number;
|
|
280
|
+
}
|
|
664
281
|
|
|
665
|
-
export
|
|
282
|
+
export interface HitRateParams {
|
|
283
|
+
accuracy_term: number;
|
|
284
|
+
evasion_term: number;
|
|
285
|
+
target_morale_mod: number;
|
|
286
|
+
critical_rate_constant: number;
|
|
287
|
+
critical_percentage_bonus: number;
|
|
288
|
+
hit_percentage_bonus: number;
|
|
289
|
+
}
|
|
666
290
|
|
|
667
|
-
export interface
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
291
|
+
export interface AttackAnalyzerShipConfig
|
|
292
|
+
extends ShipConditions,
|
|
293
|
+
NightFleetConditions {
|
|
294
|
+
balloons?: number;
|
|
295
|
+
fleet_los_mod?: number | null;
|
|
672
296
|
}
|
|
673
297
|
|
|
674
|
-
export
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
g5?: GearState;
|
|
680
|
-
gx?: GearState;
|
|
298
|
+
export type AirSquadronMode = "Sortie" | "AirDefense";
|
|
299
|
+
|
|
300
|
+
export interface AirSquadronState extends GearVecState, SlotSizeVecState {
|
|
301
|
+
id?: string;
|
|
302
|
+
mode?: AirSquadronMode;
|
|
681
303
|
}
|
|
682
304
|
|
|
683
|
-
export interface
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
305
|
+
export interface ShellingStyle {
|
|
306
|
+
tag: "ShellingStyle";
|
|
307
|
+
attack_type: ShellingType;
|
|
308
|
+
cutin: DayCutinLike | null;
|
|
309
|
+
power_mod: number;
|
|
310
|
+
accuracy_mod: number;
|
|
311
|
+
hits: number;
|
|
689
312
|
}
|
|
690
313
|
|
|
691
|
-
export interface
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
314
|
+
export interface NightAttackStyle {
|
|
315
|
+
tag: "NightAttackStyle";
|
|
316
|
+
attack_type: NightAttackType;
|
|
317
|
+
cutin: NightCutinLike | null;
|
|
318
|
+
power_mod: number;
|
|
319
|
+
accuracy_mod: number;
|
|
696
320
|
hits: number;
|
|
697
|
-
hit_rate: HitRate | null;
|
|
698
|
-
hit_rate_params: HitRateParams | null;
|
|
699
|
-
damage: DamageReport | null;
|
|
700
321
|
}
|
|
701
322
|
|
|
702
|
-
export interface
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
is_active: boolean;
|
|
323
|
+
export interface AswAttackStyle {
|
|
324
|
+
tag: "AswAttackStyle";
|
|
325
|
+
attack_type: AswAttackType;
|
|
706
326
|
}
|
|
707
327
|
|
|
708
|
-
export interface
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
s1?: ShipState;
|
|
712
|
-
s2?: ShipState;
|
|
713
|
-
s3?: ShipState;
|
|
714
|
-
s4?: ShipState;
|
|
715
|
-
s5?: ShipState;
|
|
716
|
-
s6?: ShipState;
|
|
717
|
-
s7?: ShipState;
|
|
328
|
+
export interface TorpedoAttackStyle {
|
|
329
|
+
tag: "TorpedoAttackStyle";
|
|
330
|
+
attack_type: TorpedoAttackType;
|
|
718
331
|
}
|
|
719
332
|
|
|
720
|
-
export type
|
|
333
|
+
export type DayPhaseAttackStyle = ShellingStyle | AswAttackStyle;
|
|
721
334
|
|
|
722
|
-
export
|
|
723
|
-
map?: number;
|
|
724
|
-
node?: NodeId;
|
|
725
|
-
phase?: number;
|
|
726
|
-
debuff?: boolean;
|
|
727
|
-
disable_historical_mod?: boolean;
|
|
728
|
-
landing_battle?: boolean;
|
|
729
|
-
}
|
|
335
|
+
export type NightPhaseAttackStyle = NightAttackStyle | AswAttackStyle;
|
|
730
336
|
|
|
731
|
-
export interface
|
|
732
|
-
|
|
337
|
+
export interface SupportShellingStyle {
|
|
338
|
+
tag: "SupportShellingStyle";
|
|
339
|
+
attack_type: SupportShellingType;
|
|
733
340
|
}
|
|
734
341
|
|
|
735
|
-
export
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
342
|
+
export type DamageState = "Normal" | "Shouha" | "Chuuha" | "Taiha" | "Sunk";
|
|
343
|
+
|
|
344
|
+
export type FleetType = "Main" | "Escort" | "RouteSup" | "BossSup";
|
|
345
|
+
|
|
346
|
+
export interface ShipMeta {
|
|
347
|
+
id: string;
|
|
348
|
+
ship_id: number;
|
|
741
349
|
}
|
|
742
350
|
|
|
743
|
-
export interface
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
night_fleet_cutin: FleetCutinReport<NightAttackStyle>[];
|
|
351
|
+
export interface FleetMeta {
|
|
352
|
+
id: string;
|
|
353
|
+
len: number;
|
|
354
|
+
ships: [string, ShipMeta | null][];
|
|
748
355
|
}
|
|
749
356
|
|
|
750
|
-
export interface
|
|
751
|
-
|
|
752
|
-
rate: number | null;
|
|
753
|
-
formation: Formation;
|
|
754
|
-
attacks: FleetCutinAttackReport<T>[];
|
|
357
|
+
export interface CompMeta {
|
|
358
|
+
fleets: Record<FleetType, FleetMeta>;
|
|
755
359
|
}
|
|
756
360
|
|
|
757
|
-
export interface
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
361
|
+
export interface OrgState {
|
|
362
|
+
id?: string;
|
|
363
|
+
f1?: FleetState;
|
|
364
|
+
f2?: FleetState;
|
|
365
|
+
f3?: FleetState;
|
|
366
|
+
f4?: FleetState;
|
|
367
|
+
a1?: AirSquadronState;
|
|
368
|
+
a2?: AirSquadronState;
|
|
369
|
+
a3?: AirSquadronState;
|
|
370
|
+
hq_level?: number;
|
|
371
|
+
org_type?: OrgType;
|
|
372
|
+
sortie?: FleetKey;
|
|
373
|
+
route_sup?: FleetKey;
|
|
374
|
+
boss_sup?: FleetKey;
|
|
761
375
|
}
|
|
762
376
|
|
|
763
|
-
export
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
opening_asw: ActionReport<AswAttackStyle>;
|
|
772
|
-
support_shelling: ActionReport<SupportShellingStyle>;
|
|
377
|
+
export type FleetKey = "f1" | "f2" | "f3" | "f4";
|
|
378
|
+
|
|
379
|
+
export interface SlotSizeVecState {
|
|
380
|
+
ss1?: number;
|
|
381
|
+
ss2?: number;
|
|
382
|
+
ss3?: number;
|
|
383
|
+
ss4?: number;
|
|
384
|
+
ss5?: number;
|
|
773
385
|
}
|
|
774
386
|
|
|
775
|
-
export
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
387
|
+
export interface ShipState extends GearVecState, SlotSizeVecState {
|
|
388
|
+
id?: string;
|
|
389
|
+
ship_id: number;
|
|
390
|
+
level?: number;
|
|
391
|
+
current_hp?: number;
|
|
392
|
+
morale?: number;
|
|
393
|
+
ammo?: number;
|
|
394
|
+
fuel?: number;
|
|
395
|
+
max_hp_mod?: number;
|
|
396
|
+
firepower_mod?: number;
|
|
397
|
+
torpedo_mod?: number;
|
|
398
|
+
armor_mod?: number;
|
|
399
|
+
anti_air_mod?: number;
|
|
400
|
+
evasion_mod?: number;
|
|
401
|
+
asw_mod?: number;
|
|
402
|
+
los_mod?: number;
|
|
403
|
+
luck_mod?: number;
|
|
404
|
+
day_gunfit_accuracy?: number;
|
|
405
|
+
night_gunfit_accuracy?: number;
|
|
406
|
+
custom_power_mods?: CustomPowerModifiers;
|
|
407
|
+
}
|
|
781
408
|
|
|
782
|
-
export type
|
|
409
|
+
export type ShipKey = "s1" | "s2" | "s3" | "s4" | "s5" | "s6" | "s7";
|
|
783
410
|
|
|
784
|
-
export type
|
|
411
|
+
export type Side = "Player" | "Enemy";
|
|
785
412
|
|
|
786
|
-
export type
|
|
413
|
+
export type Align = "Left" | "Right";
|
|
787
414
|
|
|
788
|
-
export
|
|
415
|
+
export interface MasterData extends MasterBattleDefinitions {
|
|
416
|
+
created_at: number;
|
|
417
|
+
gears: MasterGear[];
|
|
418
|
+
gear_attrs: MasterAttrRule<GearAttr>[];
|
|
419
|
+
ships: MasterShip[];
|
|
420
|
+
ship_attrs: MasterAttrRule<ShipAttr>[];
|
|
421
|
+
ibonuses: MasterIBonuses;
|
|
422
|
+
equippability: MasterEquippability;
|
|
423
|
+
}
|
|
789
424
|
|
|
790
|
-
export
|
|
425
|
+
export interface NationalityDef {
|
|
426
|
+
id: number;
|
|
427
|
+
ctypes: number[];
|
|
428
|
+
}
|
|
791
429
|
|
|
792
|
-
export
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
| { t: "SupportShelling"; c: SupportShellingType };
|
|
430
|
+
export interface MasterAttrRule<T> {
|
|
431
|
+
tag: T;
|
|
432
|
+
name: string;
|
|
433
|
+
expr: CompiledEvaler;
|
|
434
|
+
}
|
|
798
435
|
|
|
799
|
-
export
|
|
800
|
-
|
|
801
|
-
|
|
436
|
+
export interface MasterShip {
|
|
437
|
+
ship_id: number;
|
|
438
|
+
name: string;
|
|
439
|
+
yomi: string;
|
|
440
|
+
stype: number;
|
|
441
|
+
ctype: number;
|
|
442
|
+
nationality?: number;
|
|
443
|
+
sort_id?: number;
|
|
444
|
+
max_hp: StatInterval;
|
|
445
|
+
firepower: StatInterval;
|
|
446
|
+
armor: StatInterval;
|
|
447
|
+
torpedo: StatInterval;
|
|
448
|
+
evasion: StatInterval;
|
|
449
|
+
anti_air: StatInterval;
|
|
450
|
+
asw: StatInterval;
|
|
451
|
+
los: StatInterval;
|
|
452
|
+
luck: StatInterval;
|
|
453
|
+
torpedo_accuracy?: number;
|
|
454
|
+
basic_evasion_term?: number;
|
|
455
|
+
speed: number;
|
|
456
|
+
range?: number;
|
|
457
|
+
fuel?: number;
|
|
458
|
+
ammo?: number;
|
|
459
|
+
next_id?: number;
|
|
460
|
+
next_level?: number;
|
|
461
|
+
slotnum: number;
|
|
462
|
+
slots: SlotSizeVec;
|
|
463
|
+
stock: GearState[];
|
|
464
|
+
speed_group?: SpeedGroup;
|
|
465
|
+
useful?: boolean;
|
|
466
|
+
}
|
|
802
467
|
|
|
803
|
-
export type
|
|
804
|
-
| { t: "Night"; c: NightAttackType }
|
|
805
|
-
| { t: "Asw"; c: AswAttackType };
|
|
468
|
+
export type StatInterval = [number | null, number | null];
|
|
806
469
|
|
|
807
|
-
export
|
|
470
|
+
export interface MasterIBonuses {
|
|
471
|
+
shelling_power: MasterIBonusRule[];
|
|
472
|
+
shelling_accuracy: MasterIBonusRule[];
|
|
473
|
+
shelling_aerial_power: MasterIBonusRule[];
|
|
474
|
+
torpedo_power: MasterIBonusRule[];
|
|
475
|
+
torpedo_accuracy: MasterIBonusRule[];
|
|
476
|
+
torpedo_evasion: MasterIBonusRule[];
|
|
477
|
+
asw_power: MasterIBonusRule[];
|
|
478
|
+
asw_accuracy: MasterIBonusRule[];
|
|
479
|
+
night_power: MasterIBonusRule[];
|
|
480
|
+
night_aerial_power: MasterIBonusRule[];
|
|
481
|
+
night_accuracy: MasterIBonusRule[];
|
|
482
|
+
defense_power: MasterIBonusRule[];
|
|
483
|
+
contact_selection: MasterIBonusRule[];
|
|
484
|
+
fighter_power: MasterIBonusRule[];
|
|
485
|
+
ship_anti_air: MasterIBonusRule[];
|
|
486
|
+
fleet_anti_air: MasterIBonusRule[];
|
|
487
|
+
elos: MasterIBonusRule[];
|
|
488
|
+
}
|
|
808
489
|
|
|
809
|
-
export
|
|
490
|
+
export interface MasterIBonusRule {
|
|
491
|
+
expr: CompiledEvaler;
|
|
492
|
+
formula: CompiledEvaler;
|
|
493
|
+
}
|
|
810
494
|
|
|
811
495
|
export type GearType =
|
|
812
496
|
| "Unknown"
|
|
@@ -872,19 +556,311 @@ export type GearType =
|
|
|
872
556
|
| "CbRecon2"
|
|
873
557
|
| "SecondaryGun2";
|
|
874
558
|
|
|
875
|
-
export type GearCategory =
|
|
876
|
-
| "Fighter"
|
|
877
|
-
| "Bomber"
|
|
878
|
-
| "Recon"
|
|
559
|
+
export type GearCategory =
|
|
560
|
+
| "Fighter"
|
|
561
|
+
| "Bomber"
|
|
562
|
+
| "Recon"
|
|
563
|
+
| "MainGun"
|
|
564
|
+
| "Secondary"
|
|
565
|
+
| "Torpedo"
|
|
566
|
+
| "AntiSub"
|
|
567
|
+
| "Radar"
|
|
568
|
+
| "Landing"
|
|
569
|
+
| "Ration"
|
|
570
|
+
| "LandBased"
|
|
571
|
+
| "Misc";
|
|
572
|
+
|
|
573
|
+
export type ShipAttr =
|
|
574
|
+
| "Unknown"
|
|
575
|
+
| "NightCarrier"
|
|
576
|
+
| "Installation"
|
|
577
|
+
| "RoyalNavy"
|
|
578
|
+
| "Kai2"
|
|
579
|
+
| "TurbineSpeedBonus"
|
|
580
|
+
| "NewModelBoilerSpeedBonus"
|
|
581
|
+
| "Pillbox"
|
|
582
|
+
| "IsolatedIsland"
|
|
583
|
+
| "HarbourSummerPrincess"
|
|
584
|
+
| "SupplyDepot"
|
|
585
|
+
| "NewSupplyDepot"
|
|
586
|
+
| "PtImp"
|
|
587
|
+
| "BattleshipSummerPrincess"
|
|
588
|
+
| "HeavyCruiserSummerPrincess"
|
|
589
|
+
| "AnchorageWaterDemonVacationMode"
|
|
590
|
+
| "FrenchBattleshipPrincess"
|
|
591
|
+
| "DockPrincess"
|
|
592
|
+
| "SummerAircraftCarrierDemon";
|
|
593
|
+
|
|
594
|
+
export type ShipCategory =
|
|
595
|
+
| "Battleship"
|
|
596
|
+
| "AircraftCarrier"
|
|
597
|
+
| "HeavyCruiser"
|
|
598
|
+
| "LightCruiser"
|
|
599
|
+
| "Destroyer"
|
|
600
|
+
| "CoastalDefenseShip"
|
|
601
|
+
| "Submarine"
|
|
602
|
+
| "AuxiliaryShip";
|
|
603
|
+
|
|
604
|
+
export type ShipType =
|
|
605
|
+
| "Unknown"
|
|
606
|
+
| "DE"
|
|
607
|
+
| "DD"
|
|
608
|
+
| "CL"
|
|
609
|
+
| "CLT"
|
|
610
|
+
| "CA"
|
|
611
|
+
| "CAV"
|
|
612
|
+
| "CVL"
|
|
613
|
+
| "FBB"
|
|
614
|
+
| "BB"
|
|
615
|
+
| "BBV"
|
|
616
|
+
| "CV"
|
|
617
|
+
| "XBB"
|
|
618
|
+
| "SS"
|
|
619
|
+
| "SSV"
|
|
620
|
+
| "AP"
|
|
621
|
+
| "AV"
|
|
622
|
+
| "LHA"
|
|
623
|
+
| "CVB"
|
|
624
|
+
| "AR"
|
|
625
|
+
| "AS"
|
|
626
|
+
| "CT"
|
|
627
|
+
| "AO";
|
|
628
|
+
|
|
629
|
+
export type GearTypeIdArray = [number, number, number, number, number];
|
|
630
|
+
|
|
631
|
+
export interface SupportShellingSimulatorParams {
|
|
632
|
+
attacker_formation?: Formation;
|
|
633
|
+
target_formation?: Formation;
|
|
634
|
+
engagement: Engagement;
|
|
635
|
+
node_state: NodeState;
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
export interface ShipAnalyzerConfig {
|
|
639
|
+
air_state?: AirState;
|
|
640
|
+
engagement?: Engagement;
|
|
641
|
+
left?: AttackAnalyzerShipConfig;
|
|
642
|
+
right?: AttackAnalyzerShipConfig;
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
export type Engagement = "GreenT" | "Parallel" | "HeadOn" | "RedT";
|
|
646
|
+
|
|
647
|
+
export type SingleFormation =
|
|
648
|
+
| "LineAhead"
|
|
649
|
+
| "DoubleLine"
|
|
650
|
+
| "Diamond"
|
|
651
|
+
| "Echelon"
|
|
652
|
+
| "LineAbreast"
|
|
653
|
+
| "Vanguard";
|
|
654
|
+
|
|
655
|
+
export type CombinedFormation =
|
|
656
|
+
| "Cruising1"
|
|
657
|
+
| "Cruising2"
|
|
658
|
+
| "Cruising3"
|
|
659
|
+
| "Cruising4";
|
|
660
|
+
|
|
661
|
+
export type Formation = SingleFormation | CombinedFormation;
|
|
662
|
+
|
|
663
|
+
export type Role = "Main" | "Escort";
|
|
664
|
+
|
|
665
|
+
export interface CompAnalyzerConfig {
|
|
666
|
+
engagement: Engagement;
|
|
667
|
+
formation: Formation;
|
|
668
|
+
anti_air_cutin: number | null;
|
|
669
|
+
ship_anti_air_resist: number;
|
|
670
|
+
fleet_anti_air_resist: number;
|
|
671
|
+
left_night_fleet_conditions: NightFleetConditions;
|
|
672
|
+
right_night_fleet_conditions: NightFleetConditions;
|
|
673
|
+
}
|
|
674
|
+
|
|
675
|
+
export interface CompNightAnalysis {
|
|
676
|
+
night_cutin: CompNightCutinAnalysis;
|
|
677
|
+
fleet_cutin: FleetCutinReport<NightAttackStyle>[];
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
export interface CompDayAnalysis {
|
|
681
|
+
day_cutin: CompDayCutinAnalysis;
|
|
682
|
+
fleet_cutin: FleetCutinReport<ShellingStyle>[];
|
|
683
|
+
}
|
|
684
|
+
|
|
685
|
+
export interface CompAnalysis {
|
|
686
|
+
day: CompDayAnalysis;
|
|
687
|
+
night: CompNightAnalysis;
|
|
688
|
+
contact: ContactAnalysis;
|
|
689
|
+
anti_air: CompAntiAirAnalysis;
|
|
690
|
+
}
|
|
691
|
+
|
|
692
|
+
export interface MasterGear {
|
|
693
|
+
gear_id: number;
|
|
694
|
+
name: string;
|
|
695
|
+
types: GearTypeIdArray;
|
|
696
|
+
special_type?: number;
|
|
697
|
+
max_hp?: number;
|
|
698
|
+
firepower?: number;
|
|
699
|
+
armor?: number;
|
|
700
|
+
torpedo?: number;
|
|
701
|
+
anti_air?: number;
|
|
702
|
+
speed?: number;
|
|
703
|
+
bombing?: number;
|
|
704
|
+
asw?: number;
|
|
705
|
+
los?: number;
|
|
706
|
+
luck?: number;
|
|
707
|
+
accuracy?: number;
|
|
708
|
+
evasion?: number;
|
|
709
|
+
range?: number;
|
|
710
|
+
radius?: number;
|
|
711
|
+
cost?: number;
|
|
712
|
+
improvable?: boolean;
|
|
713
|
+
ship_anti_air_resist?: number;
|
|
714
|
+
fleet_anti_air_resist?: number;
|
|
715
|
+
historical_aircraft_group?: number;
|
|
716
|
+
}
|
|
717
|
+
|
|
718
|
+
export type AirState =
|
|
719
|
+
| "AirSupremacy"
|
|
720
|
+
| "AirSuperiority"
|
|
721
|
+
| "AirParity"
|
|
722
|
+
| "AirDenial"
|
|
723
|
+
| "AirIncapability";
|
|
724
|
+
|
|
725
|
+
export type AirStateRank = "Rank0" | "Rank1" | "Rank2" | "Rank3";
|
|
726
|
+
|
|
727
|
+
export interface BattleConditions {
|
|
728
|
+
org_type: OrgType;
|
|
729
|
+
role: Role;
|
|
730
|
+
ship_index: number;
|
|
731
|
+
fleet_len: number;
|
|
732
|
+
formation: Formation;
|
|
733
|
+
fleet_los_mod: number | null;
|
|
734
|
+
night_conditions: NightFleetConditions;
|
|
735
|
+
}
|
|
736
|
+
|
|
737
|
+
export interface NightConditions {
|
|
738
|
+
player?: NightFleetConditions;
|
|
739
|
+
enemy?: NightFleetConditions;
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
export interface NightFleetConditions {
|
|
743
|
+
night_contact_rank?: ContactRank | null;
|
|
744
|
+
starshell_index?: number | null;
|
|
745
|
+
searchlight_index?: number | null;
|
|
746
|
+
activates_large_searchlight?: boolean;
|
|
747
|
+
}
|
|
748
|
+
|
|
749
|
+
export type OrgType =
|
|
750
|
+
| "Single"
|
|
751
|
+
| "CarrierTaskForce"
|
|
752
|
+
| "SurfaceTaskForce"
|
|
753
|
+
| "TransportEscort"
|
|
754
|
+
| "EnemySingle"
|
|
755
|
+
| "EnemyCombined";
|
|
756
|
+
|
|
757
|
+
export interface ShipPosition {
|
|
758
|
+
org_type?: OrgType;
|
|
759
|
+
fleet_type?: FleetType;
|
|
760
|
+
fleet_len?: number;
|
|
761
|
+
index?: number;
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
export interface AttackPower {
|
|
765
|
+
precap: number;
|
|
766
|
+
is_capped: boolean;
|
|
767
|
+
capped: number;
|
|
768
|
+
normal: number;
|
|
769
|
+
critical: number;
|
|
770
|
+
armor_penetration: number;
|
|
771
|
+
remaining_ammo_mod: number;
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
export interface AttackPowerParams {
|
|
775
|
+
is_cutin: boolean;
|
|
776
|
+
basic: number;
|
|
777
|
+
cap: number;
|
|
778
|
+
precap_mod: AttackPowerModifier;
|
|
779
|
+
postcap_mod: AttackPowerModifier;
|
|
780
|
+
ap_shell_mod: number | null;
|
|
781
|
+
aerial_power: number | null;
|
|
782
|
+
proficiency_critical_mod: number;
|
|
783
|
+
armor_penetration: number;
|
|
784
|
+
remaining_ammo_mod: number;
|
|
785
|
+
balloon_mod: number;
|
|
786
|
+
special_enemy_mods: SpecialEnemyModifiers;
|
|
787
|
+
historical_mod: AttackPowerModifier;
|
|
788
|
+
custom_mods: CustomPowerModifiers;
|
|
789
|
+
}
|
|
790
|
+
|
|
791
|
+
export interface NodeAttackAnalyzerShipConfig extends NightFleetConditions {
|
|
792
|
+
formation?: Formation;
|
|
793
|
+
}
|
|
794
|
+
|
|
795
|
+
export interface NodeAttackAnalyzerConfig {
|
|
796
|
+
air_state?: AirState;
|
|
797
|
+
engagement?: Engagement;
|
|
798
|
+
node_state?: NodeState;
|
|
799
|
+
left?: NodeAttackAnalyzerShipConfig;
|
|
800
|
+
right?: NodeAttackAnalyzerShipConfig;
|
|
801
|
+
}
|
|
802
|
+
|
|
803
|
+
export interface NodeAttackAnalysis {
|
|
804
|
+
left: AttackAnalysis;
|
|
805
|
+
right: AttackAnalysis;
|
|
806
|
+
shelling_fleet_cutin: FleetCutinReport<ShellingStyle>[];
|
|
807
|
+
night_fleet_cutin: FleetCutinReport<NightAttackStyle>[];
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
export interface AttackAnalysis {
|
|
811
|
+
attacker_is_player: boolean;
|
|
812
|
+
attacker_ship_id: number;
|
|
813
|
+
target_ship_id: number;
|
|
814
|
+
historical_params: HistoricalParams;
|
|
815
|
+
day: ActionReport<DayPhaseAttackStyle>;
|
|
816
|
+
night: ActionReport<NightPhaseAttackStyle>;
|
|
817
|
+
closing_torpedo: ActionReport<TorpedoAttackStyle>;
|
|
818
|
+
opening_asw: ActionReport<AswAttackStyle>;
|
|
819
|
+
support_shelling: ActionReport<SupportShellingStyle>;
|
|
820
|
+
}
|
|
821
|
+
|
|
822
|
+
export interface FleetState {
|
|
823
|
+
id?: string;
|
|
824
|
+
len?: number;
|
|
825
|
+
s1?: ShipState;
|
|
826
|
+
s2?: ShipState;
|
|
827
|
+
s3?: ShipState;
|
|
828
|
+
s4?: ShipState;
|
|
829
|
+
s5?: ShipState;
|
|
830
|
+
s6?: ShipState;
|
|
831
|
+
s7?: ShipState;
|
|
832
|
+
}
|
|
833
|
+
|
|
834
|
+
export type GearAttr =
|
|
835
|
+
| "Unknown"
|
|
836
|
+
| "HighAngleMount"
|
|
837
|
+
| "NightFighter"
|
|
838
|
+
| "NightAttacker"
|
|
839
|
+
| "HeavyBomber"
|
|
840
|
+
| "NightRecon"
|
|
879
841
|
| "MainGun"
|
|
880
|
-
| "Secondary"
|
|
881
|
-
| "Torpedo"
|
|
882
|
-
| "AntiSub"
|
|
883
842
|
| "Radar"
|
|
884
|
-
| "
|
|
885
|
-
| "
|
|
886
|
-
| "
|
|
887
|
-
| "
|
|
843
|
+
| "SurfaceRadar"
|
|
844
|
+
| "AirRadar"
|
|
845
|
+
| "DepthChargeProjector"
|
|
846
|
+
| "SynergisticDepthCharge"
|
|
847
|
+
| "AntiSubMortar"
|
|
848
|
+
| "AntiSubWeapon"
|
|
849
|
+
| "ApDepthCharge"
|
|
850
|
+
| "AntiSubAircraft"
|
|
851
|
+
| "LateModelBowTorpedo"
|
|
852
|
+
| "Seaplane"
|
|
853
|
+
| "CbAircraft"
|
|
854
|
+
| "LbAircraft"
|
|
855
|
+
| "JetAircraft"
|
|
856
|
+
| "Fighter"
|
|
857
|
+
| "Recon"
|
|
858
|
+
| "ObservationSeaplane"
|
|
859
|
+
| "CbFighterBomber"
|
|
860
|
+
| "AntiInstDiveBomber"
|
|
861
|
+
| "CbSwordfish"
|
|
862
|
+
| "SemiNightPlane"
|
|
863
|
+
| "HighAltitudeInterceptor";
|
|
888
864
|
|
|
889
865
|
export interface ShipConditions extends ShipPosition {
|
|
890
866
|
formation?: Formation;
|
|
@@ -961,84 +937,107 @@ export interface DayContactChance {
|
|
|
961
937
|
total: number;
|
|
962
938
|
}
|
|
963
939
|
|
|
964
|
-
export type
|
|
940
|
+
export type AswAttackType = "DepthCharge" | "Aerial";
|
|
965
941
|
|
|
966
|
-
export type
|
|
942
|
+
export type ShellingType = "Normal" | "Aerial";
|
|
967
943
|
|
|
968
|
-
export type
|
|
969
|
-
| "Battleship"
|
|
970
|
-
| "AircraftCarrier"
|
|
971
|
-
| "HeavyCruiser"
|
|
972
|
-
| "LightCruiser"
|
|
973
|
-
| "Destroyer"
|
|
974
|
-
| "CoastalDefenseShip"
|
|
975
|
-
| "Submarine"
|
|
976
|
-
| "AuxiliaryShip";
|
|
944
|
+
export type NightAttackType = "Normal" | "Swordfish" | "Aerial";
|
|
977
945
|
|
|
978
|
-
export type
|
|
979
|
-
| "Unknown"
|
|
980
|
-
| "DE"
|
|
981
|
-
| "DD"
|
|
982
|
-
| "CL"
|
|
983
|
-
| "CLT"
|
|
984
|
-
| "CA"
|
|
985
|
-
| "CAV"
|
|
986
|
-
| "CVL"
|
|
987
|
-
| "FBB"
|
|
988
|
-
| "BB"
|
|
989
|
-
| "BBV"
|
|
990
|
-
| "CV"
|
|
991
|
-
| "XBB"
|
|
992
|
-
| "SS"
|
|
993
|
-
| "SSV"
|
|
994
|
-
| "AP"
|
|
995
|
-
| "AV"
|
|
996
|
-
| "LHA"
|
|
997
|
-
| "CVB"
|
|
998
|
-
| "AR"
|
|
999
|
-
| "AS"
|
|
1000
|
-
| "CT"
|
|
1001
|
-
| "AO";
|
|
946
|
+
export type SupportShellingType = ShellingType;
|
|
1002
947
|
|
|
1003
|
-
export type
|
|
948
|
+
export type AttackType =
|
|
949
|
+
| { t: "Asw"; c: AswAttackType }
|
|
950
|
+
| { t: "Shelling"; c: ShellingType }
|
|
951
|
+
| { t: "Night"; c: NightAttackType }
|
|
952
|
+
| { t: "Torpedo" }
|
|
953
|
+
| { t: "SupportShelling"; c: SupportShellingType };
|
|
1004
954
|
|
|
1005
|
-
export
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
include?: string;
|
|
1009
|
-
exclude?: string;
|
|
1010
|
-
}
|
|
955
|
+
export type DayPhaseAttackType =
|
|
956
|
+
| { t: "Shelling"; c: ShellingType }
|
|
957
|
+
| { t: "Asw"; c: AswAttackType };
|
|
1011
958
|
|
|
1012
|
-
export
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
equip_ship: Record<number, MstEquipShip>;
|
|
1016
|
-
equip_exslot_ship: Record<number, MstEquipExslotShip>;
|
|
1017
|
-
rules: EquippabilityRule[];
|
|
1018
|
-
}
|
|
959
|
+
export type NightPhaseAttackType =
|
|
960
|
+
| { t: "Night"; c: NightAttackType }
|
|
961
|
+
| { t: "Asw"; c: AswAttackType };
|
|
1019
962
|
|
|
1020
|
-
export
|
|
1021
|
-
api_ctypes: Record<number, number> | null;
|
|
1022
|
-
api_ship_ids: Record<number, number> | null;
|
|
1023
|
-
api_stypes: Record<number, number> | null;
|
|
1024
|
-
}
|
|
963
|
+
export type TorpedoAttackType = null;
|
|
1025
964
|
|
|
1026
|
-
export type
|
|
965
|
+
export type DayCutin =
|
|
966
|
+
| "Zuiun"
|
|
967
|
+
| "AirSea"
|
|
968
|
+
| "MainMain"
|
|
969
|
+
| "MainAp"
|
|
970
|
+
| "MainRadar"
|
|
971
|
+
| "MainSec"
|
|
972
|
+
| "DoubleAttack"
|
|
973
|
+
| "FBA"
|
|
974
|
+
| "BBA"
|
|
975
|
+
| "BA";
|
|
976
|
+
|
|
977
|
+
export type NightCutin =
|
|
978
|
+
| "MainTorpRadar"
|
|
979
|
+
| "TorpLookoutRadar"
|
|
980
|
+
| "TorpTsloTorp"
|
|
981
|
+
| "TorpTsloDrum"
|
|
982
|
+
| "NightZuiun2Radar"
|
|
983
|
+
| "NightZuiun2"
|
|
984
|
+
| "NightZuiunRadar"
|
|
985
|
+
| "NightZuiun"
|
|
986
|
+
| "DoubleAttack"
|
|
987
|
+
| "TorpTorpMain"
|
|
988
|
+
| "TorpTorpTorp"
|
|
989
|
+
| "MainMainSec"
|
|
990
|
+
| "MainMainMain"
|
|
991
|
+
| "SubTorpTorp"
|
|
992
|
+
| "SubRadarTorp"
|
|
993
|
+
| "Cvci1_25"
|
|
994
|
+
| "Cvci1_20"
|
|
995
|
+
| "Cvci1_18"
|
|
996
|
+
| "Photobomber";
|
|
1027
997
|
|
|
1028
|
-
export type
|
|
998
|
+
export type FleetCutin =
|
|
999
|
+
| "NelsonTouch"
|
|
1000
|
+
| "NagatoClassCutin"
|
|
1001
|
+
| "ColoradoClassCutin"
|
|
1002
|
+
| "KongouClassCutin"
|
|
1003
|
+
| "Yamato2ShipCutin"
|
|
1004
|
+
| "Yamato3ShipCutin";
|
|
1029
1005
|
|
|
1030
|
-
export
|
|
1031
|
-
id: number;
|
|
1032
|
-
equip_type: number[];
|
|
1033
|
-
}
|
|
1006
|
+
export type DayCutinLike = DayCutin | FleetCutin;
|
|
1034
1007
|
|
|
1035
|
-
export
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1008
|
+
export type NightCutinLike = NightCutin | FleetCutin;
|
|
1009
|
+
|
|
1010
|
+
export type MoraleState = "Sparkle" | "Normal" | "Orange" | "Red";
|
|
1011
|
+
|
|
1012
|
+
export type NodeId = string;
|
|
1013
|
+
|
|
1014
|
+
export interface NodeState {
|
|
1015
|
+
map?: number;
|
|
1016
|
+
node?: NodeId;
|
|
1017
|
+
phase?: number;
|
|
1018
|
+
debuff?: boolean;
|
|
1019
|
+
disable_historical_mod?: boolean;
|
|
1020
|
+
landing_battle?: boolean;
|
|
1040
1021
|
}
|
|
1041
1022
|
|
|
1023
|
+
export type SlotSizeVec = (number | null)[];
|
|
1024
|
+
|
|
1025
|
+
export type SpecialEnemyType =
|
|
1026
|
+
| "None"
|
|
1027
|
+
| "SoftSkinned"
|
|
1028
|
+
| "Pillbox"
|
|
1029
|
+
| "IsolatedIsland"
|
|
1030
|
+
| "SupplyDepot"
|
|
1031
|
+
| "NewSupplyDepot"
|
|
1032
|
+
| "HarbourSummerPrincess"
|
|
1033
|
+
| "PtImp"
|
|
1034
|
+
| "BattleshipSummerPrincess"
|
|
1035
|
+
| "HeavyCruiserSummerPrincess"
|
|
1036
|
+
| "FrenchBattleshipPrincess"
|
|
1037
|
+
| "AnchorageWaterDemonVacationMode"
|
|
1038
|
+
| "DockPrincess"
|
|
1039
|
+
| "SummerAircraftCarrierDemon";
|
|
1040
|
+
|
|
1042
1041
|
export class AirSquadron {
|
|
1043
1042
|
private constructor();
|
|
1044
1043
|
free(): void;
|
|
@@ -1306,6 +1305,12 @@ export class Ship {
|
|
|
1306
1305
|
private constructor();
|
|
1307
1306
|
free(): void;
|
|
1308
1307
|
[Symbol.dispose](): void;
|
|
1308
|
+
state_day_gunfit_accuracy(): number | undefined;
|
|
1309
|
+
state_night_gunfit_accuracy(): number | undefined;
|
|
1310
|
+
/**
|
|
1311
|
+
* フィット砲補正
|
|
1312
|
+
*/
|
|
1313
|
+
gunfit_accuracy(is_night: boolean): number;
|
|
1309
1314
|
static default(): Ship;
|
|
1310
1315
|
eq_id(id: string): boolean;
|
|
1311
1316
|
state(): ShipState;
|
|
@@ -1364,12 +1369,6 @@ export class Ship {
|
|
|
1364
1369
|
* 確殺攻撃力
|
|
1365
1370
|
*/
|
|
1366
1371
|
ohko_power(): number | undefined;
|
|
1367
|
-
state_day_gunfit_accuracy(): number | undefined;
|
|
1368
|
-
state_night_gunfit_accuracy(): number | undefined;
|
|
1369
|
-
/**
|
|
1370
|
-
* フィット砲補正
|
|
1371
|
-
*/
|
|
1372
|
-
gunfit_accuracy(is_night: boolean): number;
|
|
1373
1372
|
id: string;
|
|
1374
1373
|
readonly hash: bigint;
|
|
1375
1374
|
readonly ship_id: number;
|