AssetResolveCopyConfig
Index
Functions
_AssignBuyGroup
Parameters
configList: readonly { BuyGroup?: string; Name?: string; Value?: number }[]
Returns void
_ExtendedValidator
Parameters
config: AssetArchetypeConfig
superConfig: AssetArchetypeConfig
key: string
superKey: string
Returns boolean
_Resolve
Parameters
config: T
The (extended) asset config
assetName: string
The name of the corresponding asset
groupName: AssetGroupName
The name of the corresponding asset group
configRecord: Partial<Record<AssetGroupName, Record<string, T>>>
A (nested) record containing the configs of all assets
configType: string
The name of the config type. Used for error reporting
configValidator: AssetCopyConfigValidator<T> = null
An optional validator for comparing the config with its to-be copied counterpart(s)
setBuyGroup: boolean = false
Whether to automatically assign a buygroup to the config and, if required, all
CopyConfig-referenced super configs
Returns T
- The original config merged with its to-be copied super configs. Returns
nullif an error is encountered.
AssetDefinition
Parameters
assetDef: AssetDefinition
The asset definition
groupName: AssetGroupName
The name of the asset group
assetRecord: Partial<Record<AssetGroupName, Record<string, AssetDefinition>>>
A record containg all asset definitions
Returns AssetDefinition
- The oiginally passed base item configuration.
Returns
nullinsstead if an error was encountered.
ExtendedItemConfig
Parameters
asset: Asset
The asset to configure
config: AssetArchetypeConfig
The extended item configuration of the base item
extendedConfig: Partial<Record<AssetGroupName, ExtendedItemGroupConfig>>
The extended item configuration object for the asset's family
Returns AssetArchetypeConfig
- The oiginally passed base item configuration.
Returns
nullinstead if an error was encountered.
Namespace for resolving
CopyConfigfields in (extended) asset configs.