Skip to content
This repository has been archived by the owner on Nov 21, 2024. It is now read-only.

Commit

Permalink
Merge commit 'refs/pull/1681/head' of https://github.com/Nik-Potokar/…
Browse files Browse the repository at this point in the history
  • Loading branch information
Taurenkey committed Aug 10, 2024
2 parents 97f3652 + 1659425 commit a406cbd
Showing 1 changed file with 37 additions and 82 deletions.
119 changes: 37 additions & 82 deletions XIVSlothCombo/Combos/PvE/BRD.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using Dalamud.Game.ClientState.JobGauge.Types;
using Dalamud.Game.ClientState.Statuses;
using System;
using System.ComponentModel.Design;
using XIVSlothCombo.Combos.PvE.Content;
using XIVSlothCombo.Core;
using XIVSlothCombo.CustomComboNS;
Expand Down Expand Up @@ -378,7 +379,7 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
if (songWanderer)
{
if (songTimerInSeconds <= 3 && gauge.Repertoire > 0) // Spend any repertoire before switching to next song
return OriginalHook(WanderersMinuet);
return OriginalHook(PitchPerfect);
if (songTimerInSeconds <= 3 && balladReady) // Move to Mage's Ballad if <= 3 seconds left on song
return MagesBallad;
}
Expand Down Expand Up @@ -422,53 +423,28 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
bool ragingReady = LevelChecked(RagingStrikes) && IsOffCooldown(RagingStrikes);
bool battleVoiceReady = LevelChecked(BattleVoice) && IsOffCooldown(BattleVoice);
bool barrageReady = LevelChecked(Barrage) && IsOffCooldown(Barrage);
bool firstMinute = CombatEngageDuration().Minutes == 0;
bool restOfFight = CombatEngageDuration().Minutes > 0;

if (!openerFinished && (!JustUsed(WanderersMinuet) || HasEffect(Buffs.BattleVoice)))
{
if (ragingReady && ((canWeaveBuffs && firstMinute) || (canWeaveDelayed && restOfFight)) &&
(GetCooldownElapsed(BattleVoice) >= 2.3 || battleVoiceReady || !LevelChecked(BattleVoice)))
return RagingStrikes;
}
else if (openerFinished)
{
if (ragingReady && ((canWeaveBuffs && firstMinute) || (canWeaveDelayed && restOfFight)) &&
(HasEffect(Buffs.BattleVoice) || battleVoiceReady || !LevelChecked(BattleVoice)))
return RagingStrikes;

}

if (canWeaveBuffs && barrageReady && !HasEffect(Buffs.HawksEye) && HasEffect(Buffs.RagingStrikes))
//Raging and BV before Finale to minimize drift
if (canWeaveBuffs && ragingReady)
return RagingStrikes;
if (canWeaveBuffs && battleVoiceReady)
return BattleVoice;
if (canWeaveBuffs && IsEnabled(CustomComboPreset.BRD_Simple_BuffsRadiant) && radiantReady &&
(Array.TrueForAll(gauge.Coda, SongIsNotNone) || Array.Exists(gauge.Coda, SongIsWandererMinuet))
&& HasEffect(Buffs.BattleVoice))
return RadiantFinale;
//removed requirement to not have hawks eye, it is better to maybe lose 60 potency than allow it to drift a 1000 potency gain out of the window
if (canWeaveBuffs && barrageReady && HasEffect(Buffs.RagingStrikes))
{
if (LevelChecked(RadiantFinale) && HasEffect(Buffs.RadiantFinale))
return Barrage;
else if (LevelChecked(BattleVoice) && HasEffect(Buffs.BattleVoice))
return Barrage;
else if (!LevelChecked(BattleVoice) && HasEffect(Buffs.RagingStrikes))
return Barrage;
}

if (canWeaveBuffs && IsEnabled(CustomComboPreset.BRD_Simple_BuffsRadiant) && radiantReady &&
(Array.TrueForAll(gauge.Coda, SongIsNotNone) || Array.Exists(gauge.Coda, SongIsWandererMinuet)) &&
(battleVoiceReady || GetCooldownRemainingTime(BattleVoice) < 0.7) &&
(GetBuffRemainingTime(Buffs.RagingStrikes) <= 16.5 || openerFinished))
{
if (!JustUsed(RagingStrikes))
return RadiantFinale;
}

if (canWeaveBuffs && battleVoiceReady &&
((GetBuffRemainingTime(Buffs.RagingStrikes) <= 16.5 || GetBuffRemainingTime(Buffs.RadiantFinale) <= 16.5) || openerFinished) && (IsOnCooldown(RagingStrikes) || IsOnCooldown(RadiantFinale)))
{
if (!JustUsed(RagingStrikes))
return BattleVoice;
}

}

if (HasEffect(Buffs.RadiantEncoreReady) && !JustUsed(RadiantFinale) && GetCooldownElapsed(BattleVoice) >= 4.2f)
return OriginalHook(RadiantEncore);


if (canWeave)
{
Expand Down Expand Up @@ -505,7 +481,7 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
}


if (LevelChecked(Bloodletter) && ((!openerFinished && IsOnCooldown(RagingStrikes)) || openerFinished))
if (LevelChecked(Bloodletter) && (empyrealCD > 1 || !LevelChecked(EmpyrealArrow)) && ((!openerFinished && IsOnCooldown(RagingStrikes)) || openerFinished))
{
uint rainOfDeathCharges = GetRemainingCharges(RainOfDeath);

Expand All @@ -532,6 +508,9 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
else if (rainOfDeathCharges > 0)
return OriginalHook(RainOfDeath);
}
//Moved Below ogcds as it was preventing them from happening.
if (HasEffect(Buffs.RadiantEncoreReady) && !JustUsed(RadiantFinale) && GetCooldownElapsed(BattleVoice) >= 4.2f)
return OriginalHook(RadiantEncore);

// healing - please move if not appropriate priority
if (IsEnabled(CustomComboPreset.BRD_ST_SecondWind))
Expand Down Expand Up @@ -711,7 +690,7 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
if (songWanderer)
{
if (songTimerInSeconds <= 3 && gauge.Repertoire > 0) // Spend any repertoire before switching to next song
return OriginalHook(WanderersMinuet);
return OriginalHook(PitchPerfect);
if (songTimerInSeconds <= 3 && balladReady) // Move to Mage's Ballad if <= 3 seconds left on song
return MagesBallad;
}
Expand Down Expand Up @@ -755,53 +734,26 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
bool ragingReady = LevelChecked(RagingStrikes) && IsOffCooldown(RagingStrikes);
bool battleVoiceReady = LevelChecked(BattleVoice) && IsOffCooldown(BattleVoice);
bool barrageReady = LevelChecked(Barrage) && IsOffCooldown(Barrage);
bool firstMinute = CombatEngageDuration().Minutes == 0;
bool restOfFight = CombatEngageDuration().Minutes > 0;

if (!openerFinished && (!JustUsed(WanderersMinuet) || HasEffect(Buffs.BattleVoice)))
{
if (ragingReady && ((canWeaveBuffs && firstMinute) || (canWeaveDelayed && restOfFight)) &&
(GetCooldownElapsed(BattleVoice) >= 2.3 || battleVoiceReady || !LevelChecked(BattleVoice)))
return RagingStrikes;
}
else if (openerFinished)
{
if (ragingReady && ((canWeaveBuffs && firstMinute) || (canWeaveDelayed && restOfFight)) &&
(HasEffect(Buffs.BattleVoice) || battleVoiceReady || !LevelChecked(BattleVoice)))
return RagingStrikes;

}

if (canWeaveBuffs && barrageReady && !HasEffect(Buffs.HawksEye) && HasEffect(Buffs.RagingStrikes))
{
//Raging and BV before Finale to minimize drift
if (canWeaveBuffs && ragingReady)
return RagingStrikes;
if (canWeaveBuffs && battleVoiceReady)
return BattleVoice;
if (canWeaveBuffs && IsEnabled(CustomComboPreset.BRD_Simple_BuffsRadiant) && radiantReady &&
(Array.TrueForAll(gauge.Coda, SongIsNotNone) || Array.Exists(gauge.Coda, SongIsWandererMinuet))
&& HasEffect(Buffs.BattleVoice))
return RadiantFinale;
//removed requirement to not have hawks eye, it is better to maybe lose 60 potency than allow it to drift a 1000 potency gain out of the window
if (canWeaveBuffs && barrageReady && HasEffect(Buffs.RagingStrikes))
{
if (LevelChecked(RadiantFinale) && HasEffect(Buffs.RadiantFinale))
return Barrage;
else if (LevelChecked(BattleVoice) && HasEffect(Buffs.BattleVoice))
return Barrage;
else if (!LevelChecked(BattleVoice) && HasEffect(Buffs.RagingStrikes))
return Barrage;
}

if (canWeaveBuffs && IsEnabled(CustomComboPreset.BRD_Simple_BuffsRadiant) && radiantReady &&
(Array.TrueForAll(gauge.Coda, SongIsNotNone) || Array.Exists(gauge.Coda, SongIsWandererMinuet)) &&
(battleVoiceReady || GetCooldownRemainingTime(BattleVoice) < 0.7) &&
(GetBuffRemainingTime(Buffs.RagingStrikes) <= 16.5 || openerFinished))
{
if (!JustUsed(RagingStrikes))
return RadiantFinale;
}

if (canWeaveBuffs && battleVoiceReady &&
((GetBuffRemainingTime(Buffs.RagingStrikes) <= 16.5 || GetBuffRemainingTime(Buffs.RadiantFinale) <= 16.5) || openerFinished) && (IsOnCooldown(RagingStrikes) || IsOnCooldown(RadiantFinale)))
{
if (!JustUsed(RagingStrikes))
return BattleVoice;
}

}

if (HasEffect(Buffs.RadiantEncoreReady) && !JustUsed(RadiantFinale) && GetCooldownElapsed(BattleVoice) >= 4.2f)
return OriginalHook(RadiantEncore);
}
}

if (canWeave)
{
Expand Down Expand Up @@ -838,7 +790,7 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
}


if (LevelChecked(Bloodletter) && ((!openerFinished && IsOnCooldown(RagingStrikes)) || openerFinished))
if (LevelChecked(Bloodletter) && (empyrealCD > 1 || !LevelChecked(EmpyrealArrow)) && ((!openerFinished && IsOnCooldown(RagingStrikes)) || openerFinished))
{
uint bloodletterCharges = GetRemainingCharges(Bloodletter);

Expand Down Expand Up @@ -873,6 +825,9 @@ protected override uint Invoke(uint actionID, uint lastComboMove, float comboTim
return All.SecondWind;
}
}
//Moved below weaves bc roobert says it is blocking his weaves from happening
if (HasEffect(Buffs.RadiantEncoreReady) && !JustUsed(RadiantFinale) && GetCooldownElapsed(BattleVoice) >= 4.2f)
return OriginalHook(RadiantEncore);

if (isEnemyHealthHigh)
{
Expand Down

0 comments on commit a406cbd

Please sign in to comment.