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

How come Color3 isnt working right?

--Dusty Road
local p = script.Parent

p.Touched:connect(function(hit)
		local dust = Instance.new("Part", p)
		dust.Transparency = 1
		dust.Anchored = true
		dust.CanCollide = false
		dust.Size = Vector3.new(1,0.5,1)
		if hit.Parent:FindFirstChild("Humanoid") then
			dust.CFrame = hit.Parent["Right Leg"].CFrame + Vector3.new(0,-2,0)
			local smoke = Instance.new("Smoke", dust)
			smoke.Color = Color3.new(84, 61, 16)--For some reason the smoke is white not brown
			smoke.Size = 0.3
			smoke.RiseVelocity = 0.2
			smoke.Opacity = 0.5
			wait(0.8)
			dust:Destroy()
		end
end)

1 answer

Color3 takes in a decimal value between 0 and 1.

To apply this, simply divide all values by 255.

As a result, it should be:

Color3.new(84/255, 61/255, 16/255)

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