Hi i created a part that when u click it disable a script that contains the ”MainScript”, and it works, but.. it just that when i enable the script, the script woldnt work, do u guys know why? :D i use this script to”close it”:
MainGame = game.ServerScriptService.MainGame function onClick(click) wait(0.5) MainGame.Disabled = true end script.Parent.ClickDetector.MouseClick:connect(onClick)
and to ”open it” :
MainGame = game.ServerScriptService.MainGame function onTouch(hit) wait(0.5) MainGame.Disabled = false end script.Parent.Touched:connect(onTouch)
but,as i sayd, when you ”open it” it woldnt work...
Try disabling the script, then in your script enable it when it is clicked that should work I think.