Skip to content

Fix/building rotation#10809

Merged
someaddons merged 2 commits intoversion/mainfrom
fix/building-rotation
Apr 18, 2025
Merged

Fix/building rotation#10809
someaddons merged 2 commits intoversion/mainfrom
fix/building-rotation

Conversation

@uecasm
Copy link
Copy Markdown
Contributor

@uecasm uecasm commented Apr 18, 2025

Closes #10803

Changes proposed in this pull request

  • Reverts the "level 0 tags" change from Fix building #10804 since it causes weird chunk claims.
  • Fixes incorrect building rotation due to duplicate rotation on cached blueprint.

Testing

  • Yes I tested this before submitting it.
  • I also did a multiplayer test.

Review please (should port, with WO refactor)

@@ -43,13 +46,11 @@ private ConstructionTapeHelper() {}
*/
public static void placeConstructionTape(@NotNull final IWorkOrder workOrder, @NotNull final Level world, final IColony colony)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can't we do it async?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It's already calculated, there's no point calculating it again. Plus the act of calculating it re-rotated the blueprint, since loadBlueprint returns a (possibly cached) pre-rotated copy.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ah, fair

Copy link
Copy Markdown
Contributor Author

@uecasm uecasm Apr 18, 2025

Choose a reason for hiding this comment

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

It's probably bad coding style that calculateCorners (not this one, but the call that was removed) also mutates the blueprint, but that's probably a refactor for another time. I did at least update the javadoc for it 😆

@someaddons someaddons merged commit 501faa4 into version/main Apr 18, 2025
5 checks passed
@someaddons someaddons deleted the fix/building-rotation branch April 18, 2025 11:42
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.

Builders rotate building at 'repair'

3 participants