Issue parenting a specialmesh to the character

So I have a remote event which fires and executes codes and just one part of the code doesn’t really work as intended which is this line:

medalAsset.Handle.SpecialMesh:Clone().Parent = player.Character:FindFirstChild("UpperTorso")

The avatar is R15 of course. Imagine the special mesh is a medal in server storage, I’m trying to create a clone and make the clones parent the character’s upper torso so that it appears visible on the upper torso. Not working out. Not creating a clone does not make a difference. I’m pretty sure my issue is nomenclature/referencing.

2 Likes

I think the Handle has to also be cloned rather than just the SpecialMesh parented to it.

The SpecialMesh object applies a mesh to a BasePart

SpecialMeshes have to be parented to a BasePart to function.

2 Likes

Thanks, your solution worked, the parenting was a success, however, after the parenting, for some reason, I can’t see the special mesh, it’s not on the avatar even though it was parented into the uppertorso according to the Explorer.

The handle is not transparent and the special mesh has its texture and mesh ids inserted as normal. Can’t figure out what I’m missing.

You can imaging that I’m trying to add an accessory onto the avatar.

1 Like

You’d also need to weld it to the part you’re attaching it to. I’m guessing you can’t see the part because it’s fallen to the ground…

-- clone the medal thing
local medalAssetClone = medalAsset.Handle:Clone()
medalAssetClone.Parent = player.Character

-- weld it 
local weld = Instance.new("Weld")
weld.Part0 = player.Character:FindFirstChild("UpperTorso")
weld.Part1 = medalAssetClone
weld.Parent = medalAssetClone

Now if you don’t know how to work with welds much, you might notice that this puts the medal thing at the center of the UpperTorso part. You might want to adjust the offset of the weld, like

weld.C0 = CFrame.new(0,1,-0.5) -- this puts it at front, top of the torso
3 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.