MVC 'architecture'. I would like a convenient way of specifying the rules of a card game including aspects such as hands or tricks, scoring, which cards from the deck or pack are used, and so on. Does anyone know of anything like this, preferably in Javascript?
Thanks for any guidance.
There's a good article here (and as a complement I suggest the companion article about displaying playing cards with CSS that's here). Nothing much to do with Python though!-) If you do want an example of handling a card game (including showing the cards as images in Tkinter) with Python, try this one (which however has nothing to do with Javascript: not sure why you've tagged your question with both languages).
C++ and Javascript have enough similarities that you should be able to at least understand general concepts and how things work from C++ code..?
http://drac-cardlib.sourceforge.net/
I found DRAC to be a good reference for general card game programming. I ended up applying a few of their approaches in my own poker AI simulations.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With