I have a local script and a boolean value in StarterGui. This local script should change the value in folder at line 11, although for some reason it will not. Does it have anything to do with being a local script?
local part = workspace:WaitForChild("ActivateBurgerJob")
local plr = game.Players.LocalPlayer;
local PlayerModule = require(game.Players.LocalPlayer.PlayerScripts:WaitForChild("PlayerModule"))
local Controls = PlayerModule:GetControls()
local ui = script.Parent;
canSeeGui = script.Parent.Parent:WaitForChild("canSeeGui").Value
local function onTouch(hit)
if plr.Character ~= nil and hit.Parent == plr.Character and canSeeGui == true then
wait(0.2)
canSeeGui = false
Controls:Disable()
ui.Enabled = true
print("Contrls disbaled")
end
end
part.Touched:Connect(onTouch)

2 comments
Thank you this actually fixed everything, I've been going in circles trying to fix this for hours yet I didn't realize it was this small of a fix haha
No problem! Glad I could help :)