Have you tried using the Game Settings window? This will allow you to override default clothing for characters.
Hmm, i think i noticed something, try using this:
game.ReplicatedStorage:WaitForChild("Events").ShirtEvent1:FireServer()
Also from what i remember, connect is deprecated, use Connect instead.
no i have not, but remember its a customization menu if they are forced to wear a shirt then they cant pick any other clothes
local char = plr.Character or plr.CharacterAdded:Wait()
local shirt = char:WaitForChild(âShirtâ,4.2) â Important
if shirt then print(âPlayer owns a shirtâ) else print(âPlayer does not own a shirtâ) end
I will not give you the code but this is how you know if the player wears a shirt
I am sorrry i forgot to tell you that :WaitForChild can have a time out so the code that iâve gave you wouldnt work because it will wait until a shirt is there.
Theyâll spawn wearing the default clothing youâve set, and then they can change it in your customisation menu. Just use the code others have contributed above.
Okay thank you I will try that, I will get back to you if it doesnât work!
Here is the full code
local plr = game.Players.LocalPlayer
local char = plr.Character or plr.CharacterAdded:Wait()
local shirt = char:WaitForChild("Shirt",1)
if shirt then
shirt.ShirtTemplate = "" --- you're id
else
local newshirt = Instance.new("Shirt")
newshirt.Parent = char
newshirt.ShirtTemplate = "" --- id
end
If it works please click the button solved above
Ok i made them wear plain white clothing thank you for the idea