RayS99 / ninjagold

Python Flask counter game collecting gold

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ninjagold

Assignment: Ninja Gold Objectives:

  1. Practice using session
  2. Practice having the server use data sent by the client in a form
  3. Practice using hidden inputs

Create a simple game to test your understanding of flask, and implement the functionality below. For this assignment, you're going to create a mini-game that helps a ninja make some money! When you start the game, your ninja should have 0 gold. The ninja can go to different places (farm, cave, house, casino) and earn different amounts of gold. In the case of a casino, your ninja can earn or LOSE up to 50 golds. Your job is to create a web app that allows this ninja to earn gold and to display past activities of this ninja. Guidelines

  1. Refer to the wireframe below.
  2. Have the four forms appear when the user goes to http://localhost:5000.
  3. For the farm, your form would look something like
  4. 
In other words, you want to include a hidden value in the form and have each form submit the form information to /process_money.
  5. Have /process_money determine how much gold the user should have.
  6. You should only have 2 routes -- '/' and '/process_money' (reset can be another route if you implement this feature). alt text

About

Python Flask counter game collecting gold


Languages

Language:HTML 59.1%Language:Python 36.6%Language:CSS 4.2%