Skip to content

Commit

Permalink
Merge pull request #533 from FFXIV-CombatReborn/mergeWIP
Browse files Browse the repository at this point in the history
forbid movement while mounted setting
  • Loading branch information
CarnifexOptimus authored Dec 31, 2024
2 parents 68ca103 + ccbb776 commit 9ed86f2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion BossMod/AI/AIBehaviour.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ private void AdjustTargetPositional(Actor player, ref Targeting targeting)

private async Task<(NavigationDecision decision, Targeting updatedTargeting)> BuildNavigationDecision(Actor player, Actor master, Targeting targeting)
{
if (_config.ForbidMovement)
if (_config.ForbidMovement || _config.ForbidAIMovementMounted && player.MountId != 0)
return (new NavigationDecision { LeewaySeconds = float.MaxValue }, targeting);

if (_followMaster && (AIPreset == null || _config.OverrideAutorotation))
Expand Down
3 changes: 3 additions & 0 deletions BossMod/AI/AIConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,8 @@ sealed class AIConfig : ConfigNode
[PropertyDisplay("Movement decision delay", tooltip: "Only change this at your own risk and keep this value low! Too high and it won't move in time for some mechanics. Make sure to readjust the value for different content.")]
public float MoveDelay = 0;

[PropertyDisplay("Forbid AI movement while mounted")]
public bool ForbidAIMovementMounted = false;

public string? AIAutorotPresetName;
}
2 changes: 2 additions & 0 deletions BossMod/AI/AIManagementWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ private Task UIAsync()
ImGui.SameLine();
configModified |= ImGui.Checkbox("Forbid movement", ref _config.ForbidMovement);
ImGui.SameLine();
configModified |= ImGui.Checkbox("Forbid mounted movement", ref _config.ForbidAIMovementMounted);
ImGui.SameLine();
configModified |= ImGui.Checkbox("Follow during combat", ref _config.FollowDuringCombat);
ImGui.Spacing();
configModified |= ImGui.Checkbox("Follow during active boss module", ref _config.FollowDuringActiveBossModule);
Expand Down

0 comments on commit 9ed86f2

Please sign in to comment.