PcoWSkbVqDnWTu_dm2ix
The Developer Hub is now deprecated and information on this page may no longer be accurate. To see our new and improved documentation, please click here. You can read more about the future of documentation here.
Collapse Sidebar

SetEquippedEmotes

SetEquippedEmotes sets the currently equipped emotes given an array of emote names as they were passed to HumanoidDescription/AddEmote|AddEmote or HumanoidDescription/SetEmotes|SetEmotes. It can also take an array of tables similar to that returned by HumanoidDescription/GetEquippedEmotes|GetEquippedEmotes. Calling this function fires HumanoidDescription/EquippedEmotesChanged|EquippedEmotesChanged.

Example

local hd = Instance.new("HumanoidDescription")
hd:SetEmotes{Salute = {3360689775}, Agree = {4849487550}}
-- Can provide either an array of strings... (index is slot number)
hd:SetEquippedEmotes({"Salute", "Agree"})
-- ...or an array of tables as returned by GetEquippedEmotes (Slot and Name keys set)
hd:SetEquippedEmotes({{Slot = 1, Name = "Salute"}, {Slot = 2, Name = "Agree"}})

See also

  • articles/HumanoidDescription System, for more information on HumanoidDescriptions
  • HumanoidDescription/GetEquippedEmotes|GetEquippedEmotes, which returns a value describing the equipped emotes set by this function
  • HumanoidDescription/EquippedEmotesChanged|EquippedEmotesChanged, which fires when this function is called

Parameters

Name Type Default Description

An array of emote names. Example:

{ "Disagree", "Agree", "Salute" }

– OR –
An array of tables describing the name and slot which each emote is equipped. Example:

{
    {Slot = 3, Name = "Salute"},
    {Slot = 2, Name = "Agree"},
    {Slot = 1, Name = "Disagree"},
}

Returns

Return Type Summary