Browse Source

Merge remote-tracking branch 'origin/Game' into develop

AIPlayer
FelixKrull 3 years ago
parent
commit
dd82f01e10
  1. 7
      src/main/java/Figure.java
  2. 3
      src/main/java/Game.java
  3. 1
      src/main/java/Gameboard.java
  4. 2
      src/main/java/Player.java
  5. 6
      src/test/java/GameTest.java
  6. 4
      src/test/java/PlayerTest.java

7
src/main/java/Figure.java

@ -6,4 +6,11 @@ public class Figure {
this.position = -1; this.position = -1;
} }
public void setPosition(int position) {
this.position = position;
}
public int getPosition() {
return position;
}
} }

3
src/main/java/Game.java

@ -8,10 +8,9 @@ public class Game {
public static void main(String[] args) { public static void main(String[] args) {
Game g = new Game(); Game g = new Game();
g.startGame();
} }
public void startGame() {
public Game() {
this.gb = new Gameboard(); this.gb = new Gameboard();
gb.initGameboard(); gb.initGameboard();
p1 = new Player("Rot"); p1 = new Player("Rot");

1
src/main/java/Gameboard.java

@ -1,4 +1,3 @@
import java.lang.reflect.Array;
import java.util.Arrays; import java.util.Arrays;
public class Gameboard { public class Gameboard {

2
src/main/java/Player.java

@ -1,5 +1,3 @@
import javax.sound.midi.Soundbank;
import java.util.Arrays;
public class Player { public class Player {

6
src/test/java/GameTest.java

@ -1,10 +1,4 @@
import static org.assertj.core.api.Assertions.*;
import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource;
public class GameTest { public class GameTest {

4
src/test/java/PlayerTest.java

@ -1,11 +1,7 @@
import static org.assertj.core.api.Assertions.*; import static org.assertj.core.api.Assertions.*;
import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource;
public class PlayerTest { public class PlayerTest {

Loading…
Cancel
Save