I have a script that if I click the part, it should make it's child, 'Curve' to true but it's not. I put a test if it works by putting 'print ('change')' and it works but 'Curve' isn't changing to true. Please help.
cur = script.Curve.Value
part = script.Parent
clickDetector = Instance.new("ClickDetector", part)
function onMouseClick(player)
print('change')
if not cur == true then
cur = true
elseif cur == true then
cur = false
end
end
clickDetector.MouseClick:connect(onMouseClick)
