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

AnimationPlayer unexpectedly toggles visible on calling advance and pause repeatedly #89360

Closed
jackycute opened this issue Mar 10, 2024 · 2 comments

Comments

@jackycute
Copy link

jackycute commented Mar 10, 2024

Tested versions

Godot_v4.3-dev4

System information

Godot v4.3.dev4 - Windows 10.0.19045 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 2070 SUPER (NVIDIA; 31.0.15.3713) - Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz (8 Threads)

Issue description

I used AnimationPlayer.pause() to pause the animation when user stop moving the mouse and resume playing from the same frame when user interact again.
It works perfectly with Godot_v4.3-dev3 but in Godot_v4.3-dev4 it flips visible unexpectedly, thus I only can use speed_scale = 0.0 or seek to let it stop in the current playing frame without changing the visible.
(maybe related to discrete tracks?)

Steps to reproduce

Create an AnimationPlayer with a track that toggle any sprite visible back and forth and make sure it doesn't have any track set "Autoplay on Load".
Assign current_animation with the track and calling advance and pause in _process to step the animation.
Run the scene and you will find the result animation is different from the animation you see in the editor.

Minimal reproduction project (MRP)

animationplayer_pause_issue.zip

@jackycute jackycute changed the title AnimationPlayer jumps to RESET track on calling advance and pause repeatedly AnimationPlayer unexpectedly toggles visible on calling advance and pause repeatedly Mar 10, 2024
@TokageItLab
Copy link
Member

Probably duplicate of #89322, fixed by #89329

@TokageItLab
Copy link
Member

I confirmed #89329 fixed this.

However, the behavior of <| play_backward looks strange, but that behavior has been the same since the beginning of 4.0, so it does not seem to be related. It would be possible to make a separate issue about that.

@TokageItLab TokageItLab closed this as not planned Won't fix, can't repro, duplicate, stale Mar 11, 2024
@TokageItLab TokageItLab removed this from the 4.3 milestone Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants