Commit e146c3d7 authored by Mehmet Duhan Tercüman's avatar Mehmet Duhan Tercüman
Browse files

Bugfix

parent a021eb6f
......@@ -49,13 +49,13 @@ Wenn man das Spiel zurücksetzen möchte, kann man die Taste `R` drücken und da
File blank comment code
-----------------------------------------------------------------------------------------------
app\src\main\java\pis_hu1\gameengine.java 22 9 144
app\src\main\java\pis_hu1\draw.java 12 0 132
app\src\main\java\pis_hu1\draw.java 12 0 136
app\src\main\java\pis_hu1\gameinterface.java 1 0 8
-----------------------------------------------------------------------------------------------
SUM: 35 9 284
SUM: 35 9 288
-----------------------------------------------------------------------------------------------
AL : 53,52%
AL : 52,77%
```
<br>
......
......@@ -27,9 +27,13 @@ dependencies {
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(16))
}
}
application {
// Define the main class for the application.
mainClass = 'PIS_HU1.App'
mainClass = 'PIS_HU1.Draw'
}
......@@ -8,6 +8,10 @@ public class Draw extends PApplet {
GameEngine game = new GameEngine();
boolean bot = false;
boolean drawGame = false;
PImage icon;
PImage winner;
PImage botPic;
PImage start;
public static void main(String[] args) {
PApplet.runSketch(new String[] {""}, new Draw());
......@@ -18,7 +22,10 @@ public class Draw extends PApplet {
}
public void setup() {
PImage icon = loadImage("app/src/main/resources/connect-four.png");
icon = loadImage("connect-four.png");
winner = loadImage("winner.png");
botPic = loadImage("robot.png");
start = loadImage("TitleScreen.png");
game.reset();
mainMenu();
surface.setTitle("Connect Four !");
......@@ -63,7 +70,6 @@ public class Draw extends PApplet {
}
y += 100;
}
PImage winner = loadImage("app/src/main/resources/winner.png");
winner.resize(350, 350);
if (game.isWin(game.getPlayerBoard()[0])) {
background(50, 96, 114);
......@@ -78,7 +84,6 @@ public class Draw extends PApplet {
textSize(60);
fill(255);
if (bot) {
PImage botPic = loadImage("app/src/main/resources/robot.png");
text("Bot WON", 100, 100);
botPic.resize(350, 350);
image(botPic, 150, 250);
......@@ -92,7 +97,6 @@ public class Draw extends PApplet {
}
public void mainMenu() {
PImage start = loadImage("app/src/main/resources/TitleScreen.png");
background(50, 96, 114);
textSize(60);
fill(255);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment