diff --git a/app.js b/app.js index d1a1e21..f5da446 100644 --- a/app.js +++ b/app.js @@ -244,7 +244,7 @@ class Matrix extends MinoesTable { for (let y=0; y position.y >= 4)) { blocksPosition.forEach(position => { - this.blocks[position.y][position.x] = this.piece.className + this.blocks[position.y][position.x] = "locked " + this.piece.className this.drawMino(position, this.piece.className) }) return true diff --git a/css/classic.css b/css/classic.css index 74f65c9..b36e539 100644 --- a/css/classic.css +++ b/css/classic.css @@ -81,6 +81,19 @@ border-bottom-color: #ad1936; } +.ghost.mino { + background: rgba(0, 0, 0, 10%) !important; + border: 3px solid rgba(128, 128, 128, 25%) !important; + box-shadow: -2px -2px 6px rgba(128, 128, 128, 25%), + -2px 2px 6px rgba(128, 128, 128, 25%), + 2px -2px 6px rgba(128, 128, 128, 25%), + 2px 2px 6px rgba(128, 128, 128, 25%); +} + +.moving.mino { + filter: saturate(80%) brightness(150%); +} + .locking.mino { filter: saturate(50%) brightness(200%); box-shadow: -1px -1px 4px rgba(128, 128, 128, 25%), @@ -89,11 +102,17 @@ 1px 1px 4px rgba(128, 128, 128, 25%); } -.ghost.mino { - background: rgba(0, 0, 0, 10%) !important; - border: 3px solid rgba(128, 128, 128, 25%) !important; - box-shadow: -2px -2px 6px rgba(128, 128, 128, 25%), - -2px 2px 6px rgba(128, 128, 128, 25%), - 2px -2px 6px rgba(128, 128, 128, 25%), - 2px 2px 6px rgba(128, 128, 128, 25%); +@keyframes locked-animation { + from { + filter: saturate(50%) brightness(400%); + box-shadow: -1px -1px 4px rgba(255, 255, 255, 25%), + -1px 1px 4px rgba(255, 255, 255, 25%), + 1px -1px 4px rgba(255, 255, 255, 25%), + 1px 1px 4px rgba(255, 255, 255, 25%); + } +} + +.locked.mino { + animation: locked-animation; + animation-duration: 0.2s; } \ No newline at end of file diff --git a/css/pop.css b/css/pop.css index 17a67a5..8aec632 100644 --- a/css/pop.css +++ b/css/pop.css @@ -51,11 +51,28 @@ body { border-color: #ffadad; } +.ghost.mino { + filter: brightness(150%) blur(2px); + opacity: 50%; +} + +.moving.mino { + filter: brightness(120%); +} + .locking.mino { border-color: white; filter: blur(2px); } -.ghost.mino { - filter: brightness(150%) blur(2px); +@keyframes locked-animation { + from { + background: white; + border-color: white; + } +} + +.locked.mino { + animation: locked-animation; + animation-duration: 0.2s; } \ No newline at end of file diff --git a/css/retro.css b/css/retro.css index ef76391..b3e6849 100644 --- a/css/retro.css +++ b/css/retro.css @@ -114,4 +114,8 @@ td { .ghost.mino { opacity: 50%; +} + +.locked.mino { + animation: none; } \ No newline at end of file