From 7b3a3bbfcc815b18c07ccd8d4169189dc0eda1dd Mon Sep 17 00:00:00 2001 From: XP Date: Fri, 9 Aug 2024 14:24:45 -0700 Subject: [PATCH] Lariat fix --- .../xp/xivsupport/triggers/Arcadion/M3S.java | 42 ++++++++----------- .../xivsupport/triggers/Arcadion/M3sTest.java | 2 +- .../src/main/resources/te_changelog.html | 4 ++ 3 files changed, 22 insertions(+), 26 deletions(-) diff --git a/triggers/triggers-dt/src/main/java/gg/xp/xivsupport/triggers/Arcadion/M3S.java b/triggers/triggers-dt/src/main/java/gg/xp/xivsupport/triggers/Arcadion/M3S.java index 6d4846839c75..dcad4c7c76b7 100644 --- a/triggers/triggers-dt/src/main/java/gg/xp/xivsupport/triggers/Arcadion/M3S.java +++ b/triggers/triggers-dt/src/main/java/gg/xp/xivsupport/triggers/Arcadion/M3S.java @@ -118,34 +118,26 @@ public boolean enabled(EventContext context) { s.waitMs(100); s.waitEvent(AbilityUsedEvent.class, aue -> aue.abilityIdMatches(0x968E, 0x93FC)); s.waitThenRefreshCombatants(100); - // TODO: IDs for this - // West safe, boss from south, then east safe (boss from north) - // 9AE8 Boss - // 9AF0 actual aoe - // Then, - // 9AEC Boss - // 9AF2 actual aoe - // The possibilities for the boss aoe are: - - - // West safe, boss from south, then west safe again (boss from north) - // 9AE9 boss - // 9AF0 actual aoe - // Then, - // 9AED boss - // 9AF3 actual aoe + /* - 9ADC - 9ADF - 9AE8 - 9AEB - 9B2C - 9B2F + Initial casts: + 9AE8 - left safe then left safe + 9AE9 - left safe then right safe + 9AEA - right safe then right safe + 9AEB - right safe then left safe */ - var lariatCast = s.findOrWaitForCast(casts, acs -> acs.abilityIdMatches(0x9AF0, 0x9AF1), false); - var safe = lariatCast.abilityIdMatches(0x9AF0) ? ArenaSector.WEST : ArenaSector.EAST; - s.setParam("safe", safe); + + // TODO: boss can come from either direction + var lariatCast = s.findOrWaitForCast(casts, acs -> acs.abilityIdMatches(0x9AE8, 0x9AE9, 0x9AEA, 0x9AEB), false); + ArenaSector bossAt = ap.forCombatant(lariatCast.getSource()); + + var firstSafe = bossAt.plusQuads(lariatCast.abilityIdMatches(0x9AE8, 0x9AE9) ? 1 : -1); + var secondSafe = bossAt.opposite().plusQuads(lariatCast.abilityIdMatches(0x9AE8, 0x9AEB) ? 1 : -1); + + s.setParam("safe", firstSafe); s.updateCall(barbarous2ThirdTower); - var lariatCast2 = s.findOrWaitForCast(casts, acs -> acs.abilityIdMatches(0x9AF2, 0x9AF3), false); - var safe2 = lariatCast2.abilityIdMatches(0x9AF3) ? ArenaSector.WEST : ArenaSector.EAST; - s.setParam("safe", safe2); + s.waitMs(5_000); + s.setParam("safe", secondSafe); s.updateCall(barbarous2SecondLariat); }); diff --git a/triggers/triggers-dt/src/test/java/gg/xp/xivsupport/triggers/Arcadion/M3sTest.java b/triggers/triggers-dt/src/test/java/gg/xp/xivsupport/triggers/Arcadion/M3sTest.java index b54375ebab3a..54600dbd7b62 100644 --- a/triggers/triggers-dt/src/test/java/gg/xp/xivsupport/triggers/Arcadion/M3sTest.java +++ b/triggers/triggers-dt/src/test/java/gg/xp/xivsupport/triggers/Arcadion/M3sTest.java @@ -62,7 +62,7 @@ protected List getExpectedCalls() { call(575085, "Side Towers to Corners", "Side Towers to Corners"), call(586220, "Corner Towers to Center", "Corner Towers to Center"), call(589604, "Center Tower to West", "Center Tower to West"), - call(596734, "East Safe", "East Safe"), + call(594641, "East Safe", "East Safe"), call(610060, "Tank Buster - Multi Hit", "Tank Buster - Multi Hit (4.7)"), call(651098, "Multiple Raidwides", "Multiple Raidwides (5.7)") ); diff --git a/xivsupport/src/main/resources/te_changelog.html b/xivsupport/src/main/resources/te_changelog.html index ac31e9d3309a..6d7ae714b0fd 100644 --- a/xivsupport/src/main/resources/te_changelog.html +++ b/xivsupport/src/main/resources/te_changelog.html @@ -1,5 +1,9 @@ +

August 9, 2024

+

August 7, 2024