ss
This commit is contained in:
parent
091afc2b5c
commit
28591233f3
85 changed files with 946 additions and 267 deletions
|
|
@ -1,5 +1,13 @@
|
|||
"use strict";
|
||||
|
||||
function drawAcquiredTarinaiOverlay(ctx, tarinai, drawW, drawH) {
|
||||
if (!tarinai?.isAcquiredTarinai) return false;
|
||||
const overlay = getRenderableImage("acquired_tarinai_overlay", "");
|
||||
if (!overlay) return false;
|
||||
ctx.drawImage(overlay, -drawW / 2, -drawH / 2, drawW, drawH);
|
||||
return true;
|
||||
}
|
||||
|
||||
function tarinaiSpriteReversesFacing(sprite) {
|
||||
const id = String(sprite || "");
|
||||
return id === "back" || id === "tarinai12_back" || /(^|_)12_back$/i.test(id);
|
||||
|
|
@ -170,6 +178,7 @@ function tarinaiSpriteReversesFacing(sprite) {
|
|||
ctx.fill();
|
||||
ctx.stroke();
|
||||
}
|
||||
drawAcquiredTarinaiOverlay(ctx, this, drawW, drawH);
|
||||
ctx.restore();
|
||||
|
||||
if (showDecor) {
|
||||
|
|
@ -200,6 +209,11 @@ function tarinaiSpriteReversesFacing(sprite) {
|
|||
const showDecor = shouldShowTarinaiDecor(this);
|
||||
if (sunbathActive) this.preloadSunbathSprites?.();
|
||||
let sprite = this.spriteId();
|
||||
if (this.isAcquiredTarinai && tarinaiSpriteReversesFacing(sprite)) {
|
||||
const fallbackOchibiSprite = this.applyTemperatureSprite?.(this.goodMode || this.type || "smile") || this.goodMode || this.type || "smile";
|
||||
this.visibleSpriteId = "";
|
||||
sprite = fallbackOchibiSprite;
|
||||
}
|
||||
if (!sunbathActive && String(sprite || "").startsWith("sunbath")) {
|
||||
this.visibleSpriteId = "";
|
||||
this.spriteLockUntil = 0;
|
||||
|
|
@ -273,7 +287,7 @@ function tarinaiSpriteReversesFacing(sprite) {
|
|||
drawW *= 1.16;
|
||||
drawH *= 1.24;
|
||||
}
|
||||
if (sprite === "intimidate") {
|
||||
if (String(sprite || "").startsWith("intimidate")) {
|
||||
drawW *= 1.32;
|
||||
drawH *= 1.32;
|
||||
}
|
||||
|
|
@ -526,6 +540,12 @@ function tarinaiSpriteReversesFacing(sprite) {
|
|||
ctx.stroke();
|
||||
ctx.restore();
|
||||
}
|
||||
drawAcquiredTarinaiOverlay(ctx, this, dw, dh);
|
||||
globalThis.TarinaiMamekusaredakeSystem?.drawOnTarinai?.(ctx, this, dw, dh, faceRight, img, {
|
||||
originX: this.x + intimidateShake + coldShakeX,
|
||||
originY: this.y + bob + fearShakeY + coldShakeY,
|
||||
angle
|
||||
});
|
||||
if (img && (this.zunchiStain || 0) > 3) {
|
||||
const stainCanvas = getCachedStainOverlayCanvas(renderSprite || sprite, img, cacheW, cacheH, clamp((this.zunchiStain || 0) / 100, 0, 1), this.zunchiStainSeed || 0.5);
|
||||
if (stainCanvas) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue