Module: game/layers

Interfaces

Type aliases

GenericLayer

Ƭ GenericLayer: Replace<Layer<LayerOptions>, { minWidth: ProcessedComputable<number> ; minimizable: ProcessedComputable<boolean> ; name: ProcessedComputable<string> }>

Defined in

profectus/src/game/layers.tsx:83


Layer

Ƭ Layer<T>: Replace<T & BaseLayer, { classes: GetComputableType<T["classes"]> ; color: GetComputableType<T["color"]> ; display: GetComputableType<T["display"]> ; forceHideGoBack: GetComputableType<T["forceHideGoBack"]> ; links: GetComputableType<T["links"]> ; minWidth: GetComputableTypeWithDefault<T["minWidth"], 600> ; minimizable: GetComputableTypeWithDefault<T["minimizable"], true> ; name: GetComputableTypeWithDefault<T["name"], T["id"]> ; style: GetComputableType<T["style"]> }>

Type parameters

NameType
Textends LayerOptions

Defined in

profectus/src/game/layers.tsx:68

Variables

layers

Const layers: Record<string, Readonly<GenericLayer> | undefined> = {}

Defined in

profectus/src/game/layers.tsx:34

Functions

addLayer

addLayer(layer, player): void

Parameters

NameType
layerGenericLayer
playerObject
player.layers?Record<string, Record<string, unknown>>

Returns

void

Defined in

profectus/src/game/layers.tsx:115


createLayer

createLayer<T>(optionsFunc): Layer<T>

Type parameters

NameType
Textends LayerOptions

Parameters

NameType
optionsFunc() => T

Returns

Layer<T>

Defined in

profectus/src/game/layers.tsx:92


getLayer

getLayer<T>(layerID): T

Type parameters

NameType
Textends GenericLayer

Parameters

NameType
layerIDstring

Returns

T

Defined in

profectus/src/game/layers.tsx:138


reloadLayer

reloadLayer(layer): void

Parameters

NameType
layerGenericLayer

Returns

void

Defined in

profectus/src/game/layers.tsx:149


removeLayer

removeLayer(layer): void

Parameters

NameType
layerGenericLayer

Returns

void

Defined in

profectus/src/game/layers.tsx:142


setupLayerModal

setupLayerModal(layer): Object

Parameters

NameType
layerGenericLayer

Returns

Object

NameType
modalJSXFunction
openModalVoidFunction

Defined in

profectus/src/game/layers.tsx:156