How to make when a proximity prompt is triggered it changes the players clothes

How to make when a proximity prompt is triggered it changes the players clothes?

1 Like

should work:

local shirtId = 123456 --change this to the shirtId you want the player to wear and set it to nil if you don't want their shirt to change.
local trousersId = 123456 --change this to the pantsId you want the player to wear and set it to nil if you don't want their pants to change.
local ProxPromt = script.Parent --assuming this script is under the prompt

ProxPrompt.Triggered:Connect(function(plr)
    if plr.Character:FindFirstChildWhichIsA("Shirt") and shirtId~= nil then
         plr.Character.Shirt.ShirtTemplate = "rbxassetid://"..shirtId
    elseif shirtId ~= nil then
        shirt = Instance.new("Shirt")
        shirt.Parent = plr.Character
        shirt.ShirtTemplate = "rbxassetid://"..shirtId
    end

    if plr.Character:FindFirstChildWhichIsA("Pants") and trousersId~= nil then
         plr.Character.Shirt.ShirtTemplate = "rbxassetid://"..trousersId
    elseif trousersId ~= nil then
        pants = Instance.new("Pants")
        pants.Parent = plr.Character
        pants.PantsTemplate = "rbxassetid://"..trousersId
    end
end)
2 Likes

you cant ask people for scripts here lol

1 Like

Oh, come on! I just slaved away writing a full script for him!

Yeah, the dev fourm really has became skidded in the past year or two. Most people who help people do it to get a solution and they generaly can only write low-quality code and don’t know more advanced things. I’ve seen countless posts where more adanced questions are asked and nobody responds (like this one which was at the bottom of my ‘suggested topics’ page.) It really is screwed and I’d prefer to ask for help with bigger things somewhere else, like reddit.

1 Like

lol thats very true nowadays the #help-and-feedback:scripting-support isnt like before

1 Like

Lol - I’m usually lurking in Development Discussion as I actually enjoy reading the posts there.

Well, do you have a system in place? Were not here to script things for you, we are here to fix and alter code you have made. If you want to hire a scripter to do it for you, go here: #collaboration.