Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 18 additions & 3 deletions WrathCombo/Combos/CustomComboPreset.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2841,9 +2841,14 @@ public enum Preset
[JobInfo(Job.DRK)]
[Retargeted(DRK.Shadowstride)]
DRK_RetargetShadowstride = 5135,

[ReplaceSkill(DRK.Unmend)]
[JobInfo(Job.DRK)]
[Retargeted(DRK.Unmend)]
DRK_Retarget_Unmend = 5136,

#endregion
// Last value = 5135
// Last value = 5136

#endregion
// Last value = 5135
Expand Down Expand Up @@ -3534,9 +3539,14 @@ public enum Preset
[JobInfo(Job.GNB)]
[Retargeted(GNB.Trajectory)]
GNB_RetargetTrajectory = 7091,

[ReplaceSkill(GNB.LightningShot)]
[JobInfo(Job.GNB)]
[Retargeted(GNB.LightningShot)]
GNB_RetargetLightningShot = 7094,
#endregion

// Last Value = 7093
// Last Value = 7094
#endregion

#region MACHINIST
Expand Down Expand Up @@ -7655,9 +7665,14 @@ public enum Preset
[JobInfo(Job.WAR)]
[Retargeted(WAR.Holmgang)]
WAR_RetargetHolmgang = 18130,

[ReplaceSkill(WAR.Tomahawk)]
[JobInfo(Job.WAR)]
[Retargeted(WAR.Tomahawk)]
WAR_RetargetTomahawk = 18156,

#endregion
// Last value = 18155
// Last value = 18156
#endregion

#region WHITE MAGE
Expand Down
34 changes: 34 additions & 0 deletions WrathCombo/Combos/PvE/DRK/DRK.cs
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,40 @@ protected override uint Invoke(uint actionID)
: actionID;
}
}

internal class DRK_RetargetUnmend : CustomCombo
{
protected internal override Preset Preset => Preset.DRK_Retarget_Unmend;

protected override uint Invoke(uint actionID)
{
if (actionID is not Unmend)
return actionID;

IGameObject? target =
//Mouseover Retarget
(DRK_Retarget_Unmend_FieldMO
? SimpleTarget.Stack.MouseOver.IfHostile().IfWithinRange(Unmend.ActionRange())
: null) ??

(DRK_Retarget_Unmend_SmartTargeting == 0 && DRK_Retarget_Unmend_RangeBasedTargeting
? DRK_Retarget_Unmend_SmartTargeting_NotTargetingPlayer
? SimpleTarget.FurthestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(Unmend.ActionRange())
: SimpleTarget.FurthestEnemyOver5YalmsAway.IfWithinRange(Unmend.ActionRange())
: null) ??

(DRK_Retarget_Unmend_SmartTargeting == 1 && DRK_Retarget_Unmend_RangeBasedTargeting
? DRK_Retarget_Unmend_SmartTargeting_NotTargetingPlayer
? SimpleTarget.NearestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(Unmend.ActionRange())
: SimpleTarget.NearestEnemyOver5YalmsAway.IfWithinRange(Unmend.ActionRange())
: null);

return target != null
? actionID.Retarget(target)
: actionID;
}
}


#endregion

Expand Down
161 changes: 96 additions & 65 deletions WrathCombo/Combos/PvE/DRK/DRK_Config.cs

Large diffs are not rendered by default.

35 changes: 35 additions & 0 deletions WrathCombo/Combos/PvE/GNB/GNB.cs
Original file line number Diff line number Diff line change
Expand Up @@ -706,6 +706,41 @@ protected override uint Invoke(uint actionID)
}
}
#endregion

#region Lightning Shot Retargeting
internal class GNB_RetargetLightningShot : CustomCombo
{
protected internal override Preset Preset => Preset.GNB_RetargetLightningShot;

protected override uint Invoke(uint actionID)
{
if (actionID is not LightningShot)
return actionID;

IGameObject? target =
//Mouseover Retarget
(GNB_RetargetLightningShot_FieldMO
? SimpleTarget.Stack.MouseOver.IfHostile().IfWithinRange(LightningShot.ActionRange())
: null) ??

(GNB_RetargetLightningShot_SmartTargeting == 0 && GNB_RetargetLightningShot_RangeBasedTargeting
? GNB_RetargetLightningShot_SmartTargeting_NotTargetingPlayer
? SimpleTarget.FurthestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(LightningShot.ActionRange())
: SimpleTarget.FurthestEnemyOver5YalmsAway.IfWithinRange(LightningShot.ActionRange())
: null) ??

(GNB_RetargetLightningShot_SmartTargeting == 1 && GNB_RetargetLightningShot_RangeBasedTargeting
? GNB_RetargetLightningShot_SmartTargeting_NotTargetingPlayer
? SimpleTarget.NearestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(LightningShot.ActionRange())
: SimpleTarget.NearestEnemyOver5YalmsAway.IfWithinRange(LightningShot.ActionRange())
: null);

return target != null
? actionID.Retarget(target)
: actionID;
}
}
#endregion

#region Basic Combos
internal class GNB_ST_BasicCombo : CustomCombo
Expand Down
35 changes: 34 additions & 1 deletion WrathCombo/Combos/PvE/GNB/GNB_Config.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
using System.Numerics;
using Dalamud.Interface.Colors;
using ECommons.ImGuiMethods;
using WrathCombo.CustomComboNS.Functions;
using WrathCombo.Data;
using WrathCombo.Extensions;
Expand Down Expand Up @@ -46,6 +48,7 @@ public static UserInt
GNB_GF_Overcap_Choice = new("GNB_GF_Overcap_Choice"),
GNB_GF_BurstStrike_Setup = new("GNB_GF_BurstStrike_Setup"),
GNB_ST_Balance_Content = new("GNB_ST_Balance_Content", 1),
GNB_RetargetLightningShot_SmartTargeting = new("GNB_RetargetLightningShot_SmartTargeting"),
GNB_Mit_OneButton_Superbolide_Health = new("GNB_Mit_OneButton_Superbolide_Health", 30),
GNB_Mit_OneButton_Corundum_Health = new("GNB_Mit_OneButton_Corundum_Health", 60),
GNB_Mit_OneButton_Aurora_Charges = new("GNB_Mit_OneButton_Aurora_Charges"),
Expand All @@ -60,7 +63,10 @@ public static UserFloat

public static UserBool
GNB_Mit_Advanced_Boss_Camouflage_Align = new("GNB_Mit_Advanced_Boss_Camouflage_Align", true),
GNB_Mit_Advanced_Boss_Nebula_First = new("GNB_Mit_Advanced_Boss_Nebula_First", true);
GNB_Mit_Advanced_Boss_Nebula_First = new("GNB_Mit_Advanced_Boss_Nebula_First", true),
GNB_RetargetLightningShot_FieldMO = new("GNB_RetargetLightningShot_FieldMO"),
GNB_RetargetLightningShot_RangeBasedTargeting = new("GNB_RetargetLightningShot_RangeBasedTargeting"),
GNB_RetargetLightningShot_SmartTargeting_NotTargetingPlayer = new("GNB_RetargetLightningShot_SmartTargeting_NotTargetingPlayer");

public static UserIntArray
GNB_Mit_OneButton_Priorities = new("GNB_Mit_OneButton_Priorities");
Expand Down Expand Up @@ -384,6 +390,33 @@ internal static void Draw(Preset preset)
DrawHorizontalRadioButton(GNB_FC_Continuation_Procs,
"Only Fated Brand", $"Only uses {FatedBrand.ActionName()} regardless of other {Continuation.ActionName()} procs currently available", 1);
break;

case Preset.GNB_RetargetLightningShot:
DrawAdditionalBoolChoice(GNB_RetargetLightningShot_FieldMO, Generics.Mouseover, FormatAndCache(Generics.MouseoverRetargetHostile, LightningShot.ActionName()));

DrawAdditionalBoolChoice(GNB_RetargetLightningShot_RangeBasedTargeting, Generics.RangeBasedTargeting, Generics.RangeBasedTargetingDesc);

if (GNB_RetargetLightningShot_RangeBasedTargeting)
{
ImGui.Indent();
ImGui.NewLine();
DrawHorizontalRadioButton(GNB_RetargetLightningShot_SmartTargeting,
Generics.FurthestOOR,
FormatAndCache(Generics.FurthestOORRetarget, LightningShot.ActionName()), 0,
descriptionColor:ImGuiColors.DalamudWhite);
DrawHorizontalRadioButton(GNB_RetargetLightningShot_SmartTargeting,
Generics.NearestOOR,
FormatAndCache(Generics.NearestOORRetarget, LightningShot.ActionName()), 1,
descriptionColor:ImGuiColors.DalamudWhite);
ImGuiEx.Spacing(new Vector2(0, 5));
ImGui.Unindent();

ImGui.Indent(10f.Scale());
DrawAdditionalBoolChoice(GNB_RetargetLightningShot_SmartTargeting_NotTargetingPlayer, Generics.SmartTargeting, Generics.SmartTargetingNotTargetingPlayer);
ImGui.Unindent();
}
break;

#endregion
}
}
Expand Down
31 changes: 27 additions & 4 deletions WrathCombo/Combos/PvE/PLD/PLD.cs
Original file line number Diff line number Diff line change
Expand Up @@ -262,11 +262,34 @@ protected override uint Invoke(uint actionID)
{
if (actionID is not ShieldLob)
return actionID;

IGameObject? target =
//Mouseover Retarget
(PLD_ShieldLob_Feature_FieldMO
? SimpleTarget.Stack.MouseOver.IfHostile().IfWithinRange(ShieldLob.ActionRange())
: null) ??

(PLD_ShieldLob_Feature_SmartTargeting == 0 && PLD_ShieldLob_Feature_RangeBasedTargeting
? PLD_ShieldLob_Feature_SmartTargeting_NotTargetingPlayer
? SimpleTarget.FurthestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(ShieldLob.ActionRange())
: SimpleTarget.FurthestEnemyOver5YalmsAway.IfWithinRange(ShieldLob.ActionRange())
: null) ??

if (LevelChecked(HolySpirit) && GetResourceCost(HolySpirit) <= LocalPlayer.CurrentMp && (TimeMoving.Ticks == 0 || HasStatusEffect(Buffs.DivineMight)))
return HolySpirit;

return actionID;
(PLD_ShieldLob_Feature_SmartTargeting == 1 && PLD_ShieldLob_Feature_RangeBasedTargeting
? PLD_ShieldLob_Feature_SmartTargeting_NotTargetingPlayer
? SimpleTarget.NearestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(ShieldLob.ActionRange())
: SimpleTarget.NearestEnemyOver5YalmsAway.IfWithinRange(ShieldLob.ActionRange())
: null);

if (PLD_ShieldLob_Feature_HolySpirit && LevelChecked(HolySpirit) && GetResourceCost(HolySpirit) <= LocalPlayer.CurrentMp &&
(TimeMoving.Ticks == 0 || HasStatusEffect(Buffs.DivineMight)))
return target != null
? HolySpirit.Retarget(ShieldLob, target)
: HolySpirit;

return target != null
? actionID.Retarget(target)
: actionID;
}
}

Expand Down
51 changes: 44 additions & 7 deletions WrathCombo/Combos/PvE/PLD/PLD_Config.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
using System.Numerics;
using Dalamud.Interface.Colors;
using ECommons.ImGuiMethods;
using FFXIVClientStructs.FFXIV.Client.System.Input.SoftKeyboards;
Expand Down Expand Up @@ -213,6 +214,36 @@ internal static void Draw(Preset preset)
#endregion

#region Standalones
case Preset.PLD_ShieldLob_Feature:
DrawAdditionalBoolChoice(PLD_ShieldLob_Feature_HolySpirit, "Smart Holy Spirit",
"Replaces Shield Lob with Holy Spirit when available. " +
"\nMust be under the effect of Divine Might or not moving." +
"\nRetargeting features will also apply to Holy Spirit.");
DrawAdditionalBoolChoice(PLD_ShieldLob_Feature_FieldMO, Generics.Mouseover, FormatAndCache(Generics.MouseoverRetargetHostile, ShieldLob.ActionName()));

DrawAdditionalBoolChoice(PLD_ShieldLob_Feature_RangeBasedTargeting, Generics.RangeBasedTargeting, Generics.RangeBasedTargetingDesc);

if (PLD_ShieldLob_Feature_RangeBasedTargeting)
{
ImGui.Indent();
ImGui.NewLine();
DrawHorizontalRadioButton(PLD_ShieldLob_Feature_SmartTargeting,
Generics.FurthestOOR,
FormatAndCache(Generics.FurthestOORRetarget, ShieldLob.ActionName()), 0,
descriptionColor:ImGuiColors.DalamudWhite);
DrawHorizontalRadioButton(PLD_ShieldLob_Feature_SmartTargeting,
Generics.NearestOOR,
FormatAndCache(Generics.NearestOORRetarget, ShieldLob.ActionName()), 1,
descriptionColor:ImGuiColors.DalamudWhite);
ImGuiEx.Spacing(new Vector2(0, 5));
ImGui.Unindent();

ImGui.Indent(10f.Scale());
DrawAdditionalBoolChoice(PLD_ShieldLob_Feature_SmartTargeting_NotTargetingPlayer, Generics.SmartTargeting, Generics.SmartTargetingNotTargetingPlayer);
ImGui.Unindent();
}

break;

case Preset.PLD_Requiescat_Options:
DrawHorizontalRadioButton(PLD_Requiescat_SubOption, FormatAndCache(Generics.DontUse0, FightOrFlight.ActionName()), "", 0);
Expand Down Expand Up @@ -353,6 +384,7 @@ public static UserInt
PLD_RetargetClemency_Health = new("PLD_RetargetClemency_Health", 30),
PLD_RetargetShieldBash_Strength = new("PLD_RetargetShieldBash_Strength", 3),
PLD_RetargetCover_Health = new("PLD_RetargetCover_Health", 30),
PLD_ShieldLob_Feature_SmartTargeting = new("PLD_ShieldLob_Feature_SmartTargeting"),

//One-Button Mitigation
PLD_Mit_HallowedGround_Max_Health = new("PLD_Mit_HallowedGround_Max_Health", 20),
Expand All @@ -368,19 +400,24 @@ public static UserFloat
PLD_AoE_InterveneTimeStill = new("PLD_AoE_InterveneTimeStill", 2.5f);

public static UserBool
PLD_ST_AdvancedMode_CircleOfScorn_ManualPooling = new ("PLD_ST_AdvancedMode_CircleOfScorn_ManualPooling"),
PLD_ST_AdvancedMode_SpiritsWithin_ManualPooling = new ("PLD_ST_AdvancedMode_SpiritsWithin_ManualPooling"),
PLD_ST_AdvancedMode_Intervene_ManualPooling = new ("PLD_ST_AdvancedMode_Intervene_ManualPooling"),
PLD_AoE_AdvancedMode_CircleOfScorn_ManualPooling = new ("PLD_AoE_AdvancedMode_CircleOfScorn_ManualPooling"),
PLD_AoE_AdvancedMode_SpiritsWithin_ManualPooling = new ("PLD_AoE_AdvancedMode_SpiritsWithin_ManualPooling"),
PLD_AoE_AdvancedMode_Intervene_ManualPooling = new ("PLD_AoE_AdvancedMode_Intervene_ManualPooling"),
PLD_ST_AdvancedMode_CircleOfScorn_ManualPooling = new("PLD_ST_AdvancedMode_CircleOfScorn_ManualPooling"),
PLD_ST_AdvancedMode_SpiritsWithin_ManualPooling = new("PLD_ST_AdvancedMode_SpiritsWithin_ManualPooling"),
PLD_ST_AdvancedMode_Intervene_ManualPooling = new("PLD_ST_AdvancedMode_Intervene_ManualPooling"),
PLD_AoE_AdvancedMode_CircleOfScorn_ManualPooling = new("PLD_AoE_AdvancedMode_CircleOfScorn_ManualPooling"),
PLD_AoE_AdvancedMode_SpiritsWithin_ManualPooling = new("PLD_AoE_AdvancedMode_SpiritsWithin_ManualPooling"),
PLD_AoE_AdvancedMode_Intervene_ManualPooling = new("PLD_AoE_AdvancedMode_Intervene_ManualPooling"),
PLD_RetargetStunLockout = new("PLD_RetargetStunLockout"),
PLD_Mitigation_Boss_Bulwark_Align = new("PLD_Mitigation_Boss_Bulwark_Align"),
PLD_Mitigation_Boss_Sentinel_First = new("PLD_Mitigation_Boss_Sentinel_First"),
PLD_HolySpirit_Standalone = new("PLD_HolySpirit_Standalone"),
PLD_HolyCircle_Standalone = new("PLD_HolyCircle_Standalone"),
PLD_SpiritsWithin_SubOption = new("PLD_SpiritsWithin_SubOption"),
PLD_Requiescat_SubOption_GoringBlade = new("PLD_Requiescat_SubOption_GoringBlade");
PLD_Requiescat_SubOption_GoringBlade = new("PLD_Requiescat_SubOption_GoringBlade"),
PLD_ShieldLob_Feature_FieldMO = new("PLD_ShieldLob_Feature_FieldMO"),
PLD_ShieldLob_Feature_SmartTargeting_NotTargetingPlayer = new("PLD_ShieldLob_Feature_SmartTargeting_NotTargetingPlayer"),
PLD_ShieldLob_Feature_RangeBasedTargeting = new("PLD_ShieldLob_Feature_RangeBasedTargeting"),
PLD_ShieldLob_Feature_HolySpirit = new("PLD_ShieldLob_Feature_HolySpirit");


public static UserIntArray
PLD_Mit_Priorities = new("PLD_Mit_Priorities");
Expand Down
37 changes: 37 additions & 0 deletions WrathCombo/Combos/PvE/WAR/WAR.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using Dalamud.Game.ClientState.Objects.Types;
using System;
using ECommons;
using WrathCombo.Core;
using WrathCombo.CustomComboNS;
using WrathCombo.Data;
Expand Down Expand Up @@ -405,6 +406,42 @@ internal class WAR_RetargetHolmgang : CustomCombo
protected override uint Invoke(uint actionID) => actionID != Holmgang ? actionID : actionID.Retarget(SimpleTarget.Self);
}
#endregion

#region Tomahawk Retargeting
internal class WAR_RetargetTomahawk : CustomCombo
{
protected internal override Preset Preset => Preset.WAR_RetargetTomahawk;

protected override uint Invoke(uint actionID)
{
if (actionID is not Tomahawk)
return actionID;

IGameObject? target =
//Mouseover Retarget
(WAR_RetargetTomahawk_FieldMO
? SimpleTarget.Stack.MouseOver.IfHostile().IfWithinRange(Tomahawk.ActionRange())
: null) ??

(WAR_RetargetTomahawk_SmartTargeting == 0 && WAR_RetargetTomahawk_RangeBasedTargeting
? WAR_RetargetTomahawk_SmartTargeting_NotTargetingPlayer
? SimpleTarget.FurthestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(Tomahawk.ActionRange())
: SimpleTarget.FurthestEnemyOver5YalmsAway.IfWithinRange(Tomahawk.ActionRange())
: null) ??

(WAR_RetargetTomahawk_SmartTargeting == 1 && WAR_RetargetTomahawk_RangeBasedTargeting
? WAR_RetargetTomahawk_SmartTargeting_NotTargetingPlayer
? SimpleTarget.NearestEnemyOver5YalmsAwayNotTargetingPlayer.IfWithinRange(Tomahawk.ActionRange())
: SimpleTarget.NearestEnemyOver5YalmsAway.IfWithinRange(Tomahawk.ActionRange())
: null);


return target != null
? actionID.Retarget(target)
: actionID;
}
}
#endregion

#region Basic Combos
internal class WAR_ST_StormsPathCombo : CustomCombo
Expand Down
Loading