DEV Community

Cover image for ๐ŸŽฒ Game 21 โ€” Cheburashka & Gena
MUHAMMAD
MUHAMMAD

Posted on

๐ŸŽฒ Game 21 โ€” Cheburashka & Gena

Built in Pure Python + Tkinter
๐ŸŠ Introduction

It started as a small side project โ€” just a cheerful, nostalgic mini-game.
Thatโ€™s how ๐ŸŽฒ Game 21 โ€” Cheburashka & Gena was born โ€” a cartoon-style dice game where you play against the famous Russian duo Cheburashka and Gena the Crocodile.

You roll dice, collect points, and watch cartoon faces react to your luck โ€” all made entirely in pure Python.

๐Ÿงฉ Gameplay

Roll dice to get as close to 21 points as possible โ€”
but if you go over, you lose!

Decide whether to roll again or stop, then watch your AI opponents โ€” Cheburashka and Gena โ€” take their turns automatically.
The one closest to 21 wins.

๐Ÿ–ผ๏ธ Features

๐ŸŽฎ Cartoon-styled interface
๐ŸŽต Procedural sound & music
๐Ÿ† Local leaderboard (SQLite)
๐ŸŒˆ Dynamic color themes
๐Ÿ—ฃ๏ธ English & Russian languages

Run it instantly:

python game21.py

GitHub โ†’ github.com/renocmon-cloud/Game21_v8_1

Website โ†’ belcantorest.me

๐ŸŽจ Design & UI

A custom CartoonButton class makes Tkinter look alive โ€” rounded corners, shadows, gradient fills, and small โ€œbounceโ€ animations.
No images โ€” everything is generated procedurally with Pillow.

Each theme (Sunny โ˜€๏ธ, Ocean ๐ŸŒŠ, Mint ๐ŸŒฟ) has its own color palette, or you can let it switch automatically for variety.

๐ŸŽต Sound & Music

No sound files โ€” just math.
Python generates short WAVs for dice rolls and melodies using wave, math, and struct.
Itโ€™s a tiny, built-in synthesizer ๐ŸŽน

๐Ÿง  Lessons Learned

Tkinter can look modern with creativity

Procedural art and sound are pure joy

SQLite is perfect for small games

Simplicity can be surprisingly powerful

๐Ÿ’ฌ Conclusion

Game 21 โ€” Cheburashka & Gena is a love letter to simplicity and charm.
No frameworks, no assets โ€” just Python, imagination, and a bit of nostalgia.

Top comments (0)