Skip to main content

Casino games library created by a group of 4 university students.

Project description

NOVEMBER 2024

Programming library creation.

This project consists of the creation of a library that allows the user to perform the following operations:

This library contains 4 main casino games: Roulette, Cards, Bingo and Dice.

######################

  • 1. Roulette: The Roulette module simulates a complete game of roulette, allowing users to place different types of bets and spin a virtual wheel to determine the winning number. The module defines core elements, such as colors (red, black, and green for 0) assigned to each number and betting options like specific numbers, colors, dozens, halves (high/low), and even/odd. Upon spinning the wheel, a random number from 0 to 36 is generated. Players can choose from betting options, and the module evaluates whether they win based on the number and characteristics (like color or parity) of the spun result. Feedback is provided for the outcome of each bet, creating an engaging simulation of a roulette game within a virtual casino setting.

######################

  • 2. Cards: The Cards module in the library provides simulations for various card-based games, including implementations for Poker, Blackjack, and basic deck handling. This module supports key functionalities such as creating a standard deck of 52 cards with four suits (hearts, diamonds, clubs, and spades) and 13 values, shuffling, and dealing cards. In Blackjack, the game simulates rounds with the player and dealer, managing card values and handling special rules for aces. Players can hit or stand to aim for a score as close to 21 as possible without exceeding it, while the dealer plays under specific constraints. The Poker game allows for simple multi-player rounds, distributing five-card hands to each participant and enabling basic betting or standing options. A simplistic hand strength assessment is used to determine outcomes, with rudimentary decision-making for the AI opponent (machine). This module emphasizes card dealing, hand management, scoring, and basic strategy.

######################

  • 3. Bingo: The Bingo module allows users to simulate a complete bingo game experience, generating unique 3x5 matrix bingo cards with 15 random numbers for each player. It displays all cards, highlighting called numbers with color-coding (green for matched and red for unmatched). Players can select their card and watch as numbers are drawn from a randomized "bingo drum" of 90 numbers. The game tracks matches on the player's card, announcing a line (a complete row) and full bingo when achieved. Opponents' progress is also monitored, creating a realistic and interactive bingo game environment within the casino games library.

######################

  • 4. Dice: The Dice Game module simulates a classic dice-rolling game where users can place various types of bets on the outcome of a roll. Players can choose from different betting options, such as predicting a specific number, the sum of two dice rolls, whether the result will be high (large) or low (small), or whether the sum will be even or odd. The game then evaluates whether the player's bet is successful based on the randomly generated dice result, providing feedback on whether they won or lost their bet. This module creates an engaging, virtual dice game experience.

######################

Using the function main_menu() the user can choose the game they want to play and the library will start the game.

  pip install casino-bdata4-e==0.0.3
  from casino-bdata4-e import *
  main_menu()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

casino_bdata4_e-0.0.3.tar.gz (12.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

casino_bdata4_e-0.0.3-py3-none-any.whl (12.9 kB view details)

Uploaded Python 3

File details

Details for the file casino_bdata4_e-0.0.3.tar.gz.

File metadata

  • Download URL: casino_bdata4_e-0.0.3.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for casino_bdata4_e-0.0.3.tar.gz
Algorithm Hash digest
SHA256 d2f74f490c3a4d7a4f007913c7d97661c328f11daaf2969a8e8cfc02e5318675
MD5 cfb22cace347fdcc4f6cb87f17180e2e
BLAKE2b-256 4602a05fe3150afee7f17bb940217754ad2f48a92eeaa1b92cc371469f8b9683

See more details on using hashes here.

File details

Details for the file casino_bdata4_e-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for casino_bdata4_e-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 b6e5aba84fef9f927ff6fb6e9cdfec7e526bd0cce4b1dc3caf7bd121a2983b36
MD5 5253fbda54f0f66b6334f52abcc7c9ba
BLAKE2b-256 32b0aeb0e528331867d411c9ab95708b94314dab54c982e85506a5165068196a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page