Answered by
4 years ago Edited 4 years ago
Hi! I think I can help with this, although I too am new to scripting so bear with me. You said that when you remove the shirt, your script is stuck in a waitforchild loop. In order to avoid this, try this:
1 | game.ReplicatedStorage.startShirt.OnServerEvent:Connect( function (plr) |
2 | local char = plr.Character |
3 | char:WaitForChild( "Shirt" ):Destroy() |
4 | local newshirt = game.ReplicatedStorage.Customisation.Shirts.sShirt 1 :Clone() |
5 | newshirt.name = "Shirt" |
I hope this helps, if it does please remember to make it easier on other people trying to help and accept this answer. Comment with any questions :)