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

Broken undo when changing shader globals #68837

Closed
KoBeWi opened this issue Nov 18, 2022 · 0 comments · Fixed by #69600
Closed

Broken undo when changing shader globals #68837

KoBeWi opened this issue Nov 18, 2022 · 0 comments · Fixed by #69600

Comments

@KoBeWi
Copy link
Member

KoBeWi commented Nov 18, 2022

Godot version

4.0 d93bec6

System information

Windows 10 x64

Issue description

When you change a shader global value in Project Settings, it creates incorrect undo state. You won't be able to undo it with Undo shortcut. History dock shows an empty entry:
image
When you try to go to the beginning, the editor will enter into infinite loop.

The reason why this happens is that when you change a global shader property, it will invoke a second UndoRedo action while another action is committing. This causes history inconsistency.

More details in this PR:
#68799
It fixed the immediate freeze when changing the property, but the undo history issue should be fixed too probably.

Steps to reproduce

  1. Go to Project Settings -> Shader Globals
  2. Add a value
  3. Change it
  4. Try to undo the change
  5. Undoing will cause redo, so the history is stuck
  6. Open History dock
  7. Click The Beginning
  8. 🧊

Minimal reproduction project

N/A

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

Successfully merging a pull request may close this issue.

2 participants