1 Project Title
C++ Implementation of the MMemory MatchCard Game
2 Objective
This project focuses on creating a C++ console application to implement the MMemory Matchcard
game, using object-oriented programming principles. The game challenges players to find matching pairs
of cards from a shuffled deck. Players take turns flipping cards to reveal their values, aiming to collect as
many matching pairs as possible.
3 Project Overview
The Memory Match game is a two-player card game where each player tries to match pairs of cards from
a shuffled deck laid out in a grid. On each turn, a player flips two cards face-up. If the cards match, the
player scores points and takes another turn. If the cards don’t match, they are flipped face-down again,
and the next player gets a turn. The player who finds the most pairs of matching cards wins the game.
4 Game Setup
• Players: The game is designed for 2 players.
• Deck: The deck consists of normal cards which are numbers and special cards which will be illus-
trated.
• Board: The cards are placed face-down in a 4 x 4 grid. Players take turns flipping two cards to try
and match pairs.
5 Gameplay Mechanics
5.1 Start of Game
• The deck is shuffled, and the cards are laid out face-down in the grid.
• Each card has a number, and there are two cards for each unique number in the deck.
5.2 Player Actions
• On their turn, a player flips two cards face-up.
• If the cards match, the player keeps the pair and takes another turn.
• If the cards don’t match, the cards are turned face-down again, and the next player takes their
turn.
5.3 Special Cards
In addition to regular cards, special cards with unique effects are added to make the game more challen-
ging:
• Standard Card: This represents the normal cards (digits between 1 to 6). This card has no special
abilities.
 Bonus Card: If a player flips a bonus card, they get an extra point or a bonus turn. The deck
consists of 2 bonus cards only.
• Penalty Card: If a player flips a penalty card, they lose a point or skip their next turn. The deck
consists of 2 penalty cards only.
5.4 Scoring
• Each player scores a point for every matched pair of cards.
• The game continues until all pairs have been matched.
• The player with the most pairs wins the game.
5.5 Game Strategy
• Players must remember the locations of previously revealed cards to increase their chances of finding
matches on subsequent turns.
• Good memory and strategy are key to winning.
6 Game Features
The project will include the following features:
• Deck and Card Management: A class to manage the deck of cards and each card’s state (face-up
or face-down).
• Player Management: A class to handle the players’ actions and scores.
• Turn Management: A mechanism that allows players to take turns flipping cards.
• End of Game: The game ends when all pairs have been matched. The player with the most
matches wins.
Milestone 01
Deadline 22nd of November 11:59 PM
General Description:
In this project, you are tasked with implementing a simple 2D card matching game that can be played
via console application. The game is based on the classic concept of memory matching, where players flip
over cards to find pairs. The game continues until all pairs have been matched, with each player trying
to identify pairs based on memory. The player with the most pairs at the end of the game wins.
Milestone 01: In this milestone, you are asked to implement the following classes and functions, each class
should have appropriate member variables and member functions:
a) Card Class: The Card class represents an individual card in the game. Card class will serve as the
base class for the special cards which are Standard, Bonus and Penalty cards.
Methods:
• display(): Displays the card’s number if face-up or a placeholder (*)if face-down.
Card Subclasses:
• StandardCard: This represents a regular card with no special abilities.
• BonusCard: This card offers bonus points when matched.
• PenaltyCard: This card deducts points if mismatched.
b) Deck Class: The Deck class represents the collection of cards in the game. It should manage the
array of Card objects and include the following methods:
Methods:
• shuffle(): Randomly shuffles the deck of cards.
• displayGrid(): Displays the current layout of the cards in the grid. For current milestone the
4x4 grid should look something like that:
* * * *
* * * *
* * * *
* * * *
c) Player Class: The Player class represents an individual participant in the game. It includes details
such as the player’s name and score
Methods:
• displayScore(): Displays the player’s current score.
d) Game Class: The Game class manages the overall game flow and player interactions.
Methods:
• initializeGame(): Initializes the game, shuffles the deck, and places cards to the grid.
Milestone Requirements: This milestone focuses on the structure of the game. Full game-play func-
tionalities (like turns, scoring, etc.) will be implemented in milestone 02.
0.1 Deliverables:
• A Header file for each of the previously mentioned classes.
• One single Source file (.cpp) with the implementation of the previously mentioned classes,
methods and attributes.
• The source file should have a main method that must initialize the game, shuffle the deck, and
display the grid for testing purposes.
• All those files should be then put in one folder and the folder should be compressed into a .zip file
with following naming format.TeamNumber_TheNameOfTheSubmittingMember_theIDofTheSubmittingMember.
• PLEASE DO NOT EXTRACT A FULL PROJECT AND JUST SUBMIT THE FILES AS MEN-
TIONED ABOVE
Important notes:
• FULLY AI GENERATED CODE WILL LEAD TO A 0 IN THE PROJECT
• All attributes in the classes are private and has setters and getters that has to be implemented
• Each class should have 2 constructors: the default constructor and a constructor that initialize all
the attributes of the classes
• Each class should have a destructor even if it will remain empty
• The Grid array and the cards attributes should be dynamically created
• All the functionalities and game play (turns, deals and scoring, etc..) as well as the special behavior
of each of the subclasses will be discussed and implemented in milestone 02.

do milestone 1