Hey, I was just wondering if anyone knew how to make this code so not only does it spawn the hat onto the player, but it also spawns it slightly larger since currently it looks too small?
P.Size doesn't create the mesh larger, it remains the same size no matter the size I put in.
h = Instance.new("Hat") p = Instance.new("Part") p.Name = "Handle" p.Size = Vector3.new(2,1,1) m = Instance.new("SpecialMesh") m.MeshType = "FileMesh" m.MeshId = "http://www.roblox.com/Asset/?id=" m.TextureId = "http://www.roblox.com/asset/?id=" h.Parent = character p.Parent = h p.Position = character.Head.Position m.Parent = p w = Instance.new("Weld") w.Parent = character.Head w.Part1 = w.Parent w.Part0 = p w.C0 = CFrame.new(Vector3.new(0,-0.53,0))
Don't change the part's size, change the mesh's scale value. To do this simply use:
m.Scale = Vector3.new(3,3,3) -- 3x the size.
In your case, use this script:
h = Instance.new("Hat") p = Instance.new("Part") p.Name = "Handle" p.Size = Vector3.new(2,1,1) m = Instance.new("SpecialMesh") m.MeshType = "FileMesh" m.MeshId = "http://www.roblox.com/Asset/?id=" m.TextureId = "http://www.roblox.com/asset/?id=" m.Scale = Vector3.new(2,2,2) -- Here's the scaling line! h.Parent = character p.Parent = h p.Position = character.Head.Position m.Parent = p w = Instance.new("Weld") w.Parent = character.Head w.Part1 = w.Parent w.Part0 = p w.C0 = CFrame.new(Vector3.new(0,-0.53,0))
Use this if you need any extra information on the scale property.
If this worked for you or helped you, please vote up and accept this as the answer!
Or you could get the Model Resizer plugin.
Step 1 Open RStudio
Step 2 go to plugins
Step 3 find get plugins
Step 4 get the Model Resizer... P.S. For 2015 viewers its on the front page.
Step 5 find the mesh hat in the giver
Step 6 put it into workspace and grab yellow spheres and drag to preferred size ( they might not appear, if so restart rstudio)
Step 7 put the mesh hat back in place it was...
Step 8 say THANKS DUDEFUN and why is your name so weird and ur done yay xox have fun hope it works lol this is random xD happy halloween, but if ur reading this after halloween happy whatever holidays next thx byeee.