BRU effects for analyzer

This commit is contained in:
Kalle
2022-09-17 12:58:43 +03:00
parent e87fd714e2
commit 4b128c59a6
8 changed files with 289 additions and 6 deletions

View File

@@ -218,6 +218,7 @@ function parametersToSubWeaponResult(params: any): SubWeaponParams {
// );
return {
overwrites: resolveSubWeaponOverwrites(params),
// xxx: not every sub has this, why? e.g. Splash Wall
SubInkSaveLv,
InkConsume: params["WeaponParam"]["InkConsume"],
@@ -337,6 +338,27 @@ function resolveOverwritesWithArbitraryKeys(
}
}
function resolveSubWeaponOverwrites(params: any) {
const result: SubWeaponParams["overwrites"] = {
SpawnSpeedZSpecUp: params["MoveParam"]?.["SpawnSpeedZSpecUp"],
PeriodFirst: params["MoveParam"]?.["PeriodFirst"],
PeriodSecond: params["MoveParam"]?.["PeriodSecond"],
MarkingFrameSubSpec:
params["MoveParam"]?.["MarkingFrameSubSpec"] ??
params["MoveParam"]?.["MarkingFrame"],
SensorRadius: params["MoveParam"]?.["SensorRadius"],
MaxHP: params["MoveParam"]?.["MaxHP"],
// xxx: missing Squid Beakon AP up
};
return Object.fromEntries(
Object.entries(result).filter(
([_key, value]) =>
value && (value.High !== value.Mid || value.Low !== value.High)
)
);
}
const WEAPON_TYPES_TO_IGNORE = [
"Mission",
"Coop",