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

How to change start and end color particle effects?

Asked by
NotSoNorm 777 Moderation Voter
9 years ago

ok how do I change the start and end rgb values of a particleEmitter?

function onButtonClicked()
    if game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled == false then
game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Left.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Right.PointLight.Enabled = true
game.Workspace.CrowdParticles.One.ParticleEmitter.Color = ColorSequence.new(Color3.new(255/255,255/255,0), Color3.new(0,255/255,255/255))

--Particles

[[
game.Workspace.CrowdParticles.Two.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Three.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Four.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Five.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Six.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Seven.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Eight.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Nine.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Ten.ParticleEmitter.Color.Start 
]] 
--Sides

    elseif game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled == true then
game.Workspace.STAGELIGHTS.BlueStageLights.Left.PointLight.Enabled = false
game.Workspace.STAGELIGHTS.BlueStageLights.Right.PointLight.Enabled = false
game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled = false
end
end
script.Parent.MouseButton1Down:connect(onButtonClicked)

3 answers

Log in to vote
1
Answered by 9 years ago
function onButtonClicked()
    if game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled == false then
game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Left.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Right.PointLight.Enabled = true
game.Workspace.CrowdParticles.One.ParticleEmitter.Color = ColorSequence.new(Color3.new(255/255,255/255,0), Color3.new(0,255/255,255/255))

--Particles

--[[
game.Workspace.CrowdParticles.Two.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Three.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Four.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Five.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Six.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Seven.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Eight.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Nine.ParticleEmitter.Color.Start  
game.Workspace.CrowdParticles.Ten.ParticleEmitter.Color.Start 
--]]  --Thats now how you do a multi line comment you do --[[ Commented stuff in here ]]--
--Sides

    elseif game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled == true then
game.Workspace.STAGELIGHTS.BlueStageLights.Left.PointLight.Enabled = false
game.Workspace.STAGELIGHTS.BlueStageLights.Right.PointLight.Enabled = false
game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled = false
end
end
script.Parent.MouseButton1Down:connect(onButtonClicked)

Ad
Log in to vote
1
Answered by 9 years ago
script.Parent.ParticleEmitter.Color =ColorSequence.new(Color3.new( 0/255, 0/255, 0/255), Color3.new( 0/255, 0/255,0/255))

The First Color3 is StartColour and the Second Color3 is EndColour. :)

0
That's not working :< NotSoNorm 777 — 9y
Log in to vote
-1
Answered by
KenzaXI 166
9 years ago
function onButtonClicked()
    if game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled == false then
game.Workspace.STAGELIGHTS.BlueStageLights.Center.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Left.PointLight.Enabled = true
game.Workspace.STAGELIGHTS.BlueStageLights.Right.PointLight.Enabled = true
--Particles
game.Workspace.CrowdParticles.One.ParticleEmitter.Color.Start.Color3 = Color3.new(255/255,255/255,0)
game.Workspace.CrowdParticles.One.ParticleEmitter.Color.End.Color3 = Color3.new(0,255/255,255/255)

I usually make color changing s cripts and I've always used Color3, However I've never come against (Number/Number, Number/Number), I think your porblems lies there, I read through all the pages in the wiki and yet again never once did I come up against (Number/Number, Number/Number) Try doing this

(255, 255, 255)
0
Color3 arguments are between 0 and 1. That's why you have Color3.new(55/255, 255/255, 0/255) the fraction is between 0 and 1 YellowoTide 1992 — 9y

Answer this question