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

Size of a part not changing?

When I try to change the size of a part it won't change, even with Vector3. Here's the code:

local part = script.Parent

if true then
	part.Size = Vector3.new(part.Size.X(9),part.size.Y(1),part.size.Z(1))
end

1 comment

0

Just add the numbers without adding “Part.size.X,Y,Z”. It works like that

1 answer

Howdy!

That's not really how to set a Vector3 value. According to the Roblox Documentation on Vector3 Values, all you need to define is the X, Y, and Z value to set it to. You don't need to set where it goes to, as it is predefined by a format.

For example, if you wanted to change the size of a part in the workspace, you would use what I have below.

local part = workspace.Part
part.Size = Vector3.new(5, 20, 100)

If this helped you out, consider accepting this answer for those sweet, sweet reputation points. If not, comment below and I (or someone else) will help you out.

##Be sure to check out the Roblox API Documentation as well for additional reference.

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