Skip to content

Merge split fleets#120

Open
tsg21 wants to merge 5 commits intomainfrom
merge-split-fleets
Open

Merge split fleets#120
tsg21 wants to merge 5 commits intomainfrom
merge-split-fleets

Conversation

@tsg21
Copy link
Copy Markdown
Owner

@tsg21 tsg21 commented Apr 11, 2026

No description provided.

@tsg21
Copy link
Copy Markdown
Owner Author

tsg21 commented Apr 11, 2026

@codex review

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d6f9abf8b6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +100 to +101
merged.fleets = merged.fleets.filter(
(fleet) => (fleet.composition ?? []).reduce((sum, c) => sum + c.count, 0) > 0,
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Preserve non-target fleets during merge/split cleanup

Restrict the post-merge cleanup to fleets touched by the merge_split_fleets command; this global filter currently drops any fleet with unknown/empty composition. In player state, visible enemy fleets usually have composition unset, so staging a merge/split immediately removes those enemy fleets from the optimistic view (map/orbit panels) until a refresh, which gives the player an incorrect tactical state.

Useful? React with 👍 / 👎.

id: entry.fleetId,
owner: playerState.player,
name: entry.name ?? entry.fleetId,
position: merged.fleets[0]?.position ?? { x: 0, y: 0 },
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Set tmp fleet position from the merged group location

Use the location of the fleets referenced by the command when creating a tmp_ fleet. This code assigns position from merged.fleets[0], which can be an unrelated fleet elsewhere in the galaxy; in that case, a newly split fleet appears at the wrong coordinates in the optimistic UI and follow-up local actions (selection/waypoint planning) are based on the wrong origin.

Useful? React with 👍 / 👎.

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.

1 participant