player = game.Players.LocalPlayer mouse = player:GetMouse() gui = script.Parent Open = false function PressE(key) if (key == "e") then if (Open == false) then for i = 1,0,-0.1 do gui.BackgroundTransparency = i end Open = true elseif (Open == true) then for k = 0,1,0.1 do gui.BackgroundTransparency = k end Open = false end end end mouse.KeyDown:connect(PressE)
This script doesn't label any errors nor does it do anything. Please fix!
If there are no errors, and this does not fuction, consider checking the if statements, and the function. Either "mouse.KeyDown:connect(PressE)" is not activating (could be incorrect), or one of the if statements is not going through. Place print statements along different points in a script. This is known as print debugging. Place one after every if statement, to see which ones are functioning. If all of them are working, that means something is wrong with your gui.