This is the part of the code that runs it through, error is in line 91:
Basically, I’m fetching the whole HumanoidDescription; however, the Accessories category inside of a Humanoid is consisted of a string with IDs that need to be separated by a comma, hence why it’s in a different statement in that image. As for the rest of the categories, they all go by singular IDs, so that’s not necessary.
This is the full code:
local EmptyData = {
["Accessories"] = {
["BackAccessory"] = {},
["FaceAccessory"] = {},
["FrontAccessory"] = {},
["HairAccessory"] = {},
["HatAccessory"] = {},
["NeckAccessory"] = {},
["ShouldersAccessory"] = {},
["WaistAccessory"] = {}
},
["Animations"] = {
["ClimbAnimation"] = 0,
["FallAnimation"] = 0,
["IdleAnimation"] = 0,
["JumpAnimation"] = 0,
["RunAnimation"] = 0,
["SwimAnimation"] = 0,
["WalkAnimation"] = 0
},
--["BodyColor"] = 0,
["Package"] = {
["Face"] = 0,
["Head"] = 0,
["LeftArm"] = 0,
["LeftLeg"] = 0,
["RightArm"] = 0,
["RightLeg"] = 0,
["Torso"] = 0
},
["Clothes"] = {
["Shirt"] = 0,
["Pants"] = 0,
["GraphicTShirt"] = 0
},
["BodyColor"] = 0,
["Scale"] = {
["BodyTypeScale"] = 0,
["DepthScale"] = 0,
["HeadScale"] = 0,
["HeightScale"] = 0,
["ProportionScale"] = 0,
["WidthScale"] = 0
}
}
--fetch existing description
local DescriptionData = game.Players.LocalPlayer.Character.Humanoid:GetAppliedDescription()
for category,values in pairs(EmptyData) do
if category == "Accessories" then --Accessories
for name,tables in pairs(values) do
local AssetTransfer = tostring(DescriptionData[name])
local Split = AssetTransfer:split(",")
EmptyData[category][name] = Split
end
else --Other forms that require a singular ID
for name,tables in pairs(values) do
EmptyData[category][name] = (DescriptionData[name])
end
end
end
Any help is appreciated!