diff --git a/src/App.vue b/src/App.vue index 2ea7bb4..cd98be0 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,5 +1,5 @@ diff --git a/src/components/PetGame.vue b/src/components/PetGame.vue index 75aa3ff..ddaa70d 100644 --- a/src/components/PetGame.vue +++ b/src/components/PetGame.vue @@ -3,6 +3,7 @@ - -
+ { @@ -1570,8 +1568,8 @@ defineExpose({ } @keyframes pet-sick-shake { 0%, 100% { transform: translateX(0); } - 25% { transform: translateX(-2px); } - 75% { transform: translateX(2px); } + 25% { transform: translateX(-3.2px); } + 75% { transform: translateX(3.2px); } } /* Tail */ @@ -1582,17 +1580,17 @@ defineExpose({ @keyframes tail-wag-idle { 0% { transform: translateX(0px); } - 50% { transform: translateX(1px); } + 50% { transform: translateX(1.6px); } 100% { transform: translateX(0px); } } @keyframes tail-wag-sleep { 0% { transform: translateX(0px); } - 50% { transform: translateX(0.5px); } + 50% { transform: translateX(0.8px); } 100% { transform: translateX(0px); } } @keyframes tail-wag-sick { 0% { transform: translateX(0px); } - 50% { transform: translateX(0.8px); } + 50% { transform: translateX(1.3px); } 100% { transform: translateX(0px); } } @@ -1604,15 +1602,15 @@ defineExpose({ @keyframes leg-front-step { 0%, 100% { transform: translateY(0); } - 50% { transform: translateY(-1px); } + 50% { transform: translateY(-1.6px); } } @keyframes leg-back-step { - 0%, 100% { transform: translateY(-1px); } + 0%, 100% { transform: translateY(-1.6px); } 50% { transform: translateY(0); } } @keyframes leg-sick-step { 0%, 100% { transform: translateY(0); } - 50% { transform: translateY(-0.5px); } + 50% { transform: translateY(-0.8px); } } /* Ears */ @@ -1622,7 +1620,7 @@ defineExpose({ @keyframes ear-twitch { 0%, 90%, 100% { transform: translateY(0); } - 92% { transform: translateY(-1px); } + 92% { transform: translateY(-1.6px); } 96% { transform: translateY(0); } } @@ -1649,17 +1647,7 @@ defineExpose({ border-radius: 10px; /* 與螢幕邊框一致 */ } -/* Fullscreen Dark Overlay (原本 PrayerMenu 的位置) */ -.dark-overlay-fullscreen { - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background: #000; - z-index: 100; /* Same as PrayerMenu was */ - pointer-events: none; -} + /* Sleep ZZZ */ .sleep-zzz { @@ -1670,30 +1658,112 @@ defineExpose({ z-index: 10; /* Above dark overlay */ } .sleep-zzz.dark-mode { - color: #fff !important; /* 強制白色:在黑色背景下變白色 */ - text-shadow: 0 0 4px rgba(255, 255, 255, 0.8); /* 添加發光效果讓它更明顯 */ + color: #fff; /* 在黑色背景下變白色 */ + text-shadow: 0 0 6px rgba(255, 255, 255, 0.8); } .sleep-zzz span { position: absolute; - font-size: 10px; + font-size: 16px; opacity: 0; animation: zzz-float 3s ease-in-out infinite; } .sleep-zzz .z1 { left: 0; animation-delay: 0s; } -.sleep-zzz .z2 { left: 8px; animation-delay: 0.8s; } -.sleep-zzz .z3 { left: 15px; animation-delay: 1.6s; } +.sleep-zzz .z2 { left: 13px; animation-delay: 0.8s; } +.sleep-zzz .z3 { left: 24px; animation-delay: 1.6s; } @keyframes zzz-float { 0% { opacity: 0; transform: translateY(0) scale(0.7); } - 20% { opacity: 1; transform: translateY(-4px) scale(0.9); } - 80% { opacity: 1; transform: translateY(-16px) scale(1.05); } - 100% { opacity: 0; transform: translateY(-24px) scale(1.1); } + 20% { opacity: 1; transform: translateY(-6.4px) scale(0.9); } + 80% { opacity: 1; transform: translateY(-25.6px) scale(1.05); } + 100% { opacity: 0; transform: translateY(-38.4px) scale(1.1); } } +/* Event Bubble */ +.event-bubble { + position: absolute; + transform: translate(-50%, -100%); + background: white; + border: 3px solid #333; + border-radius: 13px; + padding: 6px 13px; + display: flex; + align-items: center; + gap: 8px; + z-index: 20; + min-width: 96px; + box-shadow: 0 3px 6px rgba(0,0,0,0.2); + animation: bubble-pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); +} + +.event-bubble::after { + content: ''; + position: absolute; + bottom: -10px; + left: 50%; + transform: translateX(-50%); + border-width: 10px 10px 0; + border-style: solid; + border-color: #333 transparent transparent transparent; +} + +.event-bubble::before { + content: ''; + position: absolute; + bottom: -5px; + left: 50%; + transform: translateX(-50%); + border-width: 8px 8px 0; + border-style: solid; + border-color: white transparent transparent transparent; + z-index: 1; +} + +.event-icon { + width: 26px; + height: 26px; + background-size: contain; + background-repeat: no-repeat; + background-position: center; +} + +.event-text { + font-family: 'DotGothic16', monospace; + font-size: 16px; + color: #333; + font-weight: bold; +} + +/* Event Animation */ +.event-animation { + position: absolute; + width: 51px; + height: 51px; + z-index: 15; + pointer-events: none; + animation: event-float 2s ease-out forwards; +} + +/* Play Ball */ +.play-ball { + position: absolute; + width: 13px; + height: 13px; + z-index: 15; +} + +.ball-pixel { + width: 6px; + height: 6px; + background: #ff5252; + box-shadow: + 6px 0 0 #ff5252, + 0 6px 0 #ff5252, + 6px 6px 0 #ff5252; +} /* Sick Icon */ .sick-icon { position: absolute; - font-size: 14px; + font-size: 22px; pointer-events: none; z-index: 10; animation: sick-icon-pulse 1.2s ease-in-out infinite; @@ -1710,11 +1780,11 @@ defineExpose({ left: 50%; top: 50%; transform: translate(-50%, -50%); - width: 30px; - height: 40px; + width: 48px; + height: 64px; background: linear-gradient(to bottom, #888 0%, #555 100%); - border-radius: 10px 10px 0 0; - border: 2px solid #333; + border-radius: 16px 16px 0 0; + border: 3px solid #333; } .tombstone::before { @@ -1723,7 +1793,7 @@ defineExpose({ top: 50%; left: 50%; transform: translate(-50%, -50%); - font-size: 8px; + font-size: 13px; font-weight: bold; color: white; } @@ -1731,55 +1801,55 @@ defineExpose({ /* Poop Sprite (Larger & More Detailed) */ .poop { position: absolute; - width: 32px; - height: 32px; + width: 51px; + height: 51px; z-index: 5; } .poop-sprite { position: relative; - width: 3px; - height: 3px; + width: 4.8px; + height: 4.8px; background: #3d2817; top: 50%; left: 50%; transform: translate(-50%, -50%); box-shadow: /* Top point */ - 0px -12px 0 #3d2817, + 0px -19.2px 0 #3d2817, /* Row 2 - narrow */ - -3px -9px 0 #3d2817, 0px -9px 0 #5a4028, 3px -9px 0 #3d2817, + -4.8px -14.4px 0 #3d2817, 0px -14.4px 0 #5a4028, 4.8px -14.4px 0 #3d2817, /* Row 3 */ - -6px -6px 0 #3d2817, -3px -6px 0 #5a4028, 0px -6px 0 #6b4e38, - 3px -6px 0 #5a4028, 6px -6px 0 #3d2817, + -9.6px -9.6px 0 #3d2817, -4.8px -9.6px 0 #5a4028, 0px -9.6px 0 #6b4e38, + 4.8px -9.6px 0 #5a4028, 9.6px -9.6px 0 #3d2817, /* Row 4 - eyes */ - -6px -3px 0 #3d2817, -3px -3px 0 #ffffff, 0px -3px 0 #6b4e38, - 3px -3px 0 #ffffff, 6px -3px 0 #3d2817, + -9.6px -4.8px 0 #3d2817, -4.8px -4.8px 0 #ffffff, 0px -4.8px 0 #6b4e38, + 4.8px -4.8px 0 #ffffff, 9.6px -4.8px 0 #3d2817, /* Row 5 - middle */ - -9px 0px 0 #3d2817, -6px 0px 0 #5a4028, -3px 0px 0 #6b4e38, 0px 0px 0 #7d5a3a, - 3px 0px 0 #6b4e38, 6px 0px 0 #5a4028, 9px 0px 0 #3d2817, + -14.4px 0px 0 #3d2817, -9.6px 0px 0 #5a4028, -4.8px 0px 0 #6b4e38, 0px 0px 0 #7d5a3a, + 4.8px 0px 0 #6b4e38, 9.6px 0px 0 #5a4028, 14.4px 0px 0 #3d2817, /* Row 6 */ - -9px 3px 0 #3d2817, -6px 3px 0 #5a4028, -3px 3px 0 #6b4e38, 0px 3px 0 #7d5a3a, - 3px 3px 0 #6b4e38, 6px 3px 0 #5a4028, 9px 3px 0 #3d2817, + -14.4px 4.8px 0 #3d2817, -9.6px 4.8px 0 #5a4028, -4.8px 4.8px 0 #6b4e38, 0px 4.8px 0 #7d5a3a, + 4.8px 4.8px 0 #6b4e38, 9.6px 4.8px 0 #5a4028, 14.4px 4.8px 0 #3d2817, /* Row 7 */ - -12px 6px 0 #3d2817, -9px 6px 0 #3d2817, -6px 6px 0 #5a4028, -3px 6px 0 #6b4e38, - 0px 6px 0 #7d5a3a, 3px 6px 0 #6b4e38, 6px 6px 0 #5a4028, 9px 6px 0 #3d2817, 12px 6px 0 #3d2817, + -19.2px 9.6px 0 #3d2817, -14.4px 9.6px 0 #3d2817, -9.6px 9.6px 0 #5a4028, -4.8px 9.6px 0 #6b4e38, + 0px 9.6px 0 #7d5a3a, 4.8px 9.6px 0 #6b4e38, 9.6px 9.6px 0 #5a4028, 14.4px 9.6px 0 #3d2817, 19.2px 9.6px 0 #3d2817, /* Row 8 - wider */ - -12px 9px 0 #3d2817, -9px 9px 0 #5a4028, -6px 9px 0 #6b4e38, -3px 9px 0 #7d5a3a, - 0px 9px 0 #7d5a3a, 3px 9px 0 #7d5a3a, 6px 9px 0 #6b4e38, 9px 9px 0 #5a4028, 12px 9px 0 #3d2817, + -19.2px 14.4px 0 #3d2817, -14.4px 14.4px 0 #5a4028, -9.6px 14.4px 0 #6b4e38, -4.8px 14.4px 0 #7d5a3a, + 0px 14.4px 0 #7d5a3a, 4.8px 14.4px 0 #7d5a3a, 9.6px 14.4px 0 #6b4e38, 14.4px 14.4px 0 #5a4028, 19.2px 14.4px 0 #3d2817, /* Bottom row */ - -9px 12px 0 #3d2817, -6px 12px 0 #5a4028, -3px 12px 0 #6b4e38, - 0px 12px 0 #6b4e38, 3px 12px 0 #6b4e38, 6px 12px 0 #5a4028, 9px 12px 0 #3d2817; + -14.4px 19.2px 0 #3d2817, -9.6px 19.2px 0 #5a4028, -4.8px 19.2px 0 #6b4e38, + 0px 19.2px 0 #6b4e38, 4.8px 19.2px 0 #6b4e38, 9.6px 19.2px 0 #5a4028, 14.4px 19.2px 0 #3d2817; } /* Stink Animation (3 Fingers Style - Wavy) */ .poop-stink { position: absolute; - top: -25px; + top: -40px; left: 50%; transform: translateX(-50%); - width: 40px; - height: 30px; + width: 64px; + height: 48px; pointer-events: none; } @@ -1787,18 +1857,18 @@ defineExpose({ position: absolute; bottom: 0; left: 50%; - width: 2px; - height: 2px; + width: 3px; + height: 3px; background: transparent; /* Pixel art vertical wave pattern */ box-shadow: 0px 0px 0 #555, - 1px -2px 0 #555, - 1px -4px 0 #555, - 0px -6px 0 #555, - -1px -8px 0 #555, - -1px -10px 0 #555, - 0px -12px 0 #555; + 1.6px -3.2px 0 #555, + 1.6px -6.4px 0 #555, + 0px -9.6px 0 #555, + -1.6px -12.8px 0 #555, + -1.6px -16px 0 #555, + 0px -19.2px 0 #555; opacity: 0; transform-origin: bottom center; } @@ -1810,45 +1880,32 @@ defineExpose({ /* Middle Finger */ .stink-line.s2 { - /* Slightly taller wave for middle */ - box-shadow: - 0px 0px 0 #555, - 1px -2px 0 #555, - 1px -4px 0 #555, - 0px -6px 0 #555, - -1px -8px 0 #555, - -1px -10px 0 #555, - 0px -12px 0 #555, - 1px -14px 0 #555; animation: stink-finger-2 2s ease-in-out infinite; - animation-delay: 0.2s; + animation-delay: 0.3s; } /* Right Finger */ .stink-line.s3 { animation: stink-finger-3 2s ease-in-out infinite; - animation-delay: 0.4s; + animation-delay: 0.6s; } @keyframes stink-finger-1 { - 0% { opacity: 0; transform: translateX(-50%) rotate(-25deg) scaleY(0.5); } - 20% { opacity: 0.8; transform: translateX(-50%) rotate(-25deg) scaleY(1) translateY(-5px); } - 80% { opacity: 0.4; transform: translateX(-50%) rotate(-35deg) scaleY(1) translateY(-15px); } - 100% { opacity: 0; transform: translateX(-50%) rotate(-40deg) scaleY(1.2) translateY(-20px); } + 0% { opacity: 0; transform: translateX(-16px) scaleY(0.2); } + 50% { opacity: 0.6; transform: translateX(-24px) scaleY(1); } + 100% { opacity: 0; transform: translateX(-32px) scaleY(1.2); } } @keyframes stink-finger-2 { - 0% { opacity: 0; transform: translateX(-50%) rotate(0deg) scaleY(0.5); } - 20% { opacity: 0.8; transform: translateX(-50%) rotate(0deg) scaleY(1) translateY(-6px); } - 80% { opacity: 0.4; transform: translateX(-50%) rotate(0deg) scaleY(1) translateY(-18px); } - 100% { opacity: 0; transform: translateX(-50%) rotate(0deg) scaleY(1.2) translateY(-24px); } + 0% { opacity: 0; transform: translateX(0) scaleY(0.2); } + 50% { opacity: 0.6; transform: translateX(0) scaleY(1.2); } + 100% { opacity: 0; transform: translateX(0) scaleY(1.4); } } @keyframes stink-finger-3 { - 0% { opacity: 0; transform: translateX(-50%) rotate(25deg) scaleY(0.5); } - 20% { opacity: 0.8; transform: translateX(-50%) rotate(25deg) scaleY(1) translateY(-5px); } - 80% { opacity: 0.4; transform: translateX(-50%) rotate(35deg) scaleY(1) translateY(-15px); } - 100% { opacity: 0; transform: translateX(-50%) rotate(40deg) scaleY(1.2) translateY(-20px); } + 0% { opacity: 0; transform: translateX(16px) scaleY(0.2); } + 50% { opacity: 0.6; transform: translateX(24px) scaleY(1); } + 100% { opacity: 0; transform: translateX(32px) scaleY(1.2); } } /* Poop Flush Animation */ @@ -1946,14 +2003,14 @@ defineExpose({ } .death-menu { - margin-top: -30px; /* Overlay on top of tombstone */ + margin-top: -48px; /* Overlay on top of tombstone */ background: rgba(224, 224, 224, 0.95); - border: 4px solid #555; - padding: 10px; - border-radius: 8px; + border: 6px solid #555; + padding: 16px; + border-radius: 13px; text-align: center; - box-shadow: 0 4px 0 #333; - max-width: 180px; + box-shadow: 0 6px 0 #333; + max-width: 288px; width: 90%; z-index: 1; position: relative; @@ -1962,39 +2019,61 @@ defineExpose({ .death-title { font-family: 'DotGothic16', monospace; - font-size: 14px; + font-size: 22px; font-weight: bold; color: #333; - margin-bottom: 8px; + margin-bottom: 13px; } .death-actions { display: flex; flex-direction: column; - gap: 6px; + gap: 10px; } -.action-btn { - font-family: 'DotGothic16', monospace; - padding: 6px 10px; +.death-btn { background: #fff; - border: 2px solid #888; - border-radius: 4px; + border: 3px solid #333; + padding: 13px; + font-family: 'DotGothic16', monospace; + font-size: 19px; cursor: pointer; - font-size: 11px; + border-radius: 6px; transition: all 0.1s; - white-space: normal; - line-height: 1.2; - word-wrap: break-word; } -.action-btn:active { - transform: translateY(2px); - background: #ddd; +.death-btn:hover { + background: #eee; + transform: translateY(-2px); + box-shadow: 0 3px 0 #333; } +.death-btn:active { + transform: translateY(0); + box-shadow: 0 0 0 #333; +} +.death-btn.primary { + background: #4CAF50; + color: white; + border-color: #2E7D32; +} +.death-btn.primary:hover { + background: #43A047; + box-shadow: 0 3px 0 #1B5E20; +} + +.death-btn.secondary { + background: #FFC107; + color: #333; + border-color: #FFA000; +} + +.death-btn.secondary:hover { + background: #FFB300; + box-shadow: 0 3px 0 #FF6F00; +} /* Mood Animations */ .pet-root.mood-happy { diff --git a/src/components/TopMenu.vue b/src/components/TopMenu.vue index 08d194b..65fbe35 100644 --- a/src/components/TopMenu.vue +++ b/src/components/TopMenu.vue @@ -1,17 +1,26 @@