Scripting API

Scripting API

ModelMaterial

Record in Abyss.Core.Scenes, from Abyss.Core.

One material of a model, as Bevy's own surface says it, its textures by index.

public record ModelMaterial

Constructors

ModelMaterial

public ModelMaterial(string? Name, string Label, SceneMaterial Surface, int? BaseColorTexture, int? MetallicRoughnessTexture, int? NormalTexture, int? OcclusionTexture, int? EmissiveTexture)

One material of a model, as Bevy's own surface says it, its textures by index.

Parameters

  • Name: What the file calls it.
  • Label: Material0, as Bevy's loader labels it.
  • Surface: Its numbers, its texture slots empty.
  • BaseColorTexture: The texture its color is multiplied by.
  • MetallicRoughnessTexture: The texture its roughness and metalness are multiplied by.
  • NormalTexture: Its normal map.
  • OcclusionTexture: The texture whose red darkens its ambient light.
  • EmissiveTexture: The texture its light is multiplied by.

Properties

Name

public string? Name { get; init; }

What the file calls it.

Label

public string Label { get; init; }

Material0, as Bevy's loader labels it.

Surface

public SceneMaterial Surface { get; init; }

Its numbers, its texture slots empty.

BaseColorTexture

public int? BaseColorTexture { get; init; }

The texture its color is multiplied by.

MetallicRoughnessTexture

public int? MetallicRoughnessTexture { get; init; }

The texture its roughness and metalness are multiplied by.

NormalTexture

public int? NormalTexture { get; init; }

Its normal map.

OcclusionTexture

public int? OcclusionTexture { get; init; }

The texture whose red darkens its ambient light.

EmissiveTexture

public int? EmissiveTexture { get; init; }

The texture its light is multiplied by.