Skip to content

Fix fade out duration to extend a bit take into account current delta in NodeOneShot #106567

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

TokageItLab
Copy link
Member

@TokageItLab TokageItLab commented May 18, 2025

I think the cause of the issue is that the delta is subtracted immediately, so the fadeout duration is shortened by one frame. This may be a bit of a hack, but it can be solved by extending the duration by delta which will be subtracted in advance.

@TokageItLab TokageItLab added this to the 4.x milestone May 18, 2025
@TokageItLab TokageItLab requested a review from a team as a code owner May 18, 2025 17:23
@TokageItLab TokageItLab requested a review from a team as a code owner May 18, 2025 17:23
@TokageItLab TokageItLab changed the title Fix fadeout dur Fix fade out duration to extend a bit take into account current delta May 18, 2025
@TokageItLab TokageItLab removed the request for review from a team May 18, 2025 17:23
@TokageItLab TokageItLab changed the title Fix fade out duration to extend a bit take into account current delta Fix fade out duration to extend a bit take into account current delta in NodeOneShot May 18, 2025
@TokageItLab TokageItLab requested a review from a team May 18, 2025 17:31
@TokageItLab TokageItLab moved this to Ready for review in Animation Team Issue Triage May 18, 2025
@TokageItLab TokageItLab modified the milestones: 4.x, 4.5 May 19, 2025
@BlackShift
Copy link
Contributor

I was able to build and test the MRP from the issue against this PR and it does solve the problem. I agree that there is an off by one error and a simple one liner fix is all that's needed.

I can test it against a more complicated animation tree if given more time, but it seems to fix the issue.

As mentioned in my PR I'm not very familiar with the animation code, so I don't think I can give a quality review, but I'll close that one in favor of this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Ready for review
Development

Successfully merging this pull request may close these issues.

[Animation] AnimationNodeOneShot fails to trigger animation_finished signal at high frame rates.
2 participants