HomeSuomeksi

Wanhapiika - Poker Game

PythonPython
KivyKivy
KivyMDKivyMD

Background and Objectives

The idea for this project sparked from a desire to practice Python development more extensively than school assignments allowed. I built the project from scratch, focusing on game mechanics and architecture. The vision was to design a poker game that could eventually run on physical hardware with buttons or a touchscreen – leading to the choice of KivyMD as the primary framework.

Technical Execution

  • Deck Logic: The first challenge was implementing a 52-card deck and a selection mechanism. I used a list-based approach combined with Python's random function to draw five cards. Images are dynamically fetched based on the card names. To simulate a real-life deck, cards are "shuffled" only at the start, and drawn cards are removed from the deck.
  • Animations: To enhance the visual experience, I implemented custom animations for shuffling, dealing, and "holding" cards, providing a polished feel to the gameplay.
  • Doubling and Logic: The "Double or Nothing" feature compares a single drawn card's value. The core of the game logic involves complex number crunching and card comparisons to identify winning hands and calculate payouts dynamically.

Lessons Learned

Wanhapiika was a fascinating deep dive into coding and logical problem-solving. It provided valuable experience in building functional applications from the ground up. While the core features are complete, the project remains an open canvas for further refinement and new features.