Skip to content

Commit

Permalink
Added back Server Bar clicking
Browse files Browse the repository at this point in the history
  • Loading branch information
NostraThomas99 committed Mar 28, 2024
1 parent 2119b39 commit fb6758b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions RotationSolver/Commands/RSCommands_Actions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,14 @@ public static partial class RSCommands
static DateTime _lastClickTime = DateTime.MinValue;
static bool _lastState;

public static void IncrementState()
{
if (!DataCenter.State) { DoStateCommandType(StateCommandType.Auto); return; }
if (DataCenter.State && !DataCenter.IsManual && DataCenter.TargetingType == TargetingType.Big) { DoStateCommandType(StateCommandType.Auto); return; }
if (DataCenter.State && !DataCenter.IsManual) { DoStateCommandType(StateCommandType.Manual); return; }
if (DataCenter.State && DataCenter.IsManual) { DoStateCommandType(StateCommandType.Cancel); return; }
}

internal static unsafe bool CanDoAnAction(bool isGCD)
{
if (!_lastState || !DataCenter.State)
Expand Down
1 change: 1 addition & 0 deletions RotationSolver/Updaters/PreviewUpdater.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ private static void UpdateEntry()
new IconPayload(BitmapFontIcon.DPS),
new TextPayload(showStr)
);
_dtrEntry.OnClick = RSCommands.IncrementState;
}
else if (_dtrEntry != null && _dtrEntry.Shown)
{
Expand Down

0 comments on commit fb6758b

Please sign in to comment.