Many ways to do this..
One way is to give the settings button an instance variable boolean "active"
on settings clicked
toggle boolean variable
-- settings is boolean
set sprites visible
-- settings is not boolean
set sprites invisible
Also using an else statement could be used for this and many other things..
If instead of setting visible you create and destroy the rest of the sprites, you could prevent the possibility of clicking them, instead of having to add extra conditions for that..