Closed iam-yan closed 4 years ago
0.3.2
export class Vector3 { x: number; y: number; z: number; constructor() { this.x = 0; this.y = 0; this.z = 0; } set(x, y, z) { this.x = x; this.y = y; this.z = z; return this; } copy(source) { this.x = source.x; this.y = source.y; this.z = source.z; return this; } clone() { return new Vector3().set(this.x, this.y, this.z); } } export const ThreeTypes = { Vector3: createType({ name: 'Vector3', default: new Vector3(), copy: copyCopyable, clone: cloneClonable, }), };
export class ScaleComponent extends Component<ScaleComponent> { value: THREE.Vector3; } ScaleComponent.schema = { value: { default: new THREE.Vector3(), type: ThreeTypes.Vector3 }, };
Uncaught TypeError: Cannot read property 'name' of undefined at getName (Utils.js:7) at queryKey (Utils.js:32) at QueryManager.getQuery (QueryManager.js:94) at EntityManager.queryComponents (EntityManager.js:273) ...
ver
0.3.2
Create type
Use custom type
Error