simulationjsv2 0.1.1 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/simulation.d.ts +1 -0
- package/dist/simulation.js +3 -0
- package/package.json +1 -1
package/dist/simulation.d.ts
CHANGED
|
@@ -25,6 +25,7 @@ export declare class SceneCollection extends SimulationElement {
|
|
|
25
25
|
constructor(name: string);
|
|
26
26
|
getName(): string;
|
|
27
27
|
add(el: SimulationElement): void;
|
|
28
|
+
empty(): void;
|
|
28
29
|
getBuffer(camera: Camera, force: boolean): number[];
|
|
29
30
|
}
|
|
30
31
|
export declare class Camera {
|
package/dist/simulation.js
CHANGED
|
@@ -373,6 +373,9 @@ export class SceneCollection extends SimulationElement {
|
|
|
373
373
|
add(el) {
|
|
374
374
|
applyElementToScene(this.scene, this.camera, el);
|
|
375
375
|
}
|
|
376
|
+
empty() {
|
|
377
|
+
this.scene = [];
|
|
378
|
+
}
|
|
376
379
|
getBuffer(camera, force) {
|
|
377
380
|
const res = [];
|
|
378
381
|
this.scene.forEach((item) => res.push(...item.getBuffer(camera, force)));
|