A classic memory card flip game built with C++ and raylib graphics library. Match pairs of cards to win! Perfect for learning game development and contributing to open source during Hacktoberfest 2025.
- ๐ Randomized Card Layout: Cards are shuffled each game
- โฑ๏ธ Timer: Track your completion time
- ๐ Score System: Points based on matches and time
- ๐จ Beautiful Graphics: Clean, modern UI with smooth animations
- ๐ Sound Effects: Audio feedback for card flips and matches
- ๐ฑ Multiple Difficulty Levels: 4x4, 6x6, and 8x8 grids
- ๐ High Score Tracking: Save your best times locally
- C++17 or later
- CMake 3.16 or later
- raylib 5.0 (automatically downloaded by CMake)
-
Clone the repository:
git clone https://github.com/MSTC-DA-IICT/Hacktoberfest2k25_cpp_MemoryCardFlipGame.git
-
Build the project:
mkdir build && cd build cmake .. make -j4
-
Run the game:
./memory_game
- Open the project folder in Visual Studio 2022
- Select
CMakeLists.txtas the CMake project - Build and run with F5
- Install the C/C++ and CMake Tools extensions
- Open the project folder
- Select a kit when prompted
- Press F7 to build and F5 to debug
- Click on any card to flip it and reveal the symbol
- Click on another card to find its matching pair
- Match all pairs to complete the level!
- Try to complete in the shortest time with fewest moves
- Only 2 cards can be flipped at once
- If cards match, they stay revealed
- If cards don't match, they flip back after 1 second
- Game ends when all pairs are found
memory-card-game/
โโโ src/ # Source files
โ โโโ main.cpp # Entry point
โ โโโ Game.cpp # Game logic
โ โโโ Card.cpp # Card implementation
โ โโโ GameBoard.cpp # Board management
โ โโโ Utils.cpp # Utility functions
โโโ include/ # Header files
โ โโโ Game.h
โ โโโ Card.h
โ โโโ GameBoard.h
โ โโโ Utils.h
โโโ assets/ # Game assets
โ โโโ textures/ # Card textures and sprites
โ โโโ sounds/ # Audio files
โ โโโ fonts/ # Custom fonts
โโโ tests/ # Unit tests
โโโ docs/ # Documentation
โโโ CMakeLists.txt # Build configuration
โโโ README.md # This file
โโโ CONTRIBUTING.md # Contribution guidelines
โโโ LICENSE # MIT License
- Fork this repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Make your changes in the appropriate files
- Test your changes:
make test - Commit your changes:
git commit -m 'Add amazing feature' - Push to your fork:
git push origin feature/amazing-feature - Open a Pull Request
- Use 4 spaces for indentation
- Follow camelCase for variables and functions
- Use PascalCase for classes
- Add comments for complex logic
- Include unit tests for new features
This project is participating in Hacktoberfest 2025! We welcome contributions from developers of all skill levels.
Look for issues labeled with:
good-first-issue- Perfect for beginnershacktoberfest- Hacktoberfest-specific issueshelp-wanted- We need your expertise!
- ๐ Bug Fixes: Fix gameplay bugs or visual glitches
- โจ New Features: Add power-ups, themes, or game modes
- ๐จ Graphics: Improve UI/UX or add new card designs
- ๐ Audio: Add sound effects or background music
- ๐ Documentation: Improve README, add tutorials
- ๐งช Testing: Write unit tests or integration tests
- ๐ง Performance: Optimize game performance
- ๐ง Email: Contact us at
[email protected]
Read our full Contributing Guidelines for detailed information.
This project is maintained by the Microsoft Student Technical Club (MSTC) at Dhirubhai Ambani Institute of Information and Communication Technology (DA-IICT).
- ๐ Website: mstc.daiict.ac.in
- ๐ผ LinkedIn: MSTC DA-IICT
- ๐ง Email: [email protected]
We aim to foster open-source development, provide learning opportunities, and build a collaborative community of tech enthusiasts.
This project is licensed under the MIT License - see the LICENSE file for details.
- raylib community for the amazing graphics library
- MSTC DA-IICT members for their contributions
- Hacktoberfest for promoting open-source development
- All contributors who help make this project better!
If you found this project helpful:
- โญ Star this repository
- ๐ด Fork it for your own experiments
- ๐ข Share it with friends
- ๐ค Contribute to make it better!
Happy Coding! ๐
Made with โค๏ธ by MSTC DA-IICT for Hacktoberfest 2025