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

Can someone please Help me with this?

Asked by 10 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.

I'm Making a Gui that inserts a Part onClicked the Part Inserts but the size doesn't change Can Some One Please Help?

function onMouseButton1Click()
    p = Instance.new("Part", game.Workspace)
    p.Anchored = true
    p.Size = UDIM2.new(12.04, 9.69, 2)
end
script.Parent.MouseButton1Click:connect(onMouseButton1Click)

1 answer

Log in to vote
1
Answered by
Muoshuu 580 Moderation Voter
10 years ago

Parts use Vector3, GUIs use UDim2

function Click()
    local Part=Instance.new("Part",workspace)
    Part.Anchored=true
    Part.FormFactor="Custom"
    Part.Size=Vector3.new(12.04,9.69,2)
end
Ad

Answer this question