Material Set ​
A material set stores the 128 materials that can be assigned to a voxel or pixel. Each material has the properties metallic, roughness, emissive and alpha. To edit the materials of a material set use FxMaterialSet.
Properties ​
None.
Create ​
To create a new material set use FxFile.Create with FileType 332.
lua
materialSetID = FxFile.Create(332);
materialSetID = FxFile.Rename(332, materialSetID, "MyMaterialSet"); -- rename new material set
FxFile.Open(115, materialSetID); -- open new material setFiles ​
A default material set, which is copied to every new project, is located at documents\Foxel\default.fxlmat. Each project has its own material set stored as Projects\PROJECTNAME\project.fxlmat. Other custom material sets are stored as shared files in Shared\MaterialSets\ with the extension .fxlmat.