was unnötiges entfernt
parent
c1bed58d46
commit
eb3829c966
BIN
bin/Player.class
BIN
bin/Player.class
Binary file not shown.
|
@ -216,19 +216,15 @@ public class Player extends Picture implements KeyListener { // extends Picture
|
|||
if (coordinate == 'x') { // Auslesen der 'x' - Koordinate:
|
||||
if (left && dt != 0) {
|
||||
xPos -= speed * dt;
|
||||
System.out.println(speed * dt);
|
||||
} else if (right && dt != 0) {
|
||||
xPos += speed * dt;
|
||||
System.out.println(speed * dt);
|
||||
}
|
||||
return (int) xPos;
|
||||
} else if (coordinate == 'y') { // Auslesen der 'y' - Koordinate:
|
||||
if (down && dt != 0) {
|
||||
yPos += speed * dt;
|
||||
System.out.println(speed * dt);
|
||||
} else if (up && dt != 0) {
|
||||
yPos -= speed * dt;
|
||||
System.out.println(speed * dt);
|
||||
}
|
||||
return (int) yPos;
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue