Skip to content

Restore cluster allocations correctly during undo and redo - #10332

Open
AdamZ-8113 wants to merge 1 commit into
PathOfBuildingCommunity:devfrom
AdamZ-8113:fix/cluster-allocation-undo
Open

Restore cluster allocations correctly during undo and redo#10332
AdamZ-8113 wants to merge 1 commit into
PathOfBuildingCommunity:devfrom
AdamZ-8113:fix/cluster-allocation-undo

Conversation

@AdamZ-8113

@AdamZ-8113 AdamZ-8113 commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Description of the problem being solved:

Cluster jewel passives/notables could accidentally be restored due to broken "undo" logic. After unallocating cluster jewel passives, then making a change elsewhere on the tree (add or remove nodes), pressing Ctrl+Z would undo the tree changes and reallocate the cluster nodes -- even if they were removed several changes earlier.

This makes Undo and Redo restore the cluster allocations from the correct step, without bringing back older remembered allocations. It also makes sure the starting Undo history includes the cluster nodes loaded from a saved build, and that nested clusters are rebuilt when their sockets are restored.

Steps taken to verify a working solution:

  • Unallocate a cluster jewel node
  • Allocate any other node(s) on the regular part of the tree
  • Press Ctrl+Z
  • Observe that cluster nodes are no longer being re-allocated
  • Test this from the following states :
  • New build with a cluster jewel created/added
  • Saved build
  • Imported build from account
  • Imported build from a code
  • Test suite passes

Link to a build that showcases this PR:

Before screenshot:

After screenshot:

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