Welcome to Devil Dolphin Memory, a beautifully designed, responsive web-based memory card game built with plain HTML, CSS, and Vanilla JavaScript. Test your memory skills, complete dynamically generated levels, and earn crowns based on your performance!
- ๐ฎ Dynamic Levels: The game features multiple levels with varying difficulties. Levels are generated dynamically with a set number of cards.
- โฑ๏ธ Live Game Stats: Tracks your time, moves made, misses, pairs found, and calculates your accuracy in real-time.
- ๐ Achievements System: Depending on your game performance (time and moves), earn crowns:
- ๐ Red Crown (Level 3 - Expert)
- ๐ Gold Crown (Level 2 - Master)
- ๐ Green Crown (Level 1 - Starter)
- ๐ Local Storage Persistence: Automatically saves your levels statistics, overall accuracy, and best scores cross-sessions using browser
localStorage. - ๐ฑ Fully Responsive: Carefully crafted CSS (including dedicated responsive files) ensures the game looks great on desktop, tablet, and mobile devices.
- ๐ฅ๏ธ Fullscreen Mode: Immerse yourself in the game by toggling the fullscreen view during gameplay.
- HTML5: Semantic architecture for
index.html(home dashboard) andgame.html(gaming board). - CSS3: Custom modular stylesheet architecture (separated by components like
header,footer,main, andResponsivity). - Vanilla JavaScript (ES6 Modules):
game.js: The core object-oriented game engine (MemoryCardGameclass) handling logic, card flips, and timer operations.home.js: Drives the home dashboard, populates levels, and renders the player's saved score and achievements.utils.js: Houses common utilities like time formatting, array shuffling, formatting outputs, and Local Storage abstractions.data/: Contains modular configuration data (levels.js) and the image assets mappings (cards_images.js).
โโโ assets/ # Icons, images, and achievement crowns
โ โโโ images/
โ โ โโโ icons/
โ โ โโโ crowns/
โโโ scripts/ # Core logic and JS Modules
โ โโโ data/ # Levels config and cards images data
โ โโโ game.js # Game board logic and Mechanics
โ โโโ home.js # Home dashboard and Stats viewer
โ โโโ utils.js # Utility functions
โโโ styles/ # Modular CSS formatting
โ โโโ game/ # Game page styles
โ โโโ home/ # Home dashboard styles
โ โโโ Responsivity/ # Media queries for responsive UI
โ โโโ all.css # Global variables and CSS resets
โโโ game.html # The playing field view
โโโ index.html # The entry, level-selection and stats view
Since it's built with Vanilla HTML/CSS/JS, running the project is incredibly simple!
-
Clone the repository to your local machine:
git clone <repository-url>
-
Navigate to the project directory:
cd "Devil Dolphin Memory"
-
Open
index.htmlin your favorite web browser or start a local live server:- For VS Code users, standard extensions like Live Server work perfectly.
- Or simply double-click
index.htmlin your file explorer.
-
Select a level and start matching cards!
- Select a Level: Click a level from the dashboard.
- Match the Cards: Click on cards to flip them. Try to find two matching cards.
- Minimize Misses: Every pair of non-matching flipped cards counts as a miss, reducing your accuracy.
- Earn Crowns: Complete the game fast and with minimal misses to get the best crown.
- Quit or Start Over: Use the Cancel button anytime to return to the home screen.
Designed and Built by Adel Maach