Hello community,
I have recently made a Main Menu Gui with the help of a tutorial. The past day or so I’ve spent customizing it / learning the script and decided to make it so the buttons would change size when hovered over with a mouse.
The issue:
Though the function works it doesn’t work well when a player enters and leaves the button rapidly resulting the button Gui to stay one size.
Solutions that i’ve tried:
Adding a wait
Adding an if statement
Conclusion:
Any help is appreciated especially since I am somewhat new to scripting and don’t have a firm understanding quite yet.
I have found that this way isn’t very efficient. What I do is add a debounce to the MouseEntered event and don’t check for when the player’s mouse leaves the button, but if their mouse isn’t over the button and then descale it. The problem with doing it that way is the events interfere with eachother.
I found a solution to the issue! Though I had tried both of the solutions below (Thanks a ton still!) I found an discussion that said I needed to add a “true” to the end of the tweens. Works like a charm now, thanks for the help everyone!