Why is this script not able to Find the BoolValue?

What I’m Doing

I’m in the process of making a Cutscene Toggle Button so people don’t have to experience cutscenes as they may take a very long time depending on the speed of the PC/Laptop in use.

The issue

The issue is that it’s not identifying the CutsceneValue which is a BoolValue.
image
As you can see below, it is there but it refuses to identify the CutsceneValue.
image

Solutions I’ve Tried

I originally had everything going through just the Client but I realized that I had to remove the Cutscene Folder for the Client through the Server so my Cutscene actually registered that the folder was removed.

What works

Everything in the script works except the lines that are to identify the CutsceneValue [A BoolValue].

Why?

Only read this if you want to know why i’m doing all of this.

The reason i’m going through all of this process is to release it to a public at some point so everyone could have a stable Cutscene System that can be turned off if desired.
Another reason i’m going through all of this process is so Players who have the Cutscene Folder deleted don’t have their camera fixed for no reason as that can cause complaints down the line.

The Script

Again, the only thing that doesn’t work is the CutsceneValue lines.

--Made By MillerrIAm
-------------Variables------------
Event = game.ReplicatedStorage.ExtraEvents.CutsceneDisabler
------------Main Script------------
Event.OnServerEvent:Connect(function(plr,Checking)
	local playergui = plr.PlayerGui 
	if Checking == "Active" then
		if not playergui:FindFirstChild("Cutscenes") then
			local Folder = Instance.new("Folder")
			Folder.Name = "Cutscenes"
			Folder.Parent = plr.PlayerGui
		end
		playergui.CameraSystem.CutsceneValue = false
	elseif Checking == "Inactive" then
		playergui.Cutscenes:Destroy()
		playergui.CameraSystem.CutsceneValue = true
	end
end)

Thank you to anyone who helps me with this issue.

Was the value created manually or are you doing it via script?

Edit: One more thing I’ve noticed is; you’re doing playergui.CameraSystem.CutsceneValue = true instead of playergui.CameraSystem.CutsceneValue.Value = true

1 Like

The BoolValue was already made.

I’m changing it’s Value through the script though.
image

Oh yeah as I said, the issue was that you weren’t setting it’s value, you were trying to set the value(object) itself to true/false which isn’t possible.

1 Like