• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
Ajan RedDevil

AI for card game "Marriage - A Popular Nepali Game"

4 posts in this topic

Me and my friends have started our minor project on card game "Marriage - A Popular Nepali Game"...
We've used Java as our programming language...
We're a newbie in the field of AI...
So could anyone suggest any books regarding AI for card games...
Other helpful info related to our project would be handy...
0

Share this post


Link to post
Share on other sites
Marriage is a popular card game in Nepal especially in the Kathmandu valley.

Marriage consists of three decks of card which means that there are a total of
156 (52*3) cards and each card has two more similar cards plus three special cards i.e 'Joker faced cards' are used taking the total cards to 159.

First a dealer is chosen among the players and then on, the deal continues in a round-robin fashion. The dealer deals 21 cards to each player.

After dealing the cards, the first turn is that of the player next to the
dealer. This player draws a card from the deck.



Now, each player should build a pre-defined sets of card
(
i.e a
'Pure Sequence' - If you have three cards of the same suite in a sequence then
what you have is a Pure Sequence.
E.g. 7 of Spades, 8 of Spades, 9 of Spades.

and

'Tunnela' - If you have three of the same card then what you have is a Tunnela. E.g. 5 of Diamonds, 5 of Diamonds, 5 of Diamonds.
Also three special cards also make a tunnela and is awarded extreme
points.

Note: Tunnela shown at the very beginning when the player hasn't drawn any card
has points awarded to the player if the player can view the Joker before
the end of the game.
)



The first player to show three sets of pure sequence or tunnela gets the opportunity to select a Joker.
(
'Joker' - Same card and the same suit is the joker. Also the card above and
below the joker with the same suit is also the joker.
E.g.If the joker is an Ace of Hearts,
then the card above i.e Two of Hearts is also a joker
and the card below i.e King of Hearts is also a joker.

'Alter' - Same card as the joker but of different suit but of the same color
are alters.Alter carry more points than Joker.So, player must be aware
of accidentally or may be tricked into throwing alter.
E.g.If the Joker happens to be Queen of spade,
then Queen of Club is the alter.

'Ordinary Joker' - All the same numbered cards as the Joker but of different
suites are ordinary joker.

'Joker faced card' - These special cards carry points similar to alter and
is used as a Joker to finish the game. Player who has
viewed the Joker can only take advantage of these special
cards. So, player with these special cards at the beginning
during shuffling have a clear advantage as once he has
viewed the Joker he gets instant points regardless he has
any Joker/Alter.

Note:Player may demonstrate more than three sets of Pure sequence or tunnela
i.e. Player may demonstrate four or five sets before viewing the Joker
Or
Player may show pure sequence consisting of more than three cards
i.e. 7,8,9,10 of Hearts also forms a pure sequence or even more
But this has its downside as the player may find it difficult to
finish the game later on. So, he may use Joker/Alter/Special cards to
form dirty sequence of any length.
)



'Marriage' - Once the joker has been viewed player forming pure sequence
involving forms a marriage.
i.e. Joker, the card above and below forming a pure sequence is
marriage.
E.g. If 6 of diamond is the Joker then, 5, 6 and 7 of diamond forms marriage.

Note: Marriage is awarded more points.Also double Joker values more points.



The players who have viewed the Joker can only finish the game. In order to finish the game they should arrange the remaining cards in a set either using
the pure sequence, joker to form dirty sequence, dirty triplet but tunnela is
not allowed to finish the game. When no card is left to be arranged in a set,
the player declares that he has made the game.
(
'Triplet' - If you have three same numbered cards but of different suites then
what you have is a Triplet.
E.g. 10 of Hearts, 10 of Spades and 10 of Diamonds.

'Dirty Sequence' - If you have two cards with same suite in a sequence and the
third is a Joker then what you have is a Dirty Sequence.
Or
If you have two jokers and the third is a card then what you
have is a Dirty Sequence.
E.g. 10 of Clubs, 11 of Clubs and a Joker.
10 of Clubs and two Jokers.

'Dirty Triplet' - If you have two cards from a Triplet and the third one is a
Joker then what you have is a Dirty Triplet.

Note:It ain't necessary to form dirty sequence and dirty triplet with jokers
only. Players may also form dirty sequence and dirty triplet with alter and
Ordinary Jokers.
But when points are allocated then Jokers are only counted. Ordinary Jokers
do not have any points.Alters and 'Joker faced cards' have more points than
Jokers.
)


There is an alternative way to finish the game. Player may opt to play 'Doubly'
i.e. he/she may complete seven Doubly( i.e. two same cards of the same suit)
to view the Joker and then one more doubly to finish the game.So, eight doubly
means victory.

Note: Player preferring doubly cannot form any sequence/triplet with joker.
He/she is awarded extra points for playing doubly and also for all the
jokers.So, player should suspect if other players are playing doubly as
he/she may have to sacrifice even arranged set of cards to save the game
before it's too late.




While it is true that the player who has made the game will have some advantage but it is imperative to know that even if he has made the game he may have to pay points to other players.
i.e. Other players may have Jokers,Alters and special cards carrying more points
than the player finishing the game.


Varying rates of money can be assigned to a point. This has to be agreed among the players while starting to play.


Points System
Points
Ordinary Joker Tunnela 10
Joker Tunnela 20
Special cards tunnela 35
Simple Tunnela(successful) 5
Points Due (Joker Seen) 3
Points Due (Joker Not Seen) 10
Single Marriage 10
Double Marriage 30
Triple Marriage 50
Single Joker above/below 2
Double Joker above/below 5
Triple Joker above/below 10
Single Joker 3
Double Joker 8
Triple Joker 15


Note:Negative points are also awarded on various occasions
1>When player prematurely tries to finish the game even though he/she hasn't
completed the game.
2>When the player who has seen the Joker and throws a joker to the next
player who has also seen the Joker.

These points are calculated with respect to the player who has finished the game.
Player finishing the game have advantage when other players haven't viewed the Joker.In some cases, it is the player finishing the game who happens to pay.
So, its a lot of fun, tricks , risk and total intelligence come into play.





Anyone please suggest appropriate AI books for "Marriage"....
0

Share this post


Link to post
Share on other sites
There really aren't any AI books for card games that I can think of. The reason for that is that AI is not designed by genre... e.g. shooter, strategy, RPG, card game. AI is designed by decision. You select an AI technique that most effectively helps you make a given decision.

Now the types of decisions that you make may tend to align with a genre, but they aren't necessarily exclusive to it. For example, in a shooter, you do a lot of targeting of other players and objects. That's the point. However, in an RPG or strategy game you do that as well... but it might not be the primary focus.

The same can be said for evaluation decisions - i.e. "which of these two options is more important to me?" You do that for target selection in an FPS, spell selection in an RPG, where to build a city or structure in a TBS/RTS, etc. Never mind the genre, the choice we are making needs to be solved by evaluating the relative merits of the various options. (Which is what my book deals with.)

In card games, you deal with that aspect, but you also have a major aspect of uncertainty. You frankly don't know what you can't see. That's where dealing with Bayesian inference, Markov models, and Monte Carlo techniques.

The bottom line in any AI modeling is to simply look at the individual decision that you are making, take into account what matters, and choose a technique for solving that one decision. In order to do this, obviously, you must know what the techniques are. Most of the general AI books will teach these to you. However, many of them are not in the proverbial realm of "rocket science". Most of them are common sense.

What I'm trying to say is, don't think there is a Book of AI Magic out there that will solve your problem for you. There isn't. You still need to think. In fact, I recommend trying the "thinking" approach immediately.

That being said, card game AI is notoriously difficult even for simple single-deck games. Most of this is due to the unknown quantities as I mentioned above but a lot of it is due to the huge number of potential solutions that are available. (NP-Hard for those conversant with complexity theory.) Believe it or not, these are situations that people can actually intuit fairly quickly but computers have a hard time "solving" for.

Anyway, the answer to your card game AI book is #NULL.
The solution to your problem is #BLOODY_HARD.
The suggested path is #LEARN_BASICS_OF_AI + #THINK

Sorry I didn't have better news.
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0