Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

some reason my scripts are broken?

this script is suppose to open up a gui frame but when i click it it wont open it only opens in studio mode but this script used to work no problem(not a localscript)

script.Parent.MouseButton1Click:connect(function()
script.Parent.Parent.Frame.Visible=true
script.Parent.Parent.Frame.VoteText.Visible=true
script.Parent.Parent.Frame.CloseButton.Visible=true

end)

and this script is suppose to make a block dissapear when you click a button but the button is unclickable it only clicks in studio mode and this script used to work no problem(not a localscript)

Debounce=false
function onClicked()
if not Debounce then
Debounce=true

script.Parent.BrickColor=BrickColor.new("Really red")
Workspace.invisibleD.Transparency=1
Workspace.invisibleD.CanCollide=false
wait(3)
Workspace.invisibleD.Transparency=0
Workspace.invisibleD.CanCollide=true
script.Disabled=true
wait(5)
script.Disabled=false
script.Parent.BrickColor=BrickColor.new("Lime green")
Debounce=false
end
end
script.Parent.ClickDetector.MouseClick:connect(onClicked)

Please Help!

2 comments

0

Well script.Disabled = true... it wont go past that line I think... Also for the first script try making it a localscript

0

By studio mode do you mean solo?

1 answer

I believe(if I am understanding you right) that the problem with you first script is that you are changing only the script in your StarterGui. The issue with that is that is that you would have to die for it to be "updated" because the StarterGui is what you spawn with. Try changing the **PlayerGui **to visible instead. If I am not understanding you correctly please tell me. Hope this helped

1 comment

0

no no you have to understand the scripts used to work in play mode the actual game but it doesnt work in the play mode now only works when i am using studio (editing)

This discussion is preserved as it was. New answers, comments, and votes are closed.