Skip to content
This repository has been archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
fix: changed warning in High-end duty.
Browse files Browse the repository at this point in the history
  • Loading branch information
ArchiDog1998 committed Apr 28, 2023
1 parent 3ded391 commit 0f696b7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion RotationSolver/Localization/Strings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -592,6 +592,6 @@ internal partial class Strings
#endregion
};

public string HighEndWarning { get; set; } = "You'd better not use Rotation Solver in {0}!";
public string HighEndWarning { get; set; } = "Please separately keybind damage reduction / shield cooldowns in case RS fails at a crucial moment in {0}!";
public string HighEndBan { get; set; } = "{0} can not be used in High-end Duty!";
}
11 changes: 10 additions & 1 deletion RotationSolver/Updaters/SocialUpdater.cs
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,20 @@ static void ClientState_TerritoryChanged(object sender, ushort e)

static void DutyState_DutyStarted(object sender, ushort e)
{
if(Service.Player == null) return;
if (!Service.Player.IsJobCategory(JobRole.Tank) && !Service.Player.IsJobCategory(JobRole.Healer)) return;

var territory = Service.GetSheet<TerritoryType>().GetRow(e);
if (HighEndDuties.Any(t => t.RowId == territory.RowId))
{
var str = territory.PlaceName?.Value?.Name.ToString() ?? "High-end Duty";
Service.ToastGui.ShowError(string.Format(LocalizationManager.RightLang.HighEndWarning, str));
var message = string.Format(LocalizationManager.RightLang.HighEndWarning, str);
Service.ToastGui.ShowError(message);
Service.ChatGui.PrintChat(new Dalamud.Game.Text.XivChatEntry()
{
Message = message,
Type = Dalamud.Game.Text.XivChatType.ErrorMessage,
});
}
}

Expand Down

0 comments on commit 0f696b7

Please sign in to comment.