mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-06-25 17:10:43 +00:00
wip
This commit is contained in:
parent
c85ee681bb
commit
73d6764a0b
13 changed files with 19 additions and 3 deletions
|
|
@ -243,6 +243,7 @@ export class ObjectContainer {
|
|||
this.model = null;
|
||||
this.subRoot?.dispose();
|
||||
this.root.removeChild(this.subRoot);
|
||||
this.scene.removeTransformNode(this.subRoot);
|
||||
|
||||
this.timer = new Timer();
|
||||
|
||||
|
|
@ -263,10 +264,12 @@ export class ObjectContainer {
|
|||
}
|
||||
|
||||
public destroy() {
|
||||
this.sr.disableSnapshotRendering();
|
||||
this.timer.dispose();
|
||||
this.instance?.dispose?.();
|
||||
this.subRoot?.dispose();
|
||||
this.root.dispose(true);
|
||||
this.subRoot.dispose();
|
||||
this.root.dispose();
|
||||
this.scene.removeTransformNode(this.root);
|
||||
this.sr.enableSnapshotRendering();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -145,6 +145,7 @@ export const allInOnePc = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ export const beamLamp = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -134,6 +134,8 @@ export const desktopPc = defineObject({
|
|||
lc.removeLight(light1);
|
||||
lc.removeLight(light2);
|
||||
}
|
||||
scene.removeLight(light1); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
scene.removeLight(light2); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -130,6 +130,7 @@ export const ductRailSpotLights = defineObject({
|
|||
for (const light of lights) {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
|
|||
|
|
@ -170,6 +170,7 @@ export const laptopPc = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -157,6 +157,7 @@ export const lavaLamp = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
if (animationObserver != null) {
|
||||
scene.onAfterAnimationsObservable.remove(animationObserver);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -133,6 +133,7 @@ export const monitor = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -115,6 +115,7 @@ export const spotLight = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -99,6 +99,7 @@ export const tv = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -116,6 +116,7 @@ export const wallMountSpotLight = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -109,8 +109,9 @@ export const woodRingFloorLamp = defineObject({
|
|||
for (const light of lights) {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
}
|
||||
}
|
||||
},
|
||||
};
|
||||
},
|
||||
});
|
||||
|
|
|
|||
|
|
@ -129,6 +129,7 @@ export const woodRingsPendantLight = defineObject({
|
|||
dispose: () => {
|
||||
light.dispose();
|
||||
if (lc != null) lc.removeLight(light);
|
||||
scene.removeLight(light); // lc使用時はsceneには追加してないはずだが、これがないとクラッシュする babylonのバグ?
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue