im trying to set the variable (myboolvar) from true back to false after i press a onscreen button to prevent the button from being pressed again but that is not the case as i can still press the button as many times as a want so could someone help me to fix this? (line 15)
local myboolvar = nil
myboolvar = true
if myboolvar == false then
end
if myboolvar == true then
local button = script.Parent.Frame.Thebutton
button.MouseButton1Click:Connect(function()
TypeSound:Play()
typewrite(textLabel, "Click the button to continue.",0.1)
TypeSound:Stop()
end)
end
myboolvar = false

5 comments
it shows a error
what is the error it is giving you
Players.person13042.PlayerGui.ScreenGui.LocalScript:10: Expected identifier when parsing expression, got ')'
Oops my mistake try it now
tysm