Skip to content

Commit

Permalink
Merge pull request #433 from BrakusTapus/main
Browse files Browse the repository at this point in the history
removed tactician code from earlier PR
  • Loading branch information
LTS-FFXIV authored Oct 19, 2024
2 parents e0eb1f8 + a996dbd commit c463fbc
Showing 1 changed file with 25 additions and 7 deletions.
32 changes: 25 additions & 7 deletions RotationSolver.Basic/Rotations/Basic/MachinistRotation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,22 @@ partial class MachinistRotation

#region Job Gauge
/// <summary>
///
/// Gets a value indicating whether the player is currently Overheated.
/// </summary>
public static bool IsOverheated => JobGauge.IsOverheated;

/// <summary>
///
/// Gets a value indicating whether the player has an active Robot.
/// </summary>
public static bool IsRobotActive => JobGauge.IsRobotActive;

/// <summary>
/// Gets the current Heat level.
/// </summary>
public static byte Heat => JobGauge.Heat;

/// <summary>
///
/// Gets the current Overheated Stacks.
/// </summary>
public static byte OverheatedStacks
{
Expand All @@ -29,22 +34,29 @@ public static byte OverheatedStacks
}

/// <summary>
///
/// Gets the current Battery level.
/// </summary>
public static byte Battery => JobGauge.Battery;

/// <summary>
///
/// Gets the battery level of the last summon (robot).
/// </summary>
public static byte LastSummonBatteryPower => JobGauge.LastSummonBatteryPower;

static float OverheatTimeRemainingRaw => JobGauge.OverheatTimeRemaining / 1000f;

static float SummonTimeRemainingRaw => JobGauge.SummonTimeRemaining / 1000f;

/// <summary>
///
/// Gets the time remaining for Overheat in seconds minus the DefaultGCDRemain.
/// </summary>
public static float OverheatTime => OverheatTimeRemainingRaw - DataCenter.DefaultGCDRemain;

/// <summary>
/// Gets the time remaining for the Rook or Queen in seconds minus the DefaultGCDRemain.
/// </summary>
public static float SummonTime => SummonTimeRemainingRaw - DataCenter.DefaultGCDRemain;

/// <summary>
///
/// </summary>
Expand All @@ -65,9 +77,12 @@ protected static bool OverheatedEndAfterGCD(uint gctCount = 0, float offset = 0)
public override void DisplayStatus()
{
ImGui.Text("IsOverheated: " + IsOverheated.ToString());
ImGui.Text("IsRobotActive: " + IsRobotActive.ToString());
ImGui.Text("Heat: " + Heat.ToString());
ImGui.Text("Battery: " + Battery.ToString());
ImGui.Text("LastSummonBatteryPower: " + LastSummonBatteryPower.ToString());
ImGui.Text("SummonTimeRemainingRaw: " + SummonTimeRemainingRaw.ToString());
ImGui.Text("SummonTime: " + SummonTime.ToString());
ImGui.Text("OverheatTimeRemainingRaw: " + OverheatTimeRemainingRaw.ToString());
ImGui.Text("OverheatTime: " + OverheatTime.ToString());
ImGui.Text("OverheatedStacks: " + OverheatedStacks.ToString());
Expand All @@ -92,7 +107,7 @@ static partial void ModifyHotShotPvE(ref ActionSetting setting)
static partial void ModifyReassemblePvE(ref ActionSetting setting)
{
setting.StatusProvide = [StatusID.Reassembled];
setting.ActionCheck = () => HasHostilesInRange;
setting.ActionCheck = () => HasHostilesInRange && !Player.HasStatus(true, StatusID.Reassembled);
}

static partial void ModifyGaussRoundPvE(ref ActionSetting setting)
Expand Down Expand Up @@ -146,6 +161,7 @@ static partial void ModifyRookAutoturretPvE(ref ActionSetting setting)

static partial void ModifyRookOverdrivePvE(ref ActionSetting setting)
{
setting.ActionCheck = () => JobGauge.IsRobotActive;
setting.CreateConfig = () => new ActionConfig()
{
TimeToKill = 16,
Expand Down Expand Up @@ -224,6 +240,8 @@ static partial void ModifyHeatedSlugShotPvE(ref ActionSetting setting)
static partial void ModifyDismantlePvE(ref ActionSetting setting)
{
setting.TargetStatusProvide = [StatusID.Dismantled];
// Pretty sure this will work as intended, but commented out cause I want a 2nd opinion ~ Kirbo
//setting.ActionCheck = () => CurrentTarget != null && !CurrentTarget.HasStatus(false, StatusID.Dismantled);
setting.CreateConfig = () => new ActionConfig()
{
AoeCount = 1,
Expand Down

0 comments on commit c463fbc

Please sign in to comment.