mirror of
https://github.com/tengge1/ShadowEditor.git
synced 2026-01-25 15:08:11 +00:00
22 lines
512 B
JavaScript
22 lines
512 B
JavaScript
/**
|
|
* 物体基类
|
|
* @constructor
|
|
* @description 物体不需要继承该类,该类仅仅用来说明物体上的通用方法。
|
|
*/
|
|
function BaseObject() {
|
|
THREE.Object3D.call(this);
|
|
}
|
|
|
|
BaseObject.prototype = Object.create(THREE.Object3D.prototype);
|
|
BaseObject.prototype.constructor = BaseObject;
|
|
|
|
/**
|
|
* 创建类前调用,用于下载创建物体所需的类
|
|
*/
|
|
BaseObject.prototype.load = function () {
|
|
return new Promise(resolve => {
|
|
resolve();
|
|
});
|
|
};
|
|
|
|
export default BaseObject; |