这段代码在子级中使用继承我在场景中添加了一些在父级中声明的内容我该怎么做它在子级查看场景中出现错误
function parent (domElement, renderStatistics) {
this.scene = new THREE.Scene();
}
function child(domElement) {
parent.call(this, domElement);
this.init();
}
child.prototype = Object.create(parent.prototype);
child.prototype.constructor = Young;
child.prototype.init = function () {
function createLab(geometry) {
var mesh = new THREE.Mesh(geometry, new THREE.MeshFaceMaterial());
this.scene.add(mesh); // this error Cannot call method 'add' of undefined
}
}