Skip to content

Comments

Pathfinding improvement#7020

Open
Strogoo wants to merge 1 commit intoFAForever:developfrom
Strogoo:newPathfinding
Open

Pathfinding improvement#7020
Strogoo wants to merge 1 commit intoFAForever:developfrom
Strogoo:newPathfinding

Conversation

@Strogoo
Copy link
Contributor

@Strogoo Strogoo commented Feb 10, 2026

Requires FAForever/FA-Binary-Patches#132

Discussion and vids are here: https://discord.com/channels/197033481883222026/1469005016361861445

Summary by CodeRabbit

  • Bug Fixes

    • Fixed long-distance pathfinding so units no longer adopt column formation for extended moves, improving movement predictability and efficiency.
    • Ensures this pathfinding behavior is applied when starting sessions and after loading saved games.
  • Documentation

    • Added a changelog entry describing the long-distance pathfinding fix.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 10, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds a new SetupPathfinding call to initialize navigator behavior (sets SetNavigatorPersonalPosMaxDistance(9999)) during session setup and after post-load; also adds a changelog snippet documenting fix for issue #7020. (28 words)

Changes

Cohort / File(s) Summary
Pathfinding Configuration
lua/simInit.lua
Adds SetupPathfinding() and calls it after ResetSyncTable in SetupSession and after allied-victory handling in OnPostLoad; sets SetNavigatorPersonalPosMaxDistance(9999) with explanatory comments to alter long-distance move behavior.
Changelog Entry
changelog/snippets/fix.7020.md
Adds a changelog snippet for issue #7020: "Fix pathfinding by disabling column formation for long-distance moves."

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐇 I nudged the paths and hopped along,
Columns loosened, steps grow strong,
Long moves wander, finding ground,
I left a note and hopped around,
— Rabbit cheers the changelog song.

🚥 Pre-merge checks | ✅ 1 | ❌ 2
❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Description check ⚠️ Warning The description is largely incomplete and does not follow the required template structure, missing critical sections like description of changes, testing done, and proper documentation. Complete the description by filling in the required sections: clearly describe the pathfinding changes, document all testing performed, fill the checklist, and verify changelog compliance with guidelines.
Title check ❓ Inconclusive The title is vague and generic, using non-descriptive language that doesn't clearly convey the specific nature of the pathfinding change or its primary objective. Replace with a more specific title that clearly describes the main change, such as 'Disable column formation for long-distance pathfinding' or 'Configure navigator positioning for improved pathfinding behavior.'
✅ Passed checks (1 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

No actionable comments were generated in the recent review. 🎉


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@changelog/snippets/fix.7020.md`:
- Line 1: Update the changelog snippet text to hyphenate the compound adjective:
replace "long distance moves" with "long-distance moves" in the string "(`#7020`)
Fix pathfinding by disabling column formation for long distance moves." so the
sentence reads "(`#7020`) Fix pathfinding by disabling column formation for
long-distance moves."

In `@lua/simInit.lua`:
- Around line 225-231: Fix the typo in the comment near
SetNavigatorPersonalPosMaxDistance(9999): change "waipoints" to "waypoints" in
the explanatory block so the comment reads "...using personal positioning
instead of waypoints for any move order...". Ensure only the comment text is
updated and the function call SetNavigatorPersonalPosMaxDistance remains
unchanged.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@lua/simInit.lua`:
- Around line 224-231: The SetNavigatorPersonalPosMaxDistance(9999) call is only
in SetupSession and must also be invoked when a save is loaded; modify the
OnPostLoad() function to reapply SetNavigatorPersonalPosMaxDistance(9999) (place
it alongside other session/initialization calls in OnPostLoad) so loaded games
use the same navigator behavior as new sessions; reference
SetNavigatorPersonalPosMaxDistance, SetupSession, and OnPostLoad to locate where
to add the call.

@vjt4
Copy link
Contributor

vjt4 commented Feb 10, 2026

I'm not on the team or contributor or anything, but 100% agree, based on the videos.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants