From d6e77d11f660638766919ab6222ae27060537076 Mon Sep 17 00:00:00 2001 From: Andrew Gilewsky Date: Sat, 6 Jan 2024 12:34:19 +0000 Subject: [PATCH] TOP P6 WIP --- .../Endwalker/Ultimate/TOP/P6CosmoMeteor.cs | 32 +++++++++++++++++++ .../Endwalker/Ultimate/TOP/TOPEnums.cs | 6 ++++ .../Endwalker/Ultimate/TOP/TOPStates.cs | 29 +++++++++++++---- 3 files changed, 61 insertions(+), 6 deletions(-) create mode 100644 BossMod/Modules/Endwalker/Ultimate/TOP/P6CosmoMeteor.cs diff --git a/BossMod/Modules/Endwalker/Ultimate/TOP/P6CosmoMeteor.cs b/BossMod/Modules/Endwalker/Ultimate/TOP/P6CosmoMeteor.cs new file mode 100644 index 0000000000..113451e188 --- /dev/null +++ b/BossMod/Modules/Endwalker/Ultimate/TOP/P6CosmoMeteor.cs @@ -0,0 +1,32 @@ +namespace BossMod.Endwalker.Ultimate.TOP +{ + class P6CosmoMeteorPuddles : Components.SelfTargetedAOEs + { + public P6CosmoMeteorPuddles() : base(ActionID.MakeSpell(AID.CosmoMeteorAOE), new AOEShapeCircle(10)) { } + } + + class P6CosmoMeteorAddComet : Components.Adds + { + public P6CosmoMeteorAddComet() : base((uint)OID.CosmoComet) { } + } + + class P6CosmoMeteorAddMeteor : Components.Adds + { + public P6CosmoMeteorAddMeteor() : base((uint)OID.CosmoMeteor) { } + } + + class P6CosmoMeteorSpread : Components.UniformStackSpread + { + public int NumCasts { get; private set; } + + public P6CosmoMeteorSpread() : base(0, 5) { } + + public override void Init(BossModule module) => AddSpreads(module.Raid.WithoutSlot(true)); + + public override void OnEventCast(BossModule module, Actor caster, ActorCastEvent spell) + { + if ((AID)spell.Action.ID == AID.CosmoMeteorSpread) + ++NumCasts; + } + } +} diff --git a/BossMod/Modules/Endwalker/Ultimate/TOP/TOPEnums.cs b/BossMod/Modules/Endwalker/Ultimate/TOP/TOPEnums.cs index b21142e417..e85e080b47 100644 --- a/BossMod/Modules/Endwalker/Ultimate/TOP/TOPEnums.cs +++ b/BossMod/Modules/Endwalker/Ultimate/TOP/TOPEnums.cs @@ -27,6 +27,8 @@ public enum OID : uint IntermissionAlpha = 0x3E75, // R0.900, spawn during fight (purely visual during pre-p6 intermission) IntermissionOmegaF = 0x3E76, // R0.500, spawn during fight (purely visual during pre-p6 intermission) BossP6 = 0x3D6D, // R13.000, spawn during fight + CosmoMeteor = 0x3D6E, // R3.000, spawn during fight (p6 big meteor) + CosmoComet = 0x3D6F, // R1.000, spawn during fight (p6 small comet) //_Gen_Actor1ea1a1 = 0x1EA1A1, // R2.000, x1, EventObj type //_Gen_Exit = 0x1E850B, // R0.500, x1, EventObj type @@ -227,6 +229,10 @@ public enum AID : uint P6WaveCannonProtean = 31657, // BossP6->self, 10.9s cast, single-target, visual (proteans + wild charge) P6WaveCannonWildCharge = 31658, // BossP6->self, no cast, range 100 width 8 rect wild charge P6WaveCannonProteanAOE = 31659, // Helper->self, no cast, range 100 width 8 rect + CosmoMeteor = 31664, // BossP6->self, 5.0s cast, single-target, visual (big puddles + meteors/comets spawn) + CosmoMeteorAOE = 31666, // Helper->self, 4.0s cast, range 10 circle puddle + CosmoMeteorSpread = 32699, // Helper->player, no cast, range 5 circle spread + CosmoMeteorCometEnrage = 31669, // CosmoComet->self, no cast, range 100 circle, wipe if comets not killed in time //_Ability_LatentSynchronizationDefect = 31576, // Helper->player, no cast, single-target }; diff --git a/BossMod/Modules/Endwalker/Ultimate/TOP/TOPStates.cs b/BossMod/Modules/Endwalker/Ultimate/TOP/TOPStates.cs index 841b33b5e5..eb8930bddc 100644 --- a/BossMod/Modules/Endwalker/Ultimate/TOP/TOPStates.cs +++ b/BossMod/Modules/Endwalker/Ultimate/TOP/TOPStates.cs @@ -79,8 +79,8 @@ private void Phase6(uint id) P6CosmoArrowWaveCannon(id + 0x60000, 0.3f); P6FlashGales(id + 0x70000, 4.9f); P6UnlimitedWaveCannonCosmoDive(id + 0x80000, 0.3f); - // not sure about timings below... P6FlashGales(id + 0x90000, 7.5f); + P6CosmoMeteor(id + 0xA0000, 3.5f); // meteors, flares, magic numbers, enrage SimpleState(id + 0xFF0000, 100, "???"); } @@ -496,10 +496,10 @@ private void P6CosmoArrowCosmoDive(uint id, float delay) ComponentCondition(id + 0x13, 2, comp => comp.NumCasts >= 26, "Exasquare 4"); ActorCastStart(id + 0x20, _module.BossP6, AID.CosmoDive, 1.1f, true); - ComponentCondition(id + 0x21, 0.9f, comp => comp.NumCasts >= (comp.CurPattern == Ultimate.TOP.P6CosmoArrow.Pattern.OutIn ? 34 : 30), "Exasquare 5") // depending on pattern, lines expanding outwards could have finished + ComponentCondition(id + 0x21, 0.9f, comp => comp.NumCasts >= (comp.CurPattern == P6CosmoArrow.Pattern.OutIn ? 34 : 30), "Exasquare 5") // depending on pattern, lines expanding outwards could have finished .ActivateOnEnter(); - ComponentCondition(id + 0x22, 2, comp => comp.NumCasts >= (comp.CurPattern == Ultimate.TOP.P6CosmoArrow.Pattern.OutIn ? 38 : 34), "Exasquare 6"); - ComponentCondition(id + 0x23, 2, comp => comp.NumCasts >= (comp.CurPattern == Ultimate.TOP.P6CosmoArrow.Pattern.OutIn ? 42 : 38), "Exasquare 7"); // will get one more for in-out pattern + ComponentCondition(id + 0x22, 2, comp => comp.NumCasts >= (comp.CurPattern == P6CosmoArrow.Pattern.OutIn ? 38 : 34), "Exasquare 6"); + ComponentCondition(id + 0x23, 2, comp => comp.NumCasts >= (comp.CurPattern == P6CosmoArrow.Pattern.OutIn ? 42 : 38), "Exasquare 7"); // will get one more for in-out pattern ActorCastEnd(id + 0x24, _module.BossP6, 0.7f, true); ComponentCondition(id + 0x30, 2.5f, comp => !comp.Active, "Tankbusters + Stack") @@ -551,7 +551,6 @@ private void P6CosmoArrowWaveCannon(uint id, float delay) .SetHint(StateMachine.StateHint.Raidwide | StateMachine.StateHint.Tankbuster); } - // TODO: timings.. private void P6UnlimitedWaveCannonCosmoDive(uint id, float delay) { ActorCast(id, _module.BossP6, AID.UnlimitedWaveCannon, delay, 5, true) @@ -560,7 +559,7 @@ private void P6UnlimitedWaveCannonCosmoDive(uint id, float delay) .ActivateOnEnter(); ComponentCondition(id + 0x11, 1.9f, comp => comp.NumCasts > 0, "Exaflares start"); - ActorCast(id + 0x20, _module.BossP6, AID.CosmoDive, 6, 5.6f, true) + ActorCast(id + 0x20, _module.BossP6, AID.CosmoDive, 6.1f, 5.6f, true) .ActivateOnEnter(); ComponentCondition(id + 0x30, 2.5f, comp => !comp.Active, "Tankbusters + Stack") .DeactivateOnExit() @@ -568,5 +567,23 @@ private void P6UnlimitedWaveCannonCosmoDive(uint id, float delay) .DeactivateOnExit() .SetHint(StateMachine.StateHint.Raidwide | StateMachine.StateHint.Tankbuster); } + + private void P6CosmoMeteor(uint id, float delay) + { + ActorCast(id, _module.BossP6, AID.CosmoMeteor, delay, 5, true); + ComponentCondition(id + 0x10, 0.1f, comp => comp.Casters.Count > 0, "Puddles bait") + .ActivateOnEnter(); + ComponentCondition(id + 0x20, 4.0f, comp => comp.NumCasts > 0) + .ActivateOnEnter() + .ActivateOnEnter() // adds become targetable ~3.2s after puddle casts start + .ActivateOnEnter() + .DeactivateOnExit(); + ComponentCondition(id + 0x30, 1.2f, comp => comp.NumCasts > 0, "Spreads 1"); + ComponentCondition(id + 0x31, 1.0f, comp => comp.NumCasts > 4, "Spreads 2"); + ComponentCondition(id + 0x32, 5.0f, comp => comp.NumCasts > 8, "Spreads 3"); + ComponentCondition(id + 0x33, 1.0f, comp => comp.NumCasts > 12, "Spreads 4") + .DeactivateOnExit(); + // +3.2s: comet enrage + } } }