Acey Deucey, also known as 'In Between' and 'Sheets', is more of a fun game than a card game, but you could win some money playing it. The general principle behind Acey Deucey is that the player is dealt two cards face up. He/she then bets whether the next card will fall numerically between the first two cards. If it does, the player wins!

For this exam, you will write a program using Model 2 Architecture (MVC design pattern), or Model 1 Architecture ( either JSPs or Servlets as Controller/View) - your choice, HTML, CSS and Java classes that will allow a user to play a single player version of the game Acey Deucey.

Acey Deucey Resources:

You can read about the game of Acey Deucey at the following Web sites. You can visit other sites if you wish. Use this information to understand the problem and how it might be solved. Keep in mind that these are for general background, your solution should follow the Acey Deucey variation described below. Remember, you are not likely to be able to write a program for a problem if you don't fully understand the problem before you program it.

  • Wikipedia: http://en.wikipedia.org/wiki/Acey_Deucey (card game)
  • Bicycle Cards: https://www.bicyclecards.com/how-to-play/in-between/

MIST4630 Acey Deucey Variation:

Use the following game rules for our Acey Deucey variation. These variations from the usual rules are provided to reduce the scope of the program and make it a little easier for you to develop the game using the components you currently know how to use and to complete during the time allowed.

  • Shuffle: You should shuffle the deck before each new 3 card deal (this is necessary based on how we know to keep up with data between requests at this time).
  • Deal: As we draw and lay out the deal, three cards are laid out -left, middle and right. The left and right cards are face up for the player to see while the middle card is initially face down. In our version, the left card should always be a lower card than the right card (hint: draw the cards, then switch them if necessary before assigning them to the images on your view).
  • Bet Results: We will use the following rules when assigning winnings/losses:
    • If the value of middle card is between the values of the left and right cards, then the deal is a win - add the value of the bet to the player's current bank.
    • If middle card is outside of the range of values defined by the left and right cards, then deal is lost - subtract the value of the bet to the player's current bank.
    • If the middle card is equal to one of two outer cards, then its a draw no money is added or subtracted from the player's current bank.
    • Handling aces- for this variation, a single ace will always be on the left so it counts as a low ace (value=1).
    • Special case Left card value = Right card value: Instead of betting on high/low, we will allow a player to bet on whether the middle card is also equal. If they are correct, they win twice the amount of the bet, but if they are wrong, they lose twice the amount of the bet.
    • Quitting the game: The game is over and the results page is displayed for two possible cases:
      The player decides that they have had enough and clicks the quit button. Results are tallied and displayed on the results view.
      The player's current bank is at or below zero. In this case, the only button displayed is the quit button and the player is not allowed a new deal. Results are tallied and displayed on the results view.

General Program Requirements:

For your program, you must create an Eclipse project that contains Java classes, tsp pages or servlets (your choice), CSS file(s), HTML, and images.

JSPs or Servlets or MVC: You can choose to implement the controller/view using any of the configurations that we have studied so far. You should choose to use whichever you are most comfortable with. You will need at least one set of controller/view components for each of the different views (see Detailed Program Requirements).

Java Classes: Your solution should include at least one Java class that is actually used by your Controller/View components. Two Java classes have been provided along with these instructions. You may import these into your project and use them as is, or you may alter them if you want, or you may write your own from scratch.

CSS file: Your solution should include CSS to style the pages. Your design can be Similar to that shown in my figures but you should put your own design twists on the ld include enough here to demonstrate that you can use CSS for:

  • linking to the same CSS file from all view pages
  • centering the content in the page
  • Use playing card images to display the drawn cards. (the tags of course will be html based but you should CSS to position them)
  • set background colors
  • style the fonts on the page
  • at least three other style items of your choice.
  • It's okay to include a minimal set of CSS within the view pages if warranted, but keep most style commands in the external CSS file.

Playing Card Images: A set of playing card images are provided along with these instructions. Feel free to use these as part of our program. Remember that they need to be imported into the appropriate location of your Eclipse project in order to work with your program.

Other Requirements:

1. Your solution should allow a single user to play either until they decide to quit or they lose all of their money.

2. Be sure to thoroughly test your solution. 10% is deducted off the top for any program with errors (syntax, run-time, compile or logic errors).

3. You may use previous notes, your book, and class examples as reference but all code within your submission must be created from your own, individual efforts.

4. All views should provide appropriate messages regarding the outcome of each bet and the final results of the game for all possible outcomes.

Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.