Skip to content

Commit fb6758b

Browse files
Added back Server Bar clicking
1 parent 2119b39 commit fb6758b

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

RotationSolver/Commands/RSCommands_Actions.cs

+8
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,14 @@ public static partial class RSCommands
1515
static DateTime _lastClickTime = DateTime.MinValue;
1616
static bool _lastState;
1717

18+
public static void IncrementState()
19+
{
20+
if (!DataCenter.State) { DoStateCommandType(StateCommandType.Auto); return; }
21+
if (DataCenter.State && !DataCenter.IsManual && DataCenter.TargetingType == TargetingType.Big) { DoStateCommandType(StateCommandType.Auto); return; }
22+
if (DataCenter.State && !DataCenter.IsManual) { DoStateCommandType(StateCommandType.Manual); return; }
23+
if (DataCenter.State && DataCenter.IsManual) { DoStateCommandType(StateCommandType.Cancel); return; }
24+
}
25+
1826
internal static unsafe bool CanDoAnAction(bool isGCD)
1927
{
2028
if (!_lastState || !DataCenter.State)

RotationSolver/Updaters/PreviewUpdater.cs

+1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ private static void UpdateEntry()
4242
new IconPayload(BitmapFontIcon.DPS),
4343
new TextPayload(showStr)
4444
);
45+
_dtrEntry.OnClick = RSCommands.IncrementState;
4546
}
4647
else if (_dtrEntry != null && _dtrEntry.Shown)
4748
{

0 commit comments

Comments
 (0)