Skip to content

API / DragonBonesData

类: DragonBonesData ​

定义于: model/DragonBonesData.ts:38

龙骨数据。 一个龙骨数据包含多个骨架数据。

继承 ​

构造函数 ​

构造函数 ​

ts
new DragonBonesData(): DragonBonesData;

返回 ​

DragonBonesData

继承自 ​

BaseObject.constructor

属性 ​

armatureNames ​

ts
readonly armatureNames: string[] = [];

定义于: model/DragonBonesData.ts:91

所有的骨架数据名称。


binary ​

ts
binary: ArrayBuffer;

定义于: model/DragonBonesData.ts:99

Internal


cachedFrames ​

ts
readonly cachedFrames: number[] = [];

定义于: model/DragonBonesData.ts:83

Internal


colorArray ​

ts
colorArray: Int16Array<ArrayBuffer> | Uint16Array<ArrayBuffer>;

定义于: model/DragonBonesData.ts:127

Internal


floatArray ​

ts
floatArray: Float32Array;

定义于: model/DragonBonesData.ts:107

Internal


frameArray ​

ts
frameArray: Int16Array;

定义于: model/DragonBonesData.ts:119

Internal


frameFloatArray ​

ts
frameFloatArray: Float32Array;

定义于: model/DragonBonesData.ts:115

Internal


frameIndices ​

ts
readonly frameIndices: number[] = [];

定义于: model/DragonBonesData.ts:79

Internal


frameIntArray ​

ts
frameIntArray: Int16Array;

定义于: model/DragonBonesData.ts:111

Internal


frameRate ​

ts
frameRate: number;

定义于: model/DragonBonesData.ts:53

动画帧频。


hashCode ​

ts
readonly hashCode: number;

定义于: core/BaseObject.ts:156

分配给此实例的唯一标识号。

继承自 ​

BaseObject.hashCode


intArray ​

ts
intArray: Int16Array;

定义于: model/DragonBonesData.ts:103

Internal


name ​

ts
name: string;

定义于: model/DragonBonesData.ts:71

龙骨数据名称。 该名称与龙骨项目名保持一致。


timelineArray ​

ts
timelineArray: Uint16Array;

定义于: model/DragonBonesData.ts:123

Internal


version ​

ts
version: string;

定义于: model/DragonBonesData.ts:61

数据版本。

方法 ​

addArmature() ​

ts
addArmature(value: ArmatureData): void;

定义于: model/DragonBonesData.ts:165

Internal

参数 ​

参数类型
valueArmatureData

返回 ​

void


getArmature() ​

ts
getArmature(armatureName: string): ArmatureData;

定义于: model/DragonBonesData.ts:185

获取特定的骨架数据。

参数 ​

参数类型描述
armatureNamestringThe armature data name.

返回 ​

ArmatureData


returnToPool() ​

ts
returnToPool(): void;

定义于: core/BaseObject.ts:167

清除该实例的所有数据并将其返还对象池。

返回 ​

void

继承自 ​

BaseObject.returnToPool


borrowObject() ​

ts
static borrowObject<T>(objectConstructor: () => T): T;

定义于: core/BaseObject.ts:136

从对象池中获取特定类的实例。

类型参数 ​

类型参数
T extends BaseObject

参数 ​

参数类型描述
objectConstructor() => T特定的类。

返回 ​

T

继承自 ​

BaseObject.borrowObject


clearPool() ​

ts
static clearPool(objectConstructor: typeof BaseObject): void;

定义于: core/BaseObject.ts:111

清除特定对象池的缓存实例。

参数 ​

参数类型默认值描述
objectConstructortypeof BaseObjectnull特定的类。 (不设置则清除所有缓存的实例)

返回 ​

void

继承自 ​

BaseObject.clearPool


setMaxCount() ​

ts
static setMaxCount(objectConstructor: typeof BaseObject, maxCount: number): void;

定义于: core/BaseObject.ts:72

设置特定对象池的最大缓存数量。

参数 ​

参数类型描述
objectConstructortypeof BaseObject特定的类。 (不设置则设置所有对象池的最大缓存数量)
maxCountnumber最大缓存数量。

返回 ​

void

继承自 ​

BaseObject.setMaxCount


toString() ​

ts
static toString(): string;

定义于: model/DragonBonesData.ts:39

返回 ​

string

重写了 ​

BaseObject.toString

Released under the MIT License.