Optimized Ticking and Rendering #5

Merged
CyB3RC0nN0R merged 5 commits from feature/optimized_pipeline into develop 2020-07-01 20:17:13 +02:00
7 changed files with 17 additions and 17 deletions
Showing only changes of commit 04931dfd99 - Show all commits

View File

@ -12,7 +12,7 @@ import java.awt.Rectangle;
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* Created: <strong>01.07.2020</strong><br>
*
* @author Kai S. K. Engelbart
* @since Snake 1.1
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public final class Food implements Updateable {
@ -26,7 +26,7 @@ public final class Food implements Updateable {
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @param color the color of the food item
* @param lengthBonus the length added to the snake when the food item is eaten
* @param bounds the bounds of the food item
* @since Snake 1.1
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public Food(Color color, int lengthBonus, Rectangle bounds) {
this.color = color;
@ -42,13 +42,13 @@ public final class Food implements Updateable {
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* @return the length added to the snake when the food item is eaten
* @since Snake 1.1
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public int getLengthBonus() { return lengthBonus; }
/**
* @return the bounds of the food item
* @since Snake 1.1
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public Rectangle getBounds() { return bounds; }
}

delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:42:47 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:13 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:38 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:43:55 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```

View File

@ -36,7 +36,7 @@ public final class FoodFactory {
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*
* @param width the width of the viewport
* @param height the height of the viewport
* @since Snake 1.1
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public FoodFactory(int width, int height) {
this.width = width;
@ -45,7 +45,7 @@ public final class FoodFactory {
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* @return a new food item
* @since Snake 1.1
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public synchronized Food spawn() {
nextSpawnTime = System.currentTimeMillis() + random.nextInt(15000) + 1000;
@ -63,7 +63,7 @@ public final class FoodFactory {
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* @return the time after which a new food item should be spawned
* @since Snake 1.1
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public long getNextSpawnTime() { return nextSpawnTime; }
}

delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:32 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:44 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:44:52 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```

View File

@ -10,7 +10,7 @@ import java.awt.Graphics2D;
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* Created: <strong>01.07.2020</strong><br>
*
* @author Kai S. K. Engelbart
* @since Snake 1.1
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public final class Handler implements Updateable {
@ -24,7 +24,7 @@ public final class Handler implements Updateable {
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*
* @param snake the snake
* @param foodFactory the food factory
* @since Snake 1.1
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public Handler(Snake snake, FoodFactory foodFactory) {
this.snake = snake;

delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:09 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:45:16 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```

View File

@ -147,7 +147,7 @@ public class Snake implements Updateable {
/**
* @return the current {@link Direction} of the snake
* @since Snake 1.0
* @since Snake 1.2
*/
public Direction getDirection() { return direction; }
@ -159,7 +159,7 @@ public class Snake implements Updateable {
/**
* @return a rectangle representing the head of the snake
* @since Snake 1.1
* @since Snake 1.2
*/
public Rectangle getHead() { return tiles.get(0); }
}

View File

@ -18,7 +18,7 @@ public interface Updateable {
* Here should the actions be implemented that are supposed to happen when a new
* frame gets created.
delvh commented 2020-07-01 19:54:02 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*
* @since Snake 1.0
* @since Snake 1.2
*/
default void tick() {}

View File

@ -14,7 +14,7 @@ import java.util.TimerTask;
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* Created: <strong>01.07.2020</strong><br>
*
* @author Kai S. K. Engelbart
* @since Snake 1.0
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public class Viewport extends Canvas {
@ -33,7 +33,7 @@ public class Viewport extends Canvas {
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* @param gameRoot the game object responsible for updating the rest
* @since Snake 1.0
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public Viewport(Updateable gameRoot) {
this.gameRoot = gameRoot;
@ -43,7 +43,7 @@ public class Viewport extends Canvas {
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* Starts the render task.
*
* @since Snake 1.1
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public void start() {
if (renderTask != null)
@ -72,7 +72,7 @@ public class Viewport extends Canvas {
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
/**
* Stops the render task.
*
* @since Snake 1.1
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
* @since Snake 1.2
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
*/
public void stop() {
renderTask.cancel();

delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:55:38 +02:00 (Migrated from github.com)
Review
 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:56:50 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 19:58:09 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```
delvh commented 2020-07-01 20:04:49 +02:00 (Migrated from github.com)
Review
	 * @since Snake 1.2
```suggestion * @since Snake 1.2 ```

View File

@ -32,7 +32,7 @@ public class Endscreen extends JDialog {
public Endscreen(int score) {
this.score = score;
setTitle("Endscreen");
setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
setBounds(100, 100, 700, 700);
getContentPane().setLayout(new BorderLayout());
contentPanel.setBorder(new EmptyBorder(5, 5, 5, 5));