Fix snake asset lookup for canvas overlays

This commit is contained in:
Jonas
2025-09-21 20:42:39 +02:00
parent 830dedb686
commit d77f334047
2 changed files with 29 additions and 1 deletions

View File

@@ -8,7 +8,15 @@ class Overlay{
this.src = imgSrc;
if(!this.src) return;
this.image = this.tileLoader.tileMap.get(this.src);
const image = this.tileLoader.getImage(this.src);
if(!image){
this.src = null;
return;
}
this.src = this.tileLoader.resolveSrc(this.src);
this.image = image;
}
}