GithubHelp home page GithubHelp logo

card_game_sevens's Introduction

Intro:

The following is a simulation of a variation of ohel. There are 10 rounds and the game is based on points and contains 'trumps'. Trumps represent the leading strongest suite. 10 Points are awarded if the player determined the amount of 'tricks' (hands won) in the betting round plus an extra 2 points per 'trick' won.

For each round there are two phases. For the first phase players take turns from the 'left' of the dealer (in the simulation case incremental player number) bidding on the amount of tricks they think they will win. With the dealer dealing last the sum of the bids can not equal the amount of cards in each players hand.

For example if it was round 2 (each player receives 2 cards) of a 3 player game and the current bids were 1 and 0 player 3 can not bid 1 as then the total bids would sum to the amount of cards.

The next phase is the playing phase. During this phase the player who bid first will lead. The leading card's suite is the current winning suite. The players will then take turns playing a single card to follow. If the player has the same suite as the leading card the player must play this suite (or a card with the same suite in the case of multiple). This is called 'following suite'. If the player can not follow suite then any card can be played. The winner of the hand round is the player that played the highest starting suite or if trumps are present the highest trump. The player who won the trick is then able to lead until each player is no cards remaining.

For this variation the rounds up to 7 contain incremental cards starting from 1. Round 8-10 are special rounds. Round 8 there is no trick available. For round 9 the trick is face down during the bidding round and for round 10 both the players cards and trick are unknown to them.

Functions required to enter a bot.

The game currently takes two functions your bidding strategy and play strategy. The arguments are as follows:

bidStrategy(gameRound, scoreCard, currentBids, cards, trump)

playStrategy(gameRound, scoreCard, currentRoundResults, cards, trump, playerChoices, currentRoundStack)

card_game_sevens's People

Contributors

arno1da avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.