small bug fix

This commit is contained in:
redbirdly 2024-06-20 15:58:58 +08:00 committed by GitHub
parent a6565b2652
commit 49e2607f9e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -181,7 +181,7 @@ function glowItsOwnColor(pixel) {
}
function glowItsOwnColorIfPowered(pixel) {
if (pixel.charge <= 0) {return;}
if (!pixel.charge || pixel.charge <= 0) {return;}
if (!pixel.color) return;
var x = Math.floor(pixel.x / lightmapScale);
var y = Math.floor(pixel.y / lightmapScale);