muffin v7.4.15

This commit is contained in:
alydev 2026-03-01 00:29:23 +10:00
parent 9bf3dbdf69
commit 0b1b2d38c7
14 changed files with 1215 additions and 1057 deletions

View file

@ -87,6 +87,11 @@ internal sealed class ActiveQuestComponent
public void Draw(bool isMinimized)
{
if (_fateController.IsRunning)
{
DrawFateActive(isMinimized);
return;
}
(QuestController.QuestProgress, QuestController.ECurrentQuestType)? currentQuestDetails = _questController.CurrentQuestDetails;
QuestController.QuestProgress questProgress = currentQuestDetails?.Item1;
QuestController.ECurrentQuestType? currentQuestType = currentQuestDetails?.Item2;
@ -131,12 +136,12 @@ internal sealed class ActiveQuestComponent
if (interactionType == EInteractionType.WaitForManualProgress || interactionType == EInteractionType.Snipe || interactionType == EInteractionType.Instruction)
{
flag = true;
goto IL_0154;
goto IL_0169;
}
}
flag = false;
goto IL_0154;
IL_0154:
goto IL_0169;
IL_0169:
if (flag)
{
color.Push(ImGuiCol.Text, ImGuiColors.DalamudOrange);
@ -178,7 +183,7 @@ internal sealed class ActiveQuestComponent
text2.AppendFormatted((item2 == 1) ? string.Empty : "s");
text2.AppendLiteral(" - Leveling mode will start automatically");
ImGui.TextColored(in col, text2);
using (ImRaii.Disabled(_questController.IsRunning || !_autoDutyIpc.IsStopped()))
using (ImRaii.Disabled(_questController.IsRunning || _fateController.IsRunning || !_autoDutyIpc.IsStopped()))
{
if (ImGuiComponents.IconButton(FontAwesomeIcon.Play))
{
@ -247,6 +252,32 @@ internal sealed class ActiveQuestComponent
}
}
private void DrawFateActive(bool isMinimized)
{
using (ImRaii.PushColor(ImGuiCol.Text, ImGuiColors.ParsedGold))
{
ImU8String text = new ImU8String(6, 1);
text.AppendLiteral("FATE: ");
text.AppendFormatted(Shorten(_fateController.CurrentFate.Name));
ImGui.TextUnformatted(text);
}
IList<string> remainingTaskNames = _fateController.GetRemainingTaskNames();
if (remainingTaskNames.Count > 0)
{
ImGui.TextColored(ImGuiColors.DalamudGrey, remainingTaskNames[0]);
}
if (!isMinimized)
{
string text2 = (_fateController.CycleLimit.HasValue ? $"Cycle {_fateController.CompletedCycles + 1} / {_fateController.CycleLimit}" : $"Cycle {_fateController.CompletedCycles + 1}");
ImGui.TextColored(ImGuiColors.DalamudGrey3, text2);
}
if (ImGuiComponents.IconButton(FontAwesomeIcon.Stop))
{
_fateController.Stop("UI stop");
_movementController.Stop();
}
}
private void DrawQuestNames(QuestController.QuestProgress currentQuest, QuestController.ECurrentQuestType? currentQuestType)
{
if (currentQuestType == QuestController.ECurrentQuestType.Simulated)
@ -563,7 +594,7 @@ internal sealed class ActiveQuestComponent
private void DrawQuestButtons(QuestController.QuestProgress currentQuest, QuestStep? currentStep, QuestProgressInfo? questProgressInfo, bool isMinimized)
{
using (ImRaii.Disabled(_questController.IsRunning))
using (ImRaii.Disabled(_questController.IsRunning || _fateController.IsRunning))
{
if (ImGuiComponents.IconButton(FontAwesomeIcon.Play))
{