✓ Accepted answer
Instead of doing that, you should do this;
local Part = Instance.new("Part", workspace)
local Bc = BrickColor.new("Lavender")
Part.Position = Vector3.new(0, 0, 0)
game.Lighting.ClickDetector.Parent = Part
game.Lighting.ClickDetector.MouseClick:connect(function()
Part.BrickColor = Bc
end)
So it's more reliable using local variables than normal ones. Plus the brick color gotta be in a variable. Plus, you can't change the parent in a script, then get the parent in the script. It's because that you changed it in the script, not the game itself. Plus, scripts only run when you playtest/play, so it won't have the effect of the parent being changed until the game is started. that's why it didn't work. Copy the script above, and it might work.