Skip to content

Commit

Permalink
Merge pull request #103 from iamSamuelFu/proj01
Browse files Browse the repository at this point in the history
Proj01
  • Loading branch information
brianslee authored Mar 19, 2018
2 parents 26bef3c + 6d4ff7b commit 915389e
Show file tree
Hide file tree
Showing 107 changed files with 22,117 additions and 231 deletions.
39 changes: 39 additions & 0 deletions W18_proj00.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
## Samuel Fu, Xingxing Geng
- Samuel Fu (GitHubID:`iamSamuelFu`)
- Xingxing Geng (GitHubID:'`xingxinggeng`)

## A)
This project builds up a game simulating table tennis, which can have most up to 2 players playing at the same time on the same computer.

## B)
- As a user, I can start a new game so I can play against another player on the same computer.
- As a user, I can choose the color of the ping pong ball and the difficulty level of the game before I start a new game.
- As a user, I can control the paddle to hit or hold the ball.
- As a user, I can lose a life if I let the ball get past by my paddle.
- As a user, I can store my name and my score in this game if I made top five highest scores.

## C)
The software definitely runs. It creates a rectangle panel in the middle of the screen to provide an interface for users, allowing them to start a new game, check the instructions or exit. It simulates the game of table tennis, putting two paddles on both sides and a ball bouncing between.

## D)
- As a user, I would like to be able to throw a curving ball.
- As a user, I would like to be able to adjust the size of the screen when the program is running.

## E)
Current README.md does a great job both introducing this game and tracing through the development and improvements of this program. It is really helpful for me to get to know this program and how to maintain it. However, I think a collection of pictures from each version can be added into the file, to display the development of this game more visually.

## F)
The build.xml is a little bit messy in formatting but runnable. Some targets needs description, but there is no JWS stuff needs to be removed.

## G)
The "issues" listed pointed out many possibilities this game could turn into. All the bugs and improvements in "issues" are explained in details respectively. There are definitely enough questions for us to earn 1000 points, though some of the issues are minor.

## H)
Hit star to gain life :https://github.com/ucsb-cs56-projects/cs56-games-pong/issues/100

## I)
The code overall is formatted well, and the purposes of class and methods of are clear. The variable names are mostly self-documenting. However, there are more comments than it actually needs. It makes the code easier to read within their own class, but some comments only explained what the code does, instead of why we use this code. Therefore, it is difficult to see the relationship between classes without the class diagram. I would tell whoever is going to work on the code that each object in this game (such as "paddle," "pong," and "game") was coded in seperate file under the same directory. Each file implements what each object does. It will be easier to understand the code by figuring out what object the method belongs to.

## J)
The test coverage is very limited, and there is no JUnit tests at all. There are only handful of tests, and most of them are commented out for unknown reasons. The coverage can be expanded by adding more tests of some basic methods in each class and some corner cases on top of that.

43 changes: 43 additions & 0 deletions docs/allclasses-frame.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_151) on Thu Feb 15 18:41:46 PST 2018 -->
<title>All Classes</title>
<meta name="date" content="2018-02-15">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<script type="text/javascript" src="script.js"></script>
</head>
<body>
<h1 class="bar">All&nbsp;Classes</h1>
<div class="indexContainer">
<ul>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Ball.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">Ball</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/BallTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests" target="classFrame">BallTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/ColorPrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">ColorPrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/CustomModePrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">CustomModePrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/DifficultyLevel.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">DifficultyLevel</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/DifficultyLevelPrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">DifficultyLevelPrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/highscore/DisplayHighScores.html" title="class in edu.ucsb.cs56.projects.games.pong.highscore" target="classFrame">DisplayHighScores</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/EndOfGame.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">EndOfGame</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/Game.html" title="class in edu.ucsb.cs56.projects.games.pong" target="classFrame">Game</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/GameOver.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">GameOver</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/highscore/HighScore.html" title="class in edu.ucsb.cs56.projects.games.pong.highscore" target="classFrame">HighScore</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/HighScoreTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">HighScoreTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/instructions/Instructions.html" title="class in edu.ucsb.cs56.projects.games.pong.menu.instructions" target="classFrame">Instructions</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/InstructionsTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">InstructionsTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">MainMenuComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuUI.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">MainMenuUI</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MenuPaddingComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">MenuPaddingComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MenuTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">MenuTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Paddle.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">Paddle</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/PaddleTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests" target="classFrame">PaddleTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/PlayTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu" target="classFrame">PlayTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Pong.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">Pong</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/PongTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests" target="classFrame">PongTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Screen.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay" target="classFrame">Screen</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/sound/SoundEffect.html" title="class in edu.ucsb.cs56.projects.games.pong.sound" target="classFrame">SoundEffect</a></li>
</ul>
</div>
</body>
</html>
43 changes: 43 additions & 0 deletions docs/allclasses-noframe.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_151) on Thu Feb 15 18:41:46 PST 2018 -->
<title>All Classes</title>
<meta name="date" content="2018-02-15">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<script type="text/javascript" src="script.js"></script>
</head>
<body>
<h1 class="bar">All&nbsp;Classes</h1>
<div class="indexContainer">
<ul>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Ball.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">Ball</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/BallTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests">BallTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/ColorPrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">ColorPrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/CustomModePrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">CustomModePrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/DifficultyLevel.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">DifficultyLevel</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/DifficultyLevelPrompt.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">DifficultyLevelPrompt</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/highscore/DisplayHighScores.html" title="class in edu.ucsb.cs56.projects.games.pong.highscore">DisplayHighScores</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/EndOfGame.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">EndOfGame</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/Game.html" title="class in edu.ucsb.cs56.projects.games.pong">Game</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/GameOver.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">GameOver</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/highscore/HighScore.html" title="class in edu.ucsb.cs56.projects.games.pong.highscore">HighScore</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/HighScoreTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">HighScoreTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/instructions/Instructions.html" title="class in edu.ucsb.cs56.projects.games.pong.menu.instructions">Instructions</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/InstructionsTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">InstructionsTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">MainMenuComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuUI.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">MainMenuUI</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MenuPaddingComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">MenuPaddingComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/MenuTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">MenuTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Paddle.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">Paddle</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/PaddleTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests">PaddleTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/menu/PlayTextComponent.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">PlayTextComponent</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Pong.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">Pong</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/tests/PongTest.html" title="class in edu.ucsb.cs56.projects.games.pong.tests">PongTest</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/gameplay/Screen.html" title="class in edu.ucsb.cs56.projects.games.pong.gameplay">Screen</a></li>
<li><a href="edu/ucsb/cs56/projects/games/pong/sound/SoundEffect.html" title="class in edu.ucsb.cs56.projects.games.pong.sound">SoundEffect</a></li>
</ul>
</div>
</body>
</html>
160 changes: 160 additions & 0 deletions docs/constant-values.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_151) on Thu Feb 15 18:41:46 PST 2018 -->
<title>Constant Field Values</title>
<meta name="date" content="2018-02-15">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<script type="text/javascript" src="script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="Constant Field Values";
}
}
catch(err) {
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="overview-summary.html">Overview</a></li>
<li>Package</li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
<li><a href="deprecated-list.html">Deprecated</a></li>
<li><a href="index-all.html">Index</a></li>
<li><a href="help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev</li>
<li>Next</li>
</ul>
<ul class="navList">
<li><a href="index.html?constant-values.html" target="_top">Frames</a></li>
<li><a href="constant-values.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<div class="header">
<h1 title="Constant Field Values" class="title">Constant Field Values</h1>
<h2 title="Contents">Contents</h2>
<ul>
<li><a href="#edu.ucsb">edu.ucsb.*</a></li>
</ul>
</div>
<div class="constantValuesContainer"><a name="edu.ucsb">
<!-- -->
</a>
<h2 title="edu.ucsb">edu.ucsb.*</h2>
<ul class="blockList">
<li class="blockList">
<table class="constantsSummary" border="0" cellpadding="3" cellspacing="0" summary="Constant Field Values table, listing constant fields, and values">
<caption><span>edu.ucsb.cs56.projects.games.pong.menu.<a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuUI.html" title="class in edu.ucsb.cs56.projects.games.pong.menu">MainMenuUI</a></span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th scope="col">Constant Field</th>
<th class="colLast" scope="col">Value</th>
</tr>
<tbody>
<tr class="altColor">
<td class="colFirst"><a name="edu.ucsb.cs56.projects.games.pong.menu.MainMenuUI.HEIGHT">
<!-- -->
</a><code>protected&nbsp;static&nbsp;final&nbsp;int</code></td>
<td><code><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuUI.html#HEIGHT">HEIGHT</a></code></td>
<td class="colLast"><code>480</code></td>
</tr>
<tr class="rowColor">
<td class="colFirst"><a name="edu.ucsb.cs56.projects.games.pong.menu.MainMenuUI.WIDTH">
<!-- -->
</a><code>protected&nbsp;static&nbsp;final&nbsp;int</code></td>
<td><code><a href="edu/ucsb/cs56/projects/games/pong/menu/MainMenuUI.html#WIDTH">WIDTH</a></code></td>
<td class="colLast"><code>640</code></td>
</tr>
</tbody>
</table>
</li>
</ul>
</div>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="overview-summary.html">Overview</a></li>
<li>Package</li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
<li><a href="deprecated-list.html">Deprecated</a></li>
<li><a href="index-all.html">Index</a></li>
<li><a href="help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev</li>
<li>Next</li>
</ul>
<ul class="navList">
<li><a href="index.html?constant-values.html" target="_top">Frames</a></li>
<li><a href="constant-values.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>
Loading

0 comments on commit 915389e

Please sign in to comment.