Vital.sandbox
Model

self:is_material_visible

Shared

Retrieves whether a specific material on a component is currently visible


Syntax

local result = self:is_material_visible(component, material)

Parameters

TypeNameDescription
stringcomponentPath of the component containing the material
stringmaterialName of the material to check

Returns

TypeNameDescription
boolresulttrue if the material is visible, false otherwise

Examples

Check whether a specific material is currently visible
local entity = model.create("character")

engine.print("info", "Eyelash visible:", entity:is_material_visible("Skeleton3D/Head", "eyelash_style_1_material"))

On this page