It says to include code 'snipits', but this is a short script so I will include the whole thing, as well as an explanation of what I am trying to do.
wait(60) game.StarterGui.Purgetime.TextButton.Script.Disabled = false game.StarterGui.Waittime.TextButton.Script.Disabled = true if true then wait(720) game.StarterGui.Purgetime.TextButton.Script.Disabled = true game.StarterGui.Waittime.TextButton.Script.Disabled = false end
Basically, I am creating a game based off of the movie "The Purge"
What I am trying to do, as you might be able to see is turn the timer script in the GUIs I have off/on at intervals. The Waittime GUI is where the players will wait in the lobby, then when the Waittime GUI is disabled, and the Purgetime GUI is enabled different timers will be active/inactive. My goal is to have an interval where one Script is active while the other is not, wait a certain amount of time, then make the inactive script active, and the active script inactive.
The problem: Nothing is happening when I run the game. Both scripts still run normally, without being activated or deactivated. Thanks!
===========Note: I would also like the script to loop, but I am not sure how..==========
You didn't put what the if statement is checking. Just
if true then
won't work. If you want one of these Disabled properties to be checked, you have to insert them in the if line. Like this:
if game.StarterGui.Purgetime.TextButton.Script.Disabled == true then
Or this:
if game.StarterGui.Waittime.TextButton.Script.Disabled == true then
But beyond that, I didn't understand what you mean, sorry.