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 RichTextLabel bbcode rainbow play reversed and paused #100494

Merged
merged 1 commit into from
Dec 18, 2024

Conversation

havi05
Copy link
Contributor

@havi05 havi05 commented Dec 16, 2024

Adds the abillity to pause and reverse the bbcode rainbow animation as written in the documentation (bbcode_in_richtextlabel)

Adds a new bbcode option:
speed - a negative value will play the animation reversed, a positive value will play the animation forwards, and a value of 0 will pause the animation

I have added the argument speed so that it is possible to change the speed independently of the frequency.
Fixes #85031

@havi05 havi05 requested a review from a team as a code owner December 16, 2024 22:57
@AThousandShips AThousandShips added bug topic:gui cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release cherrypick:4.3 Considered for cherry-picking into a future 4.3.x release labels Dec 17, 2024
@AThousandShips AThousandShips added this to the 4.4 milestone Dec 17, 2024
Copy link
Member

@bruvzg bruvzg left a comment

Choose a reason for hiding this comment

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

Working as expected, code looks good.

@@ -716,7 +717,7 @@ class RichTextLabel : public Control {
void push_shake(int p_strength, float p_rate, bool p_connected);
void push_wave(float p_frequency, float p_amplitude, bool p_connected);
void push_tornado(float p_frequency, float p_radius, bool p_connected);
void push_rainbow(float p_saturation, float p_value, float p_frequency);
void push_rainbow(float p_saturation, float p_value, float p_frequency, float p_speed);
Copy link
Member

Choose a reason for hiding this comment

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

Note: method isn't exposed, so no need for compatibility bind.

@akien-mga akien-mga merged commit e69a561 into godotengine:master Dec 18, 2024
20 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug cherrypick:4.3 Considered for cherry-picking into a future 4.3.x release topic:gui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RichTextLabel BBCode Rainbow animation can't be played backwards or paused
4 participants