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

How to change the size of Particles through a script?

Asked by 8 years ago

Hi so I've successfully created a Particle effect and put it into a Brick which were both generated through a sing script. But what I can't seem to figure out is how to make it bigger once it is inside the script? Right now I'm going based off of this system here :

01 brick = Instance.new("Part", game.Workspace) 02 pe = Instance.new("ParticleEmitter", brick) 03 color1 = Color3.new(.62,.62,.62) 04 color2 = Color3.new(.8,.08,.08) 05

06 pe.Color = ColorSequence.new(color1,color2) 07 pe.Rate = 3.5 08 pe.Speed = NumberRange.new(2,2.5) 09 pe.Lifetime = NumberRange.new(.2,2) 10 --Only as an example

And so when I try to type in: "pe.Size = (1)" It basically breaks the tool it is in and I cannot even use it. So my question is how can I make the particles bigger without breaking the script?

0
I can't test this right now but remove the (1) and put pe.Size = 1 if it works tell me and I'll put an answer so you can accept iSvenDerp 233 — 8y
0
Don't forget to accept answers on all your questions! I believe the "Accept Answer" button is on the right side of the post, underneath the poster's username. chess123mate 5873 — 8y

1 answer

Log in to vote
0
Answered by 8 years ago

pe.Size = NumberSequence.new(1)

pe.Size is a NumberSequence, not a number, so you have to give it the proper type. You can read up more on NumberSequences here.

0
Oh okay, thank you. supersayain4 0 — 8y
Ad

Answer this question