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

How to put packages into the players character?

Asked by
PolyyDev 214 Moderation Voter
6 years ago

I have a server script in the StarterCharacterScripts that goes like this

local is = game:GetService("InsertService")
local as = game:GetService("AssetService"):GetAssetIdsForPackage(193700907)
local plr = game.Players.LocalPlayer

for i,v in pairs(as) do
    pack = is:LoadAsset(v)
    for index,item in pairs(pack:GetChildren()) do
        if item.Name == "R6" then
            item:Destroy()
        end
        for l,n in pairs(item:GetChildren()) do
            n.Parent = workspace
        end
    end 
end

How do I get the package to stay on the players body without killing the player in the process?

0
I won't answer with a full answer post because I am not very sure of how you would use this (if anyone does know please use the answer functionality rather than comments like myself) but I would suggest taking a look at the following method to see if it could be used for your needs. http://wiki.roblox.com/index.php?title=API:Class/Player/LoadCharacterAppearance User#18718 0 — 6y

1 answer

Log in to vote
0
Answered by 6 years ago

I don't know much about custom rigs but my guess is

player.Character = customRig
0
He meant a package, not a custom rig. Custom rigs are created yourself packages (2.0, 1.0, 3.0, etc.) are created by ROBLOX. AstrealDev 728 — 6y
Ad

Answer this question