Release Notes for 369

HumanoidDescription is a new object that represents components of a Humanoid’s appearance, such as accessories, animations, packages, etc.

I believe the goal of this system is to make it easier for developers to apply existing/custom costumes to R15 rigs, without needing to cover all existing/future edge-cases with the system.

There are lots of components to Roblox’s avatar system, each with their quirks and rules, so it helps to have it all centralized in a system that’s easy for developers to use, as it interfaces with the C++ code that assembles avatars in the first place!

For example, if you wanted to apply a bundle to a character using just the id of the bundle, you could have a function that looks something like this:

local AssetService = game:GetService("AssetService")
local Players = game:GetService("Players")

local function applyBundle(humanoid, bundleId)
	local bundleInfo = AssetService:GetBundleDetailsAsync(bundleId)
	local outfitId = 0
		
	-- Find the outfit that corresponds with this bundle.
	for _,item in pairs(bundleInfo.Items) do
		if item.Type == "UserOutfit" then
			outfitId = item.Id
			break
		end
	end
		
	if outfitId > 0 then
		local bundleDesc = Players:GetHumanoidDescriptionFromOutfitId(outfitId)
		humanoid:ApplyDescription(bundleDesc)
	end
end

The object itself has a lot of properties available at your disposal to define a costume for an avatar.

17 Likes