Git Product home page Git Product logo

rxcg-poker's Introduction

Λambd'em Poker

Description

Client for playing Texas Hold 'em versus AI or human beings with some additional features, possibly.

Feel uncomfortable if you don't know/remember game rules?
Be prepared, read 'em all or tl; dr & look at pictures.

Features

gameplay

Layout

  • table (with shadow! It's important)
  • player seats that display name & balance
  • quasar deck layout (from One Site Which Must Not Be Named)
  • chips layout (from the same source that deck)
  • action buttons, small bet sizing buttons and slider (finally, original)

UX

slider

  • slider to choose bet with big blind step
  • small buttons to choose bet in % of current pot
  • only possible actions are suggested for buttons
  • fold is blocked when check is available

highlight

  • active player is highlighted
  • game results are showed when one player is left
  • AI think time is 1s
  • showdown is showed only for 2.44s, don't miss it!
  • clicked action button is faded

Logic

  • dealing random cards and board
  • posting blinds
  • change of positions
  • handling of bet rounds
  • detecting & comparing of poker combinations
  • detecting winner(-s) and awarding them

AI

  • 5 predefined play styles: telephone, passive, loose, tight and aggresive
  • chooses move on pre-flop depending on hand range and size of incoming bet
  • has probabilities of performing some move relying on chance and combination strength
  • considerates random distribution for choosing bet size
  • can use continuation bets up to triple barrel bluff on air

Status

Solid release candidate is made, although some bugs are sneaking nearby and deep inside you still think that some shizzle sugar stuff like move timer or highlighting of winner is critically essential.

Play to your heart content versus AI or at least try winning all of them. Just remember, none of them ever pretends to be hazardous entity and still requires at least twice as much work as was done to be reborn in Serious Strategy Unit ©.

Build and run

First of all - install Stack tool.

Setup it on first launch:

stack setup

For launching client:

stack build && stack exec poker

Use command line argument to explicitly set opponent play style:

stack exec poker %playstylename%

Available options:

  • telephone
  • passive
  • loose
  • tight
  • aggresive
  • random

When choosing random play style, one of previous 5 is chosen fortuitously. Also, it's default setting for missing, misspelled or multiply argument.

Disregard that, Cabal is fine too.

cabal install --only-dependencies
cabal run %playstylename%

Documentation

Initial project requirements document can be read here. And for brave ones, feel free to look through haddock documentation, it's offline version is located in docs/lambdem-poker-0.6.

Additional stuff

As part of project web based range selector is supplemented.

ranges

Wait, what?! That peasant front end?! In my cozy haskell project?!

Testing

Contains some hand templates to test detecting and comparing of combinations. Isn't pretending to be a test coverage at all and still requires a human eye to verify results. Consider it like sandboxed appendage for debugging purposes.

For launching tests use:

stack test

Don't even try to run if you don't know what you're exactly doing!

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.