Back to Projects
C++ · Windows API · Game Dev

Brainiac (Memory Game)

A memory card-matching game built in C++. One of the first games I built, Brainiac was a foundational experience in game engine integration, state management, and OOP design.

View Source Code
Brainiac Memory Game
C++ & Object-Oriented Programming
Built the game using classes and objects. One of the first projects where I applied OOP concepts in a game context.
Windows API
Worked with Windows-specific functions (HINSTANCE, HWND, HDC) to manage the game window and rendering.
Handled Windows messages for paint events and window lifecycle.
Game Loop & Frame Rate Management
Structured a game loop to update card flip animations and rendering at a consistent frame rate.
Graphics & Rendering
Loaded and rendered bitmap card faces and card backs, managing flip animations.
Game Engine Utilization
Integrated the shared game engine, learning to initialize resources and set up the game environment from scratch.
Input Handling
Handled mouse click input to select and flip cards on the game board.
Collision Detection & Match Logic
Detected matching pairs of cards using bitmap comparison and handled game win conditions.
Game State Management
Managed card states (face-down, face-up, matched), tracking progress and handling game-over and win screens.