Skip to main content

AssetLayer

An object defining a drawable layer of an asset

Index

Properties

readonlyAllowColorize

AllowColorize: boolean

whether or not this layer can be colored

optionalreadonlyAllowModuleTypes

AllowModuleTypes?: never
@deprecated

optionalreadonlyAllowPose

AllowPose?: never
@deprecated
  • Superceded by PoseMapping

readonlyAllowTypes

AllowTypes: Data

A record mapping stringified PartialType values to a set of unique IDs.

readonlyAlpha

Alpha: readonly Data[]

readonlyAsset

Asset: Asset

The asset that this layer belongs to

readonlyBlendingMode

BlendingMode: GlobalCompositeOperation

readonlyColorGroup

ColorGroup: string

specifies the name of a color group that this layer belongs to. Any layers within the same color group can be colored together via the item color UI

readonlyColorIndex

ColorIndex: number

The coloring index for this layer

readonlyColorSuffix

ColorSuffix: Readonly<Record<string, string>>

readonlyCopyLayerColor

CopyLayerColor: string

if not null, specifies that this layer should always copy the color of the named layer

readonlyCreateLayerTypes

CreateLayerTypes: readonly string[]

readonlyDrawingLeft

DrawingLeft: Readonly<Partial<Record<AssetPoseName, number>> & Record<, number>>

readonlyDrawingTop

DrawingTop: Readonly<Partial<Record<AssetPoseName, number>> & Record<, number>>

optionalreadonlyFixedPosition

FixedPosition?: boolean

That layer is drawing at a fixed Y position

optionalreadonlyGroupAlpha

GroupAlpha?: readonly Data[]

Any group-specific alpha masks that should be applied when drawing the layer. Only available on layers that have been created prior to drawing

readonlyHasImage

HasImage: boolean

optionalreadonlyHasType

HasType?: never
@deprecated
  • superceded by CreateLayerTypes

optionalreadonlyHideAs

HideAs?: Readonly<{ Asset?: string; Group: AssetGroupName }>

readonlyHideColoring

HideColoring: boolean

whether or not this layer can be colored in the coloring UI

readonlyHideForAttribute

HideForAttribute: readonly AssetAttribute[]

optionalreadonlyHideForPose

HideForPose?: never
@deprecated
  • Superceded by PoseMapping

readonlyInheritColor

InheritColor: AssetGroupName

readonlyLockLayer

LockLayer: boolean

readonlyMaxOpacity

MaxOpacity: number

readonlyMinOpacity

MinOpacity: number

optionalreadonlyMirrorExpression

MirrorExpression?: AssetGroupName

optionalreadonlyModuleType

ModuleType?: never
@deprecated
  • Superceded by CreateLayerTypes

readonlyName

Name: string

The name of the layer - may be null if the asset only contains a single default layer

readonlyOpacity

Opacity: number

readonlyParentGroupName

ParentGroupName: AssetGroupName

The name of the parent group for this layer. If null, the layer has no parent group. If undefined, the layer inherits its parent group from it's asset/group.

readonlyPoseMapping

PoseMapping: Readonly<Partial<Record<AssetPoseName, AssetPoseName | PoseType>>>

An array of objects mapping poses to other poses to determine their draw folder

readonlyPriority

Priority: number

The drawing priority of this layer. Inherited from the parent asset/group if not specified in the layer definition.

readonlyShowForAttribute

ShowForAttribute: readonly AssetAttribute[]

readonlyVisibility

Visibility: Player | AllExceptPlayerDialog | Others | OthersExceptDialog | Owner | Lovers | Mistresses

Used along with a hook to make layers of an asset disappear in some cases.