Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Guys can someone help me making this? visit the page and see.

Asked by 8 years ago

Guys I want the people who join my game start on a suit from the game... Can you help me?

3 answers

Log in to vote
0
Answered by 8 years ago
ShirtID = 0000000
PantID = 0000000

Uniform = function(Char)
    local s = Instance.new("Shirt",Char)
    s.ShirtTemplate = ShirtID
    local p = Instance.new("Pants",Char)
    p.PantsTemplate = PantID
end

game.Players.ChildAdded:connect(function(Plr) --Child added used for use in studio
    repeat wait() until Plr.Character
    repeat wait() until Plr.Character:FindFirstChild("Head")
    repeat wait() until Plr.Character:FindFirstChild("Torso")
    wait(1)
    if Plr.Character:FindFirstChild("Shirt") then
        Plr.Character.Shirt:Destroy()
    end
    if Plr.Character:FindFirstChild("Pants") then
        Plr.Character.Pants:Destroy()
    end
    Uniform(Plr.Character)
    Plr.CharacterAdded:connect(function(Char)
        repeat wait() until Char:FindFirstChild("Head")
        repeat wait() until Char:FindFirstChild("Torso")
        wait(1)
        if Char:FindFirstChild("Shirt") then
            Char.Shirt:Destroy()
        end
        if Char:FindFirstChild("Pants") then
            Char.Pants:Destroy()
        end
        Uniform(Char)
    end)
end)

This might work...

Ad
Log in to vote
0
Answered by 8 years ago

Hey... I don't know I joined but It removes the player cloth and didn't add the shirt and pants..

Log in to vote
0
Answered by 8 years ago

You need to edit the following for it to work:

ShirtID = 0000000
PantID = 0000000

The IDs are located in the link of the shirt/pants.

0
Oh ty :D StarInTheSkys 0 — 8y

Answer this question