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

Commit

Permalink
fix: role actions check.
Browse files Browse the repository at this point in the history
  • Loading branch information
ArchiDog1998 committed Aug 23, 2023
1 parent 58a1039 commit dadc9a2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions RotationSolver.Basic/Rotations/CustomRotation_Actions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ internal RoleAction(ActionID actionID, JobRole[] roles, ActionOption option = Ac
}

internal bool InRole(JobRole role) => _roles.Contains(role);

public override bool CanUse(out IAction act, CanUseOption option = CanUseOption.None, byte aoeCount = 0, byte gcdCountForAbility = 0)
{
return base.CanUse(out act, option, aoeCount, gcdCountForAbility)
&& Player != null && InRole(Player.ClassJob.GameData.GetJobRole());
}
}

/// <summary>
Expand Down

0 comments on commit dadc9a2

Please sign in to comment.