Skip to content

Conversation

@Max4407
Copy link

@Max4407 Max4407 commented Dec 12, 2025

Most base mechanics are implemented but it is rough around the edges. Uno now uses the new-ish card classes and ASCII art. Special cards mechanics (skip, reverse, +2/+4, and wild) are not yet implemented and that's what I am working on next. I have not yet seriously tested for any bugs, so there may be a couple with the current implementation.

image image

kevin8999 and others added 30 commits September 17, 2025 15:49
This commit adds the file and beginning code for roulette.

When the user enters the casino, they may choose roulette and be greeted with a roulette sign.
Adds `play_roulette()` function in `roulette.py` to the global namespace.

NOTE FOR FUTURE MAINTAINERS: Please use something else other than the global namespace when accessing functions.
USE OF THE GLOBAL NAMESPACE SHOULD BE AVOIDED FOR SECURITY REASONS.
REASON: Python does not declare data types like other programming languages do.
Placing a generic `type` before the variable name will raise an error. This is why it is being removed.
Make comments more clear in `Roulette.__init__()`
Add a "spin wheel function" to the `Roulette` class that randomly picks an index on the wheel
`AmericanRoulette` inherits from `Roulette` class. It will store its rules inside the class.
Add values found in standard American roulette wheel
This commit moves the warning message to not run `roulette.py` as main to the top of the file.

The bottom of the file contains

```
if __name__ == "__main__":
```

However, this line is never run because these import lines:

```
from casino.card_assets import assign_card_art
from casino.types import Card
from casino.utils import clear_screen, cprint, cinput

import casino.accounts
```

will raise an error.
Adds function that lets users submit bets for all `accounts` in the `Roulette` class
Adds a `"""` that wasn't present in `Roulette.submit_bets()`
Adds `Roulette.roulette_sort_key`. Helper function that sorts roulette string values found in `Roulette.wheel` when using the built-in `sorted()` function
Adds two variables that determine the valid colors and numbers of a wheel.
Made deck size modular and user input dependent. For now this can effectively serve as difficulty because higher deck values mean counting cards becomes more and more difficult if not impossible.
Changes `bets` from tuple to dictionary.
Ensures all values use the full, lowercase name for clarity.

For example, instead of:

```
{"color": "r"}
```

the output is

{"color": "red"}
kevin8999 and others added 28 commits October 28, 2025 15:50
refactor: Refactor card deck handling
FIX for issue ufosc#66: Edited theme prompt to signify default selection
…t colors, changed formatting to match Blackjack, created roulette table
…ncise code, fixed issue of printing order by doing so
seperated logic of printing game to a function for more clrear and co…
Added double down mechanic to blackjack game, as requested in issue ufosc#85.
Implement insurance mechanic in Blackjack (ufosc#83)
FIX / POKER - Clear screen on raise (Issue ufosc#61)
@kevin8999
Copy link
Contributor

kevin8999 commented Dec 28, 2025

I noticed that this PR has a lot of commits and that a lot of files have been changed (including code files for other games). This PR needs to be culled so that it only modifies files related to Uno.

It could also just be an issue related to merging because it is similar to PR #34.

@Max4407
Copy link
Author

Max4407 commented Dec 28, 2025

Kevin, I think this is because the feature/uno branch is behind the main branch. I didn't make most of the changes that are in the pull request, they are just things that I pulled from main. The stuff I personally wrote to add was 95% in the casino/games/uno directory and I didn't use AI that would go and change a ton of other stuff without me realizing. I could totally be wrong because it's been a few weeks since I wrote the code but I think this could be fixed if this branch was updated to include most of the stuff in main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.