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

Commit

Permalink
fix: add an option for target all friendly.
Browse files Browse the repository at this point in the history
  • Loading branch information
ArchiDog1998 committed Feb 27, 2023
1 parent 59e5e3a commit 0266366
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion RotationSolver/Actions/BaseAction/BaseAction_Target.cs
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ private bool TargetParty(float range, int aoeCount, bool mustUse, out BattleChar
//找到没死的队友们。
var availableCharas = TargetUpdater.PartyMembers.Where(player => player.CurrentHp != 0);

if ((ActionID)ID == ActionID.AethericMimicry)
if (Service.Configuration.TargetFriendly ? _action.CanTargetFriendly : (ActionID)ID == ActionID.AethericMimicry)
{
availableCharas = availableCharas.Union(TargetUpdater.AllianceMembers);
}
Expand Down
2 changes: 2 additions & 0 deletions RotationSolver/Configuration/PluginConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@ public class PluginConfiguration : IPluginConfiguration
public bool UseHealWhenNotAHealer = true;
public float ObjectMinRadius = 0f;
public float HealthDifference = 0.25f;
public bool TargetFriendly = false;

public Dictionary<ClassJobID, float> HealingOfTimeSubtractSingles { get; set; } = new Dictionary<ClassJobID, float>();

public Dictionary<ClassJobID, float> HealingOfTimeSubtractAreas { get; set; } = new Dictionary<ClassJobID, float>();
Expand Down
1 change: 1 addition & 0 deletions RotationSolver/Localization/Strings_Major.cs
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ internal partial class Strings
public string Configwindow_Param_MoveTowardsScreen { get; set; } = "Using movement actions towards the object in the center of the screen";
public string Configwindow_Param_MoveTowardsScreenDesc { get; set; } = "Using movement actions towards the object in the center of the screen, otherwise toward the facing object.";
public string Configwindow_Param_RaiseAll { get; set; } = "Raise all (include passerby)";
public string Configwindow_Param_TargetFriendly { get; set; } = "Target all for friendly actions(include passerby)";
public string Configwindow_Param_RaiseBrinkofDeath { get; set; } = "Raise player even has Brink of Death";
public string Configwindow_Param_MoveAreaActionFarthest { get; set; } = "Moving Area Ability to farthest";
public string Configwindow_Param_MoveAreaActionFarthestDesc { get; set; } = "Move to the furthest position from character's face direction.";
Expand Down
7 changes: 5 additions & 2 deletions RotationSolver/Windows/RotationConfigWindow_Param.cs
Original file line number Diff line number Diff line change
Expand Up @@ -385,8 +385,11 @@ private void DrawParamTarget()
LocalizationManager.RightLang.Configwindow_Param_MoveTargetAngleDesc);

DrawCheckBox(LocalizationManager.RightLang.Configwindow_Param_MoveAreaActionFarthest,
ref Service.Configuration.MoveAreaActionFarthest,
LocalizationManager.RightLang.Configwindow_Param_MoveAreaActionFarthestDesc);
ref Service.Configuration.MoveAreaActionFarthest,
LocalizationManager.RightLang.Configwindow_Param_MoveAreaActionFarthestDesc);

DrawCheckBox(LocalizationManager.RightLang.Configwindow_Param_TargetFriendly,
ref Service.Configuration.TargetFriendly);

DrawCheckBox(LocalizationManager.RightLang.Configwindow_Param_RaiseAll,
ref Service.Configuration.RaiseAll);
Expand Down

0 comments on commit 0266366

Please sign in to comment.