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

Why does the Part's size not change?

Asked by
Mystdar 352 Moderation Voter
10 years ago
function MakeSpark(pos)
    local effect = game.ServerStorage.Part:Clone()
    effect.Name = "Effect"
    effect.Anchored = true
    effect.CanCollide = false
    effect.Material = Enum.Material.SmoothPlastic
    effect.Locked = false
    effect.TopSurface = 0
    effect.BottomSurface = 0
    effect.BrickColor = Colors[1]
    effect.Size = Vector3.new(8, 8, 8) -- This line, doesn't work
    effect.CFrame = CFrame.new(pos)
    effect.Parent = game.Workspace
end

function HitEffect(pos)
        local thread = coroutine.create(MakeSpark)
        coroutine.resume(thread, pos)

end

Should make a 8x8x8 part appear.

0
output? NinjoOnline 1146 — 10y
0
Eh, well those lines are part of a 200 line long script that works perfectly without it, with it, it just seems to ignore it. Mystdar 352 — 10y
0
The size alone is what's not functioning properly? Everything else is correct, even the parenting and positioning of it? Ravenshield 180 — 10y
0
Maybe swap line 3 and 13 and add this code under line 10?? effect.FormFactor = "Custom" fahmisack123 385 — 10y
0
Correct, RavenShield. Mystdar 352 — 10y

1 answer

Log in to vote
0
Answered by 10 years ago

SImple.

effect.FormFactor=("Custom") 
effect.Size=Vector3.new(8,8,8)

Also line 10 will error.

effect.BrickColor=BrickColor.new("Lime green")

When your using that kind of function function MakeSpark(Pos) you will need to use something like this

--THIS IS NOT THE FUNCTION
MakeSpark(game.Players.LocalPLayer.Character.Torso)
0
Thanks, for the response, i'll test it in the morning, however line 10 will not error, in the table the first 'Color' is [BrickColor.new("Dusty Rose"), etc] Mystdar 352 — 10y
Ad

Answer this question