This commit is contained in:
33333-33333 2026-06-21 22:29:00 +09:00
commit 0a6148c73f
67 changed files with 2653 additions and 1519 deletions

View file

@ -284,16 +284,16 @@
ctx.restore();
}
}
if (sprite === "zunchi_slave") {
if (String(sprite || "").startsWith("zunchi_slave")) {
const zImg = typeof getRenderableImage === "function" ? getRenderableImage("zunchi", "zunchi") : (images && images.get ? images.get("zunchi") : null);
if (zImg) {
ctx.save();
ctx.shadowColor = "rgba(46, 36, 24, 0.28)";
ctx.shadowBlur = 5;
ctx.shadowOffsetY = Math.max(1, drawH * 0.012);
const zw = Math.max(12, drawW * 0.30);
const zw = Math.max(16, drawW * 0.42);
const zh = zw * 0.74;
ctx.drawImage(zImg, -zw * 0.50, -dh * 0.48 - zh * 0.25, zw, zh);
ctx.drawImage(zImg, -zw * 0.78, -dh * 0.50 - zh * 0.28, zw, zh);
ctx.restore();
}
}
@ -342,15 +342,20 @@
const drawMeter = (y, pct, fill, alpha) => {
ctx.save();
ctx.globalAlpha = alpha;
const safePct = clamp(Number(pct) || 0, 0, 1);
const fillW = safePct <= 0 ? 0 : Math.min(bw, Math.max(2, bw * safePct));
ctx.fillStyle = "rgba(255,252,242,0.86)";
roundedRect(ctx, x - 2, y - 2, bw + 4, bh + 4, 5);
ctx.fill();
ctx.fillStyle = "rgba(72,58,45,0.22)";
roundedRect(ctx, x, y, bw, bh, 4);
ctx.fill();
ctx.fillStyle = fill;
roundedRect(ctx, x, y, bw * pct, bh, 4);
ctx.fill();
if (fillW > 0) {
const fillR = Math.min(4, bh / 2, fillW / 2);
ctx.fillStyle = fill;
roundedRect(ctx, x, y, fillW, bh, fillR);
ctx.fill();
}
ctx.restore();
};
if (stressActive) {