Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix perspective shift in construction #78493

Merged
merged 1 commit into from
Dec 12, 2024

Conversation

akrieger
Copy link
Member

@akrieger akrieger commented Dec 11, 2024

Summary

None

Purpose of change

Fixes #78489. I broke logic which restored the UI after construction because I misunderstood the side effects of the code in question.

Describe the solution

The old code wrapped the restore_on_out_of_scope in a unique_ptr to allow manually triggering the restore. The broken code was instead cancelling the restore entirely. Put the unique_ptr logic back because that is correct. Keep restore_on_out_of_scope::cancel() because it might still be useful later.

Describe alternatives you've considered

Testing

It's putting the old logic back so it should Just Work (tm).

Reproduced the issue. Applied the fix. Entered and exited construction workflow and view did not stay shifted.

Additional context

@github-actions github-actions bot added <Bugfix> This is a fix for a bug (or closes open issue) Crafting / Construction / Recipes Includes: Uncrafting / Disassembling [C++] Changes (can be) made in C++. Previously named `Code` astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Dec 11, 2024
@Maleclypse Maleclypse merged commit 2a8e243 into CleverRaven:master Dec 12, 2024
28 of 30 checks passed
@akrieger akrieger deleted the disable_warhol_mode branch December 12, 2024 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Crafting / Construction / Recipes Includes: Uncrafting / Disassembling json-styled JSON lint passed, label assigned by github actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

View is slightly bugged when building/deconstructing
2 participants