Skip to content

Latest commit

 

History

History
42 lines (30 loc) · 7 KB

W16_lab05.md

File metadata and controls

42 lines (30 loc) · 7 KB

Ziliang Zeng github: zzeng Matin Akhamzadeh github: makhamzadeh

A. This is a GUI version of a hangman game in which a user can input a custom list of words or use a default list of words to play.

B. As a player I can guess a letter so that I can see if the letter is in the word or not. As a player I can choose to run on the command line or a graphic interface so that I can decide whether I want to see the hangman graphically or not. As a player I can click on the hint button so that I can get a hint from the system if I am stuck. As a player I decide to use a list of my own words so that I can play this game with new possible words.

C. The software runs pretty well. The software provides a set number of letters creating a word that the user is trying to guess. The user is supposed to guess one letter at a time and see if the letter is in the word. If the user guesses wrong, the software will start to draw one body part of a hang man at a time. Once it is completely drawn, the user loses game, but if the user can guess all the letters correctly before the whole hang man is drawn, than the user wins. There is also a counter of the win/loss ratio and a system that records points. There are also hints that the user can use at anytime throughout the game. The system also provides the user with insturctions and a set of options.

D. As a player I can click on the hint button so that I can get a hint that will definitely help me if I am stuck. As a player I can select a specific color for the background so that I can choose what color I want the background to be. As a player I can choose to turn off the sound of the game so that I can listen to music while playing this game.

E. Because there are still a decent amount of bugs that are present in the game, I feel that it would be best if those bugs were mentioned in the README.md. For example, when the user clicks on the "hint" option while playing the game, the software may provide a hint that will not help the user at all. In addition, the hints are basically letters given to the user for the word they are currently on. An improvement to this software would be not only hints that give away letters, but hints that would give the user a clue of what the word could be. In my opinion, bugs in general, along with improvements that could be made should be added to the README to make it easier for folks maintaing the code to improve it at a faster pace. Also, the README may include the basic overall goal of the game, however, it does not include the different options the user has when entering a game. For example, the user is able to restart a game, exit a game, get a hint, open the game's options, etc.

F. There are no legacy JWS code that needs to be cleaned. There is already a JUnit Jar File inside the build.xml file for debugging. However there are no descriptions for each of the targets inside the build.xml and currently, all the targets are listed as "Other targets", so it would be more convenient if people who were reading the build.xml could differentiate between the "Main targets" and the "Other targets".

G. There are enough issues that my partner and I could earn 1000 points by working on them. Most of the issues are completely clear, but for the issue that suggests us 'Fix "Hints" button small bug', do we have to fix the Hint button by making it unclickable, or is there perhaps a better way of fixing this bug? Also for making the game a two player game where one person inputs a word and another person tries to guess the word, are we supposed to make an online and offline version of this? As for the 1000 points that needs to be reached, we plan on implementing a two player offline mode (300 points). In addition we plan on adding a feature to the options menu allowing the user to change the color scheme for the background and the image (100 points). We also plan on including the option to guess the full word instead of just one letter at a time (100 points). Another feature we plan on implementing an animation that says "Congratulations" after the user wins a game (50 points). We also plan on improving the README.md file to give the perosn reading it a better understanding of the build file and the code (75 points). And even though the hangman game runs, not all of the tests pass, so we plan on also making sure all the tests pass (100 points). We plan on also making additional test cases to ensure a bug free game because currently, not all of the functions of the game are being tested (200 points). Lastly, we plan on fixing all the number and symbol input filtering issues (75 points). This total comes to 1000 points.

H. Issue1: need tests to pass (ant test does not pass) Issue2: Not only do we want to be able to add a specific color, but we want the whole background to be this color instead of a small portion of it Issue3: Pressing restart after a game ends does not reinitialize the figure of the hangman until after guessing the first letter of a new game. Make it so that the hangman reinitializes after the restart button is pressed

I. The purpose of each class and their methods are clear becaues of their respective names and the comments that accompany each file. In addition, it is also clear how each class relates to one another, but in some files there is a lot of dense code that requires more explanation on what the code does and how it gets that particular job done. The comments already present are helpful in understanding the overall goal of the code, but in some instances, there is not enough of an explanation. For example, in the HangmanGUI.java file, the play() method consists of around 120 lines of code with around fifteen lines of commenting describing what some code is doing. Because of how dense the amount of code inside this method is, this code would require more of an explanation so that the person who is reading the code can understand and follow exactly what is happening. Overall, the quality of the code is great and the comments are adequate, but because the task at hand is to improve every aspect of this code, it is imperative that certain parts of this code requires more comments. Although this code lacks some comments, it still has very clear instance variables and methods. The way each method and variable is named gives the code a better sense of what is happening inside the code and what the user is trying to accomplish.

J. There are JUnit tests that cover some of the basic requirements for the system such as making sure the board displays the correct result after the board is initialized as well as after a specific guess has been made by the user. The JUnit also tests to make sure that the "AlreadyTriedException" behaves as is expected and to make sure that the system declares a winner and loser at the proper time. However, there are still many things that the tests do not cover. For example, they fail to test the hints that are given to the user. They also fail to make sure that the point system and that the total wins and losses are correct. And there are also no tests that involve the restart button the user can click.