Skip to content
TheChatArchiveThe Chat Archive
gpt-3.5-turbo-0613· OpenAIAi2 WildChat-4.8M (AI2)

make scirpt from roblox studio that make you wear clothes like an account

  1. User

    make scirpt from roblox studio that make you wear clothes like an account

  2. Assistant

    Sure, here's a script that you can use in Roblox Studio to make your character wear clothes like another account:

    -- Define the account ID of the user whose clothes you want to copy
    local accountId = "PUT_ACCOUNT_ID_HERE"
    
    -- Function to equip clothes of a given user
    local function equipClothes(userId)
        -- Get the character model of the specified user
        local character = game:GetService("Players"):GetCharacterAppearanceAsync(userId)
    
        -- Loop through each part of the character model and equip it to your own character
        for _, assetId in pairs(character.Assets) do
            local asset = game:GetService("InsertService"):LoadAsset(assetId)
            local clothing = asset:GetChildren()[1]
    
            -- Equip the clothing to your own character
            clothing.Parent = game.Players.LocalPlayer.Character
        end
    end
    
    -- Check if the account id is valid
    local function isValidUserId(userId)
        local success, result = pcall(function()
            game:GetService("Players"):GetNameFromUserIdAsync(userId)
        end)
        return success
    end
    
    -- Equip clothes of specified account ID
    if isValidUserId(accountId) then
        -- Call the function to equip the clothes of the specified account
        equipClothes(accountId)
    else
        warn("Invalid Account ID")
    end
    

    Replace "PUT_ACCOUNT_ID_HERE" with the actual account ID of the user whose clothes you want to copy. Then, insert this script into any Roblox object (e.g., a Part or a Script) in the Roblox Studio, and when you run the game, the script will automatically equip all the clothes from the specified user to your own character.