Skip to main content

A Rock Paper Scissor Game

Project description

Play rock paper scissors against a computer!

RPS workflow

Features

  • Fun to play!
  • Easy to install
  • 100% Test Coverage
  • Beautiful ASCII art
  • Two different difficulty levels
  • A hard difficulty level that utilizes history matching
  • A detailed mode that shows the logic behind the computer move
  • Tested using GitHub Actions

Quickstart with pipenv

Installing Rock Paper Scissors Game is simple with pipenv.
pipenv install RockPaperScissorsFullGame

Run the package directly from the command line:
python -m RockPaperScissorsFullGame

Quickstart without pipenv

Creates a new virtual environment with the name .venv:

python3 -m venv .venv

Activate the virtual environment named .venv:

On Mac:

source .venv/bin/activate

On Windows:

.venv\Scripts\activate.bat

Install Rock Paper Scissors Game:

pip install RockPaperScissorsFullGame

This package is developed as a game to be played in the shell.
Run the package directly from the command line:

python -m RockPaperScissorsFullGame

How to play

Choose settings

After running the game, you will be asked if you want the ascii art to be visible.

Do you want ascii art to be visible?
select one
(1) Yes
(2) No

Enter "1" or "yes" if you want to turn on the ascii art.
Enter "2" or "no" if you want to turn off the ascii art.

Play the game

Play rock paper scissors by choosing the item.

Enter your item: (rock, paper, scissors)

Enter "rock" or "r" if you want to choose rock.
Enter "paper" or "p" if you want to choose paper.
Enter "scissors" or "s" if you want to choose scissors.

The shell will print the result of this round.

You choose Paper. Computer chooses Rock.
You Win.

You will be asked to choose the difficulty level.

Enter your preferred difficulty (easy, hard): 

Enter "easy" to play the easy mode where computer will randomly choose between rock, paper, and scissors.
Enter "hard" to play the hard mode where computer will use history matching to identify pattern then choose the item.



(Hard mode only) You will be asked if you want to turn on the detail mode. With detailed mode on, the terminal will show the outcome of previous rounds.

Do you want to turn on detail mode?
select one
(1) Yes
(2) No

Enter "1" or "yes" if you want to turn on the detail mode. Enter "2" or "no" if you want to turn off the detail mode.

Quit the game

Enter "quit" to quit the game.

Contributor

Benji Luo
Brian Lin
Robert Chen

Help building this project

  1. Fork our repository(link).
  2. Contribute and push any changes to your forked repository.
  3. Create a pull request from your forked repository.
  4. We will check the pull request and include any meaningful changes when we update the package.

Link to the PyPI page

https://pypi.org/project/RockPaperScissorsFullGame/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

RockPaperScissorsFullGame-1.2.0.tar.gz (45.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

RockPaperScissorsFullGame-1.2.0-py3-none-any.whl (33.6 kB view details)

Uploaded Python 3

File details

Details for the file RockPaperScissorsFullGame-1.2.0.tar.gz.

File metadata

File hashes

Hashes for RockPaperScissorsFullGame-1.2.0.tar.gz
Algorithm Hash digest
SHA256 a7845bb52ea9406d5de0b570560a532736e30e371e0cb7c5f7d4b488056e30a9
MD5 706351928509e2d2f2343af3cbbd4adc
BLAKE2b-256 980505e1ffa7a64f99e88a9858647a16c6790b42a4268ecc7e81416c1a998d45

See more details on using hashes here.

File details

Details for the file RockPaperScissorsFullGame-1.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for RockPaperScissorsFullGame-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 81cd93b5e2396e3a23f61d33d56271a8303316e6d0f017b5e9d510c3bc3852bb
MD5 4475da7c088baa6219ca814c8747d889
BLAKE2b-256 6996adb75f33f36e5f7a13aa3a8d12734fba8e8dca90b5e07f8bda49c65b04eb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page