Button stays "pressed" after being clicked


Is there a way to make a button “pressed” after clicking it and if I click another button the previously selected button back to it’s default color?

Can anybody help me with this?

1 Like

Hi @pkkky

Sure you can, Here an example of just 2 buttons,
For bigger numbers you should add some arrays.

Here i added the style node, in witch you can set some stuff of the button, like the image shown,
(I didnt addedd the image, just pin out any pin in the make button style and add a make slatebrush to fill in the informations)
Or you can add a border to the button, and have that change color.


Thanks for the reply @Est_engine!

I did something like this and I wonder if it is possible to simplify this blueprint?

1 Like

Sure man @pkkky

As you can see you have 4 buttons if they are of the same type, you can list them in an array.
Once you have an array you can use a loop to "Set the background " to everybody with one node,
and using a integer, say to ma White Background to only the n X.

So just call “Highlight” N4 , and be all black but the N 4

“”“”“For Automatic Array , how get the reference to HBOX_A “””"


@Est_engine Thank you!

Hi Est_engine, could you explain this method further please. How do you list the buttons in an Array? Many thanks

Hi man,
As you can see from the upper image, you can use the method B.
That works like this.
Inside your widget add a Boxwidget, and be sure to go in the detail of that box
and set it as a variable, like in the image.

Now you can place any number of buttons inside, (you can do it also by nodes ingame!)
And in the eventgraph you can get a reference to all the buttons, using the nodes in the Commented B.

So get a reference to the Box you created and use the node get all children.
from this you can use the node ForEachLoop to do an action for every child inside…
And as you can see, you can add all of them to a variable array, using add.

so you always able to do an action on all of them by that variable +foreachnode

Let me know if i can help you more @Curnow42