Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I change the color of the bricks in the following script?

Asked by 5 years ago

wait(2)

workspace:WaitForChild("PartStorage")

deb = true

script.Parent.Clicker.ClickDetector.MouseClick:connect(function(wat)

if deb == true then

deb = false

local part = Instance.new("Part",workspace.PartStorage)

part.BrickColor=script.Parent.Parent.Parent.DropColor.Value

part.Material=script.Parent.Parent.Parent.MaterialValue.Value

local cash = Instance.new("IntValue",part)

cash.Name = "Cash"

cash.Value = 1 -- How much the drops are worth

part.CFrame = script.Parent.Drop.CFrame - Vector3.new(0,1.3,0)

part.FormFactor = "Custom"

part.Size=Vector3.new(1, 1, 1) -- Size of the drops

part.TopSurface = "Smooth"

part.BottomSurface = "Smooth"

game.Debris:AddItem(part,20) -- How long until the drops expire

wait(.15)

deb = true

end

end)

I would like the script.

0
Please use the code block so the script becomes readable. LisaF854 93 — 5y
0
Add part.Color = Color3.new(number r, number g, number b) somewhere near all the other part properties that are set. https://developer.roblox.com/api-reference/datatype/Color3 MegaManSam1 207 — 5y

Answer this question