Skip to content

[BUGFIX] Fix Two Issues With Song Text on Freeplay Capsules #5036

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 2 commits into
base: develop
Choose a base branch
from

Conversation

VioletSnowLeopard
Copy link
Contributor

@VioletSnowLeopard VioletSnowLeopard commented May 7, 2025

Linked Issues

Fixes #4876. Fixes #2659.

Description

When switching song lists (changing filters or difficulties) from a song not in the new list, its text would remain highlighted when you switched back to the list it is in. This PR fixes the issue by setting the selected value of the capsule to false before the song list might change.

I also made an adjustment in SongMenuItem.hx to fix the squashed text. A detailed description of the change is in a comment below.

Screenshots/Videos

Video of song text not being highlighted:

song-text-not-highlighted.mp4

After the 0.6.4 update, there were three scenarios I found that would always result in a capsule having squished text which is shown below:

song-text-squish.mp4

Here, you can see these same scenarios no longer produce squished text:

no-text-squish.mp4

unintentionally fixes song text squishing
@github-actions github-actions bot added size: small A small pull request with 10 or fewer changes. pr: haxe PR modifies game code. status: pending triage Awaiting review. labels May 7, 2025
@Hundrec
Copy link
Collaborator

Hundrec commented May 7, 2025

Could it really be? The one to fix the squashed text?

@Hundrec Hundrec added type: minor bug Involves a minor bug or issue. topic: freeplay Related to the operation of the Freeplay menu. labels May 7, 2025
@VioletSnowLeopard
Copy link
Contributor Author

Could it really be? The one to fix the squashed text?

Would be funny since it wasn't the issue I was originally trying to fix.

@Lasercar
Copy link
Contributor

Lasercar commented May 7, 2025

Now we just have to figure out why the capsules started sometimes getting that weird y offset in 0.6

Also, I find it funny that's despite the squashed text being unintentionally fixed, we still don't know how exactly it's caused in the first place

@trayfellow
Copy link

trayfellow commented May 7, 2025

Could it really be? The one to fix the squashed text?

Hundrec. I Need A Compiled Build. I Need To Test This. Yeah I Can't Be Bothered To Waste 20GB On My Storage Space For Funkin'

@VioletSnowLeopard
Copy link
Contributor Author

Could it really be? The one to fix the squashed text?

Hundrec. I Need A Compiled Build. I Need To Test This. Yeah I Can't Be Bothered To Waste 20GB On My Storage Space For Funkin'

If you want a compiled build for Windows, I can zip the one I have. You can download it here if you want to try it.

Copy link
Contributor

@JVNpixels JVNpixels left a comment

Choose a reason for hiding this comment

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

thats it? just 2 lines? thats all it takes to fix 2 of my annoyances of the freeplay menu?

@Hundrec
Copy link
Collaborator

Hundrec commented May 8, 2025

aw

image

I got this by entering and exiting Stress on Hard

(This does fix the highlighting though)

@Lasercar
Copy link
Contributor

Lasercar commented May 8, 2025

aw

I got this by entering and exiting Stress on Hard

(This does fix the highlighting though)

We've been foiled again by the squashed text

@VioletSnowLeopard
Copy link
Contributor Author

aw
I got this by entering and exiting Stress on Hard

(This does fix the highlighting though)

Are you able to get this consistently? Did you do anything before entering Stress? Because I can't seem to get this to occur.

@trayfellow
Copy link

aw
I got this by entering and exiting Stress on Hard
(This does fix the highlighting though)

We've been foiled again by the squashed text

My worst enemy.... just like The Lich from Adventure Time, this stupid thing just wont go away no matter what

@VioletSnowLeopard
Copy link
Contributor Author

With this PR, I have found a way to reliably reproduce the squashed text on one of the capsules. I can try to figure out how it happens through debugging later.

@Hundrec
Copy link
Collaborator

Hundrec commented May 8, 2025

I left a comment under the squashed text issue outlining how to reproduce the bug by switching variations. Hopefully that's helpful!

@VioletSnowLeopard
Copy link
Contributor Author

Using debugging, I have found the problematic function. Whenever a capsule has squashed text, its x scale has a value of 0.4 and its y scale has a value of 1.4. The function that sets the text's scale values to this is textAppear. It seems that sometimes the second FlxTimer fails to work so the text's scales aren't reset to 1.

The purpose of textAppear is to make the text do a little jump back and forth animation. You can see this whenever you hit confirm on a song. Apparently this also happens to all capsules whenever changing difficulties or entering the menu, although I've never noticed it. I believe it happens at a point before the capsules are visible again.

Considering textAppear is the function that causes this issue and its functionality isn't ever noticeable aside from hitting confirm on a song, I removed the call to the function in setVisibleGrp. To allow it to still work when hitting confirm on a song, I added a call to it inside the confirm function in SongMenuItem.

@github-actions github-actions bot added size: medium A medium pull request with 100 or fewer changes. and removed size: small A small pull request with 10 or fewer changes. labels May 8, 2025
@AbnormalPoof
Copy link
Collaborator

It was that simple??

@VioletSnowLeopard
Copy link
Contributor Author

I mean, at first I tried to call the song text's resetText function in various places to try and reset the scale of the text, but it didn't work. So I just decided that the song text scale should not be changed when switching difficulties.

@Hundrec
Copy link
Collaborator

Hundrec commented May 8, 2025

Thanks for investigating! It's time to stress test this to the max!

@Hundrec Hundrec self-requested a review May 8, 2025 21:11
Copy link
Collaborator

@Hundrec Hundrec left a comment

Choose a reason for hiding this comment

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

I think you've done it!
You've finally freed us from this curse...

@VioletSnowLeopard
Copy link
Contributor Author

I think you've done it! You've finally freed us from this curse...

The cursed function textAppear

Copy link
Collaborator

@AbnormalPoof AbnormalPoof left a comment

Choose a reason for hiding this comment

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

peak

Copy link
Contributor

@JackXson-Real JackXson-Real left a comment

Choose a reason for hiding this comment

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

Merge this PR immediately! 🗣️ 🔥

@Lasercar
Copy link
Contributor

Lasercar commented May 9, 2025

Thought I'd try making the timers a variable and only allow it to be set if it's null or finished to see if it'd fix it and nope!

It seems to do it the first time you letter switch, so yeah, just disable it entirely, I've had enough.

@EliteMasterEric EliteMasterEric added size: small A small pull request with 10 or fewer changes. and removed size: medium A medium pull request with 100 or fewer changes. size: small A small pull request with 10 or fewer changes. labels May 14, 2025
Copy link
Member

@Kade-github Kade-github left a comment

Choose a reason for hiding this comment

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

very good, will be merged in the next update.

@AbnormalPoof AbnormalPoof added status: accepted PR was approved for contribution. If it's not already merged, it may be merged on a private branch. and removed status: pending triage Awaiting review. labels May 26, 2025
@AbnormalPoof AbnormalPoof added this to the 0.7.0 milestone May 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: haxe PR modifies game code. size: small A small pull request with 10 or fewer changes. status: accepted PR was approved for contribution. If it's not already merged, it may be merged on a private branch. topic: freeplay Related to the operation of the Freeplay menu. type: minor bug Involves a minor bug or issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants