fix shadow for indexed parts

This commit is contained in:
Stewart Allen 2025-12-09 15:40:09 -05:00
commit 4ba452d812

View file

@ -474,6 +474,7 @@ class Widget {
let rad = deg * (Math.PI / 180);
if (rad !== this.track.indexRad) {
this.track.indexRad = rad;
this.clearShadows();
this.setModified();
this._updateMeshPosition();
}
@ -840,6 +841,12 @@ class Widget {
this.mesh.visible = false;
}
clearShadows() {
delete this.cache.shadow;
delete this.cache.shadows;
return this;
}
async shadowAt(z) {
let shadows = this.cache.shadows;
if (!shadows) {