mirror of
https://athene2.informatik.unibw-muenchen.de/progproj/gruppen-ht24/Gruppe-02.git
synced 2025-08-03 11:07:19 +02:00
Lade Figuren auf Spielbrett
This commit is contained in:
@@ -79,6 +79,10 @@ public class Player implements FieldVisitor<Void>{
|
||||
public void setFigure(Figure figure) {
|
||||
this.figure = figure;
|
||||
}
|
||||
|
||||
public Figure getFigure(){
|
||||
return figure;
|
||||
}
|
||||
|
||||
public PlayerColor getColor() {
|
||||
switch ((id%6)+1) {
|
||||
@@ -540,4 +544,8 @@ public class Player implements FieldVisitor<Void>{
|
||||
}
|
||||
|
||||
}
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Player{name=" + name + ", figure=" + figure + "}";
|
||||
}
|
||||
}
|
||||
|
@@ -1,14 +1,13 @@
|
||||
package pp.monopoly.model;
|
||||
|
||||
import static java.lang.Math.max;
|
||||
import static java.lang.Math.min;
|
||||
import java.util.Collections;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import com.jme3.network.serializing.Serializable;
|
||||
|
||||
import static java.lang.Math.max;
|
||||
import static java.lang.Math.min;
|
||||
|
||||
@Serializable
|
||||
public class Figure implements Item{
|
||||
private final String type;
|
||||
@@ -313,5 +312,9 @@ public class Figure implements Item{
|
||||
public void accept(VoidVisitor visitor) {
|
||||
visitor.visit(this);
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user