Enable Disabled script

Hello, there’s a simple and maybe dumb quote. If I enable a script that was disabled, using coding, the script will run? or something needs to happent to it to start running?
Example:

local script = game.StarterGui.LocalScript
 
wait(10)
script.Disabled = false --Will the code that is in this script run now that it is enabled?

Well changing elements in the StarterGui won’t have an affect in real time as that’s just the container for holding UI elements to be cloned into the PlayerGui, which is what you want to edit

kk, so will it run now?

local script = game.Players.LocalPlayer.PlayerGui.LocalScript
 
wait(10)
script.Disabled = false

It might error because the PlayerGui hasn’t loaded yet, but if you use WaitForChild() on the PlayerGui and then the LocalScript it should work

Exactly what I wanted to hear :slight_smile: thanks a lot!