Interface: Live2DRuntime
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4094
Represents a Cubism version.
Properties
version
> version: number
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4098
The version number. Higher version takes priority when matching the runtime.
Methods
createCoreModel()
> createCoreModel(data, options?): any
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4124
Creates a core model.
Parameters
data
ArrayBuffer
Content of the moc file.
options?
Returns
any
Created core model.
createInternalModel()
> createInternalModel(coreModel, settings, options?): InternalModel
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4132
Creates an InternalModel.
Parameters
coreModel
any
Core model that must belong to this runtime.
settings
ModelSettings of this model.
options?
Options that will be passed to the InternalModel's constructor.
Returns
Created InternalModel.
createModelSettings()
> createModelSettings(json): ModelSettings
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4117
Creates a ModelSettings.
Parameters
json
object
The settings JSON object.
Returns
Created ModelSettings.
createPhysics()
> createPhysics(coreModel, data): any
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4146
Creates a physics.
Parameters
coreModel
any
Core model that must belong to this runtime.
data
any
Content of the physics file.
Returns
any
Created physics.
createPose()
> createPose(coreModel, data): any
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4139
Creates a pose.
Parameters
coreModel
any
Core model that must belong to this runtime.
data
any
Content of the pose file.
Returns
any
Created pose.
isValidMoc()
> isValidMoc(modelData): boolean
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4111
Checks if the data is a valid moc to create the core model.
Parameters
modelData
ArrayBuffer
The moc content.
Returns
boolean
True if the data is valid.
ready()
> ready(): Promise<void>
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4105
Returns
Promise<void>
test()
> test(source): boolean
Defined in: node_modules/untitled-pixi-live2d-engine/types/index.d.ts:4104
Checks if the source belongs to this runtime.
Parameters
source
any
Either a settings JSON object or a ModelSettings instance.
Returns
boolean
True if the source belongs to this runtime.