List

This Component refers to the return value of menu:AddList.

list:SetValues

Sets the values of the list.

list:SetValues(values)
  • values: table (string[])

list:SetCurrent

Sets the current value of the list.

list:SetCurrent(current)
  • current: number

list:OnChange

Adds a callback that gets executed when the list is changed.

list:OnChange(callback)
  • callback: function(current: number, currentValue: string)