MaterialService
Retrieves material sets and resolves material overrides.
- Service
game:GetService("MaterialService")- Inherits
- Instance
- Replication
- Never
Behavior
MaterialService retrieves material sets and resolves material overrides.
Summary
The number of registered material entries.
Returns this instance if it is an ExecutionGroup.
Returns a material-set metadata record by identifier, or nil if none exists.
Returns the available material-set metadata records.
Returns whether the named set contains the specified engine material.
Resolves a set and engine material.
Properties
Count
MaterialService.Count: numberThe number of registered material entries.
Methods
GetExecutionGroup
MaterialService:GetExecutionGroup(): ExecutionGroup?Returns this instance if it is an ExecutionGroup. Otherwise returns the nearest ancestor ExecutionGroup, or nil when no group contains the instance.
GetSet
MaterialService:GetSet(id: string): MaterialSet?Returns a material-set metadata record by identifier, or nil if none exists.
GetSets
MaterialService:GetSets(): { MaterialSet }Returns the available material-set metadata records.
Provides
MaterialService:Provides(set: string, material: EnumItem | string): booleanReturns whether the named set contains the specified engine material.
Resolve
MaterialService:Resolve(set: string, material: EnumItem | string): MaterialResolution?Resolves a set and engine material. Returns a record with Set and Substituted, or nil if resolution fails. An unknown material name causes an error.
Inherited members
- Properties
- ArchivableClassNameNameParent
- Methods
- AddComponent()AddTag()ClearAllChildren()ClearTags()Clone()Destroy()FindFirstAncestor()FindFirstAncestorOfClass()FindFirstAncestorWhichIsA()FindFirstChild()FindFirstChildOfClass()FindFirstChildWhichIsA()FindFirstDescendant()GetAttribute()GetAttributeChangedSignal()GetAttributes()GetChildren()GetComponent()GetComponentChangedSignal()GetComponents()GetDebugId()GetDescendants()GetFullName()GetPropertyChangedSignal()GetReferencing()GetTags()HasComponent()HasTag()IsA()IsAncestorOf()IsDescendantOf()RemoveComponent()RemoveTag()SetAttribute()WaitForChild()
- Events
- AncestryChangedAttributeChangedChangedChildAddedChildRemovedDescendantAddedDescendantRemovingDestroying