I'm trying to make a simulator game and there is a wall blocking another area which you need 100 cash to pass-through here is the script:
~local rc = 100
local debounce = true script.Parent.Touched:Connect(function(hit) if hit.Parent:FindFirstChild("Humanoid") then local player = game.Players:GetPlayerFromCharacter(hit.Parent) if player.leaderstats.Cash.Value >= rc then if debounce then debounce = false script.Parent.Transparency = 0.5 script.Parent.CanCollide = false if rc <= rc then script.Parent.Transparency = 0.15 script.Parent.CanCollide = true end end end end end)~
it says that rc doesn't have a value to change but it clearly does how do I fix this?

2 comments
Please format your script by clicking the Lua button.
How