Attaching an accessory to a character, yet it keeps falling off? Ive tried everything?
Asked by
6 years ago Edited 6 years ago
Ive been working on this for about 2 hours now and I am so confused as to why its not working.
I am trying to literally just attach an Accessory to a character.
I am doing this with a local script because I have to, it attaches the stuff to a dummy inside workspace and everyone shares the same dummy so it must be done client side.
Ive tried welding
1 | if m:IsA( "Accessory" ) then |
2 | m:Clone().Parent = workspace.Survivor |
3 | local NewWeld = Instance.new( "Weld" ) |
4 | NewWeld.Part 0 = Character.Head |
5 | NewWeld.Part 1 = workspace.Survivor:FindFirstChild( "Hat" ).Handle |
Which doesnt work
Ive tried flat out parenting the accessory to the character
1 | for j,m in pairs (ReplicatedStorage.Characters [ v.Name ] :GetChildren()) do |
2 | if workspace.Survivor:FindFirstChild(m.Name) then |
3 | workspace.Survivor:FindFirstChild(m.Name):Destroy() |
5 | m:Clone().Parent = workspace.Survivor |
This also doesnt work
And Ive also tried the AddAccessory() function inside a humanoid
1 | if m:IsA( "Accessory" ) then |
2 | local ClonedAccessory = m:Clone() |
3 | workspace.Survivor.Humanoid:AddAccessory(ClonedAccessory) |
5 | m:Clone().Parent = workspace.Survivor |
Which to your surprise also doesnt work.
I have a folder inside ReplicatedStorage with all the characters clothing and hats and stuff.
Let me also mention that I think its an FE problem because all of these work just fine when I press play, but when I run it in server mode, none of them work. But if its an FE problem then how come the shirts and pants still clone to the character?
Anyways I hope someone on here can help me out, this problem is so simple yet so confusing to me. Thanks and have a good day also heres a video that shows whats happening.
https://gyazo.com/baf27b3025f449a3f8c6a33e9569d245