Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Why is the baseplate turning black?

script.Parent.MouseButton1Click:Connect(function()
	game.Workspace.Map.Baseplate.BrickColor = BrickColor.new(Color3.new(script.Parent.BackgroundColor3))
end)

A simple script that is supposed to turn the baseplate brickcolor to the background color of the button. Instead it just turns black.

2 comments

0

Instead of making a color3 just set the BrickColor to the BackgroundColor3 itself without wrapping it in a Color3.new

0

Since Bricks in general just use "BrickColor" through scripts, it tries to turn your buttons RGB color3 numbers into a BrickColor, this just turns out to be black.

1 answer

✓ Accepted answer

Make it simpler for yourself and just set them equal to one another:

script.Parent.MouseButton1Click:Connect(function()
    game.Workspace.Map.Baseplate.BrickColor = script.Parent.BackgroundColor3
end)

This discussion is preserved as it was. New answers, comments, and votes are closed.