Compare commits
No commits in common. "447c86bf394d9a96f4883dc6a9b4653c7a16f8a6" and "27fdee756671993a625f7fa1fdd33dc5e1e5abf0" have entirely different histories.
447c86bf39
...
27fdee7566
@ -19,7 +19,7 @@ body {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
|
||||
/* TOP UI */
|
||||
.topbar {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
@ -56,7 +56,7 @@ body {
|
||||
box-shadow: 0 3px 6px rgba(0,0,0,0.2), inset 0 0 6px rgba(255,255,255,0.6);
|
||||
}
|
||||
|
||||
|
||||
/* === 5×4 GRID === */
|
||||
.gameboard {
|
||||
flex: 1;
|
||||
display: grid;
|
||||
@ -67,7 +67,7 @@ body {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
|
||||
/* === CARDS === */
|
||||
.card {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
@ -84,7 +84,7 @@ body {
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
|
||||
/* Face */
|
||||
.front, .back {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
@ -116,7 +116,7 @@ body {
|
||||
filter: drop-shadow(0 3px 4px rgba(0,0,0,0.45));
|
||||
}
|
||||
|
||||
|
||||
/* Hover & Flip */
|
||||
.card:not(.flipped):hover .front {
|
||||
transform: scale(1.05);
|
||||
transition: 0.25s;
|
||||
@ -124,14 +124,14 @@ body {
|
||||
|
||||
.card.flipped .inner { transform: rotateY(180deg); }
|
||||
|
||||
|
||||
/* Match Shine */
|
||||
.card.matched .front,
|
||||
.card.matched .back {
|
||||
border-color: #7affd6;
|
||||
box-shadow: 0 0 15px #7affd6, 0 0 30px rgba(122,255,214,0.8);
|
||||
}
|
||||
|
||||
|
||||
/* === COMBO POPUP === */
|
||||
.combo-popup {
|
||||
position: absolute;
|
||||
padding: 12px 20px;
|
||||
@ -222,6 +222,7 @@ body {
|
||||
<div class="end-box">
|
||||
<div class="end-title">🎉 Selamat!</div>
|
||||
<p>Anda berhasil menyelesaikan permainan!</p>
|
||||
|
||||
<div class="score-row"><span>Skor Base:</span> <span id="baseScoreEnd">0</span></div>
|
||||
<div class="score-row"><span>Time Bonus:</span> <span id="timeBonusEnd">0</span></div>
|
||||
<div class="score-row"><span>Move Bonus:</span> <span id="moveBonusEnd">0</span></div>
|
||||
@ -240,7 +241,7 @@ body {
|
||||
</div>
|
||||
|
||||
<script>
|
||||
|
||||
/* === 10 GAMBAR (20 kartu) === */
|
||||
const images = [
|
||||
"images/fruit1.png",
|
||||
"images/fruit2.png",
|
||||
@ -261,6 +262,7 @@ let time = 60;
|
||||
let moves = 0;
|
||||
let score = 0;
|
||||
let countdown;
|
||||
|
||||
let combo = 1;
|
||||
let pendingMatch = false;
|
||||
let lastMatchTime = 0;
|
||||
@ -280,6 +282,7 @@ function showComboPopup(targetCard, combo, bonus) {
|
||||
setTimeout(() => popup.remove(), 1500);
|
||||
}
|
||||
|
||||
|
||||
function shuffleDistant(cards, minDistance = 4) {
|
||||
let valid = false;
|
||||
let result;
|
||||
|
||||
@ -267,7 +267,7 @@ body {
|
||||
</div>
|
||||
|
||||
<script>
|
||||
|
||||
/* === 8 GAMBAR (16 kartu) === */
|
||||
const images = [
|
||||
"images/fruit1.png",
|
||||
"images/fruit2.png",
|
||||
@ -286,6 +286,7 @@ let time = 60;
|
||||
let moves = 0;
|
||||
let score = 0;
|
||||
let countdown;
|
||||
|
||||
let combo = 1;
|
||||
let pendingMatch = false;
|
||||
let lastMatchTime = 0;
|
||||
@ -305,6 +306,7 @@ function showComboPopup(targetCard, combo, bonus) {
|
||||
setTimeout(() => popup.remove(), 1500);
|
||||
}
|
||||
|
||||
|
||||
function shuffleDistant(cards, minDistance = 4) {
|
||||
let valid = false;
|
||||
let result;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user