Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Is it possible to make a clickdetector uptade a GUI?

Asked by 6 years ago

Hey guys! I wanted to make a game about clicking on random things, for example a computer. But I ran into a problem while making this game. I want that if you click on something, the GUI uptades and for example 1/5 things have clicked and they can only click once, so it does not break and if you click on the same object 5 times you win, that's not what I want! Thanks guys if you know this bye! (Sorry for the bad english!)

1 answer

Log in to vote
0
Answered by 6 years ago

Yeah it's possible, you can make a table of items that were clicked, then everytime you click on something you iterate through the table of clicked items and check if it was already clicked.

If yes then just break out of the loop, if not then update your gui and add the item to the table.

You can store items in the table by their name btw, and then check if clickdetector.Parent.Name == that name in the table.

Ad

Answer this question