How to check if a Gui/Variable exists?
(before I start i want to let you know this is really long) I was making a game about the UTG (ultimate trolling gui). It is basically a testing zone that will let you do any command from the GUI. But when I click on the "R6" button (makes your character r6 so it can load the utg) a little button pops up at the top and it says "Original Game". I can't find where it comes from as it is not in the r6 script and I can't find it in the GUI itself. I did some research and looked at a plugin that was required in the r6 script but it was just a script that combined the joints and made your character r6. When you clicked on the Original Game button it would teleport you to another game. I made a script that was supposed to remove it whenever it pops up, but i'm having a problem. The script says
1 | playerGui.Rejoin:Remove() |
but it isn't working. I think a script that checks if the "Rejoin" button exists and removes it if it does would work, but I don't know how to check if an item exists. Here is the original script:
1 | local playerGui = script.Parent.Parent |
2 | playerGui.Rejoin:Remove() |
(sorry for the long the backstory, and i dont know how to describe the thing that should be removed)