EnumItem
Represents one named item in an enumeration.
Behavior
EnumItem is a named enumeration value, such as Enum.Material.Neon.
Access items through the Enum global. Use named items in
scripts to keep the enumeration and value explicit.
Summary
Members4
Properties
EnumType
EnumItem.EnumType: EnumTypeThe enumeration to which the item belongs.
Name
EnumItem.Name: stringThe name of this enumeration member.
Value
EnumItem.Value: numberThe numeric value assigned to the item.
Methods
IsA
EnumItem:IsA(enumName: string): booleanReturns whether the item belongs to the specified enumeration.
Operators
__eq · __tostring · __type
Example
local material = Enum.Material.Neon
print(material.Value)Used by
AssetService · BasePart · CharacterMesh · Chat · DataModel · Humanoid · InputService · LogService · Player · PlayerMouse · PointLight · ProximityPrompt · ProximityPromptService · ReflectionService · SoundService · SpecialMesh · StarterGui · Terrain · TextBox · TextButton · TextLabel · TextService · TweenService · VRService