Skip to main content

WoodcutTreeAttachmentBaker

A class in Root.Township, Alta.Woodcutting.

Baker access for tree attachments (leaves and similar): gives the baking code each attachment's meshes, transform and leaf materials. Use the shared Instance.

Constructors​

MemberWhat it is
WoodcutTreeAttachmentBaker()Creates a WoodcutTreeAttachmentBaker with default values.

Properties​

MemberWhat it is
static WoodcutTreeAttachmentBaker Instance { get; }Shared instance.
override int MaxLods { get; }3.

Methods​

MemberWhat it is
MaterialRect GetAttachmentMaterial(TreeAttachment item, int index)Returns the species' leaf atlas material rect for the index, clamped to the last one.
override int GetLodCount(TreeAttachment item)Number of LOD meshes on the attachment.
override Material GetMaterial(TreeAttachment item, int index)Returns the species' leaf material for the index, clamped to the last one.
override Mesh GetMesh(TreeAttachment item, int lod)Returns the attachment's mesh for a LOD.
override string GetName(TreeAttachment item)The attachment's object name.
override Transform GetTransform(TreeAttachment item)The attachment's transform.
override bool IsValid(TreeAttachment item, int lod)True if the attachment has any LOD meshes.