class ModelRenderer : Renderer

book_4_sparkGenerated
code_blocksInput

Description

The ModelRenderer class in the Sandbox namespace is responsible for rendering a model in the world. It provides various methods and properties to manipulate and retrieve information about the model's rendering state, attachments, materials, and more.

Members

Instance Methods

Member NameSummary
GetAttachmentObjectGet the GameObject of a specific attachment by name.
GetAttachmentObjectGet the GameObject of a specific attachment by attachment object.
GetBoneObjectRetrieve the GameObject associated with a specific bone.
SetBodyGroupSet body group value by name.
SetBodyGroupSet body group value by index.
GetBodyGroupGet body group value by name.
GetBodyGroupGet body group value by index.
ClearMaterialOverridesClear all material overrides.
SetMaterialOverrideOverride the material for a specific target.
SetMaterialSet the material for a specific triangle.
GetMaterialGet the material for a specific triangle.
CopyFromCopy everything from another renderer.

Instance Properties

Member NameSummary
BoundsGets the bounding box of the model.
LocalBoundsGets the local bounding box of the model.
ModelGets or sets the model to be rendered.
TintGets or sets the tint color of the model.
MaterialOverrideGets or sets the material override for the model.
CreateAttachmentsGets or sets a value indicating whether to create attachments.
BodyGroupsGets or sets the body group mask.
HasBodyGroupsIndicates if the model has body groups.
MaterialGroupGets or sets the material group.
HasMaterialGroupsIndicates if the model has material groups.
RenderTypeGets or sets the shadow render type.
SceneObjectGets the associated scene object.