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

How do I change the size of a Part using a script?

I simply want to change the size of a Part with a script, I tried to see if I can change it on my own but it doesn't seem to work. Please help! :( Below is my attempted code.

Part = script.Parent



function partShrink()
	Part.Size = 1,1,1
end



partShrink()

1 answer

✓ Accepted answer

Size is not simply 3 different numbers, but rather a Vector3. As such, you need to construct a new Vector3 with Vector3.new(x, y, z) and assign Part.Size to that:

Part.Size = Vector3.new(1, 1, 1)

1 comment

0

This worked, thanks! :)

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