Layering
Index
Variables
activeTab
The currently active tab
Character
The character in question
Display
The (rectangular) shape and inter-button gap of the layering screen
readonlyDisplayDefault
The default (rectangular) shape and inter-button gap of the layering screen
readonlyID
The IDs of layering-specific DOM elements
Item
The selected item in question
readonlyPropertyNames
A set with all item property names that one may or may not assign via the layering subscreen
Functions
Exit
Parameters
reload: boolean = false
Whether the exit call is part of a reload (see Layering.Init)
Returns void
Init
Initialize the layering subscreen
Parameters
item: Item
The affected item
character: Character
The item's owning character
display: Partial<LayeringDisplay> = null
The shape of the layering subscreen
reload: boolean = false
Whether we're loading or reloading the screen. A reload pushes any current changes towards the server and reinitializes all DOM elements.
readonly: boolean = false
Returns Promise<HTMLDivElement>
The div containing the layering subscreen
IsActive
Return whether the layering sub screen has currently been initialized (be it either active or unloaded)
Returns this is Pick<Required<{ activeTab: any; Asset: any; Character: any; Display: any; IsActive: any; Item: any; OverridePriority: any; PropertyNames: any; Readonly: any; UpdateProperty: any; DisplayDefault: Readonly<LayeringDisplay>; ID: Readonly<{ assetGrid: layering-asset-grid; assetHeader: layering-asset-header; exitButton: layering-exit-button; hideButton: layering-hide-button; hideTooltip: layering-hide-button-tooltip; layerDIV: layering-layer-div; layerHeader: layering-layer-header; layerOuterGrid: layering-layer-outer-grid; lockButton: layering-lock-button; resetButton: layering-reset-button; root: layering }>; Exit: any; Init: any; Load: any; RegisterExitCallbacks: any; Resize: any; Unload: any }>, Item | Character | Display>
Load
Returns Promise<void>
RegisterExitCallbacks
Register screen-specific callbacks to-be executed after calling Layering.Exit.
Callbacks registered herein must be used exclusively for setting up the next screen, and not for tearing down the layering sub screen. As such, they are ignored when performing a reload of the layering sub screen (see Layering.Init)
Parameters
rest...options: readonly LayeringExitOptions[]
Returns void
Resize
Parameters
load: boolean
Returns void
Unload
Returns void
UpdateProperty
Update an item's property, optionally for a specific layer, and refresh the character.
Parameters
item: Item
The item to update.
propName: string
The property name (e.g., "Rotation", "ScaleX").
value: any
The new value.
optionallayerName: string
Optional layer name to update. If provided, updates layer-specific property.
Returns void
Accessors
Asset
Get the item's asset
Returns Asset
OverridePriority
Get or set the items
Property.OverridePriorityReturns AssetLayerOverridePriority
Parameters
value: AssetLayerOverridePriority
Returns void
Readonly
Get or set whether the layering screen is readonly
Returns boolean
Parameters
value: boolean
Returns void
Namespace with functions for managing the layering sub screen
Below is an example of some basic usage of the Layering subscreen, including a
Clickfunction for initializing the screen and a set ofResizeandExitfunctions for, respectively, handling the screens drawing/resizing and exiting