Skip to content

Latest commit

ย 

History

20 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

C++ / SFML Blackjack

Single-Player Blackjack Game built on Windows Powered by C++, SFML, Visual Studio 2022

Language Framework IDE Status Platform

Watch Video

๐ŸŽฎ Overview

C++ / SFML Blackjack is a digital adaptation of the classic casino card game Blackjack, built using C++, SFML, and Visual Studio 2022.

The objective is simple:
Beat the dealer by getting as close as possible to 21 without going over.

This project is intended purely for educational and learning purposes.


โœจ Features

  • ๐Ÿƒ Fully functional Blackjack gameplay
  • ๐Ÿ‘ค Single-player mode vs. AI dealer
  • ๐ŸŽจ SFML-based 2D graphics
  • ๐ŸŽต Background music integration
  • ๐Ÿ–ฑ๏ธ Mouse-driven UI
  • ๐Ÿ’ฌ Clean code structure suitable for beginners studying C++/SFML

๐Ÿ“‚ Project Structure

SFML-Blackjack/
โ”‚
โ”œโ”€โ”€ SFML/                  # Cards, fonts, audio, textures, source code (.cpp / .h) 
โ”œโ”€โ”€ sfml-dir/              # Libraries included in repo (SFML include/lib/bin)
โ”‚
โ”œโ”€โ”€ x64/
โ”‚   โ”œโ”€โ”€ Debug/             # Auto-generated by Visual Studio
โ”‚   โ””โ”€โ”€ Release/           # Auto-generated by Visual Studio
โ”‚
โ”œโ”€โ”€ .gitignore
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ SFML.sln               # Visual Studio solution


๐ŸŽฎ How to Play

  1. Start the game

    • Click Play on the main menu.
  2. Place your bet

    • Enter the amount you want to bet, then press Place.
  3. Receive your cards

    • Your initial cards will be dealt automatically.
  4. Choose your action

    • Hit โ†’ Draw another card
    • Double โ†’ Double your bet and draw one more card
    • Stand โ†’ Keep your current hand
  5. See the outcome

    • The dealerโ€™s hand is revealed.
    • If your hand is closer to 21 than the dealer without exceeding it, you win!
    • Otherwise, you lose your bet.

Repeat these steps for each round. Enjoy playing responsibly! #This is the last update for SFML Blackjack and there would be no more updates in future!

About

๐ŸƒTake on the dealer! C++/SFML Blackjack with graphics, music, and classic 21 gameplay.

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages