- Home /
The question is answered, right answer was accepted
How to highlight non interactable buttons?
I'm making a platformer game, where I have multiple levels that can be unlocked and later selected in a level selection screen. The locked levels are not interactable until the player unlocks them, but I want the player to be able to navigate through them (with arrow keys or controller) anyway. Unfortunately, the non interactable buttons for the locked levels don't highlight when they are selected, so it's easy to get lost in navigation not having any visual feedback. How would I go about making the buttons highlight even when they are not interactable?
Answer by PalermoVito · Oct 12, 2021 at 03:17 PM
Nevermind, I fixed the problem by adding an image cursor that shows up above the currently selected button, being a substitute for the highlight
Interesting, that's one of many ways to use the Highlight. Thanks for sharing the solution
Of course, I figured since I had such a hard time finding solutions for this, it might help someone in my same situation
Answer by Rechronicle · Oct 12, 2021 at 02:43 AM
I think you can add Button component but ignore all of the settings except the Highlight feature
The problem is that I want the button to work normally, but just disable the onClick function until the level the button gives access to has been unlocked. I've tried removing the listener, but I would need to add the listener back for each button afterwards, while I'm just looking for a way to disable the onClick for a period of time.
Follow this Question
Related Questions
How Do I Make GUI ON Off Button with 2 Button States 3 Answers
Prevent source image change on click 0 Answers
EventSystem.SetSelectedGameObject doesn't highlight button 6 Answers
How can I change the state of a button to "Normal" 0 Answers
How do I stop sound from looping on button press again 1 Answer