Commit 516ce458 authored by Felix RABADAN's avatar Felix RABADAN
Browse files

ajout score player, files csv

parent fee124d6
FC Nantes Ludovic Blas 1 0 1 29/35 (83%) 9 (7) 7 (5) 2 (2) 89' F 8.7
FC Nantes Andrei Girotto 1 0 1 64/72 (89%) 11 (7) 7 (3) 4 (4) 90' M 7.6
FC Nantes Pedro Chirivella 0 0 1 67/75 (89%) 3 (2) 2 (1) 1 (1) 90' M 7.2
FC Nantes Nicolas Pallois 0 0 1 56/64 (88%) 3 (2) 2 (1) 1 (1) 90' D 7.1
FC Nantes Moses Simon 0 0 0 21/29 (72%) 11 (6) 10 (5) 1 (1) 89' F 6.6
FC Nantes Randal Kolo Muani 0 1 2 8/10 (80%) 22 (7) 14 (5) 8 (2) 90' F 6.6
FC Nantes Roli Pereira De Sa 0 0 1 37/40 (93%) 9 (3) 9 (3) 0 (0) 69' M 6.6
FC Nantes Jean-Charles Castelletto 0 0 0 50/53 (94%) 5 (3) 4 (2) 1 (1) 90' D 6.5
FC Nantes Fábio 0 0 7 28/41 (68%) 15 (8) 15 (8) 0 (0) 90' D 6.4
FC Nantes Alban Lafont 0 0 0 13/27 (48%) 0 (0) 0 (0) 0 (0) 90' G 6.3
FC Nantes Dennis Appiah 0 0 0 3/6 (50%) 3 (0) 3 (0) 0 (0) 21' D 6.3
FC Nantes Sébastien Corchia 0 1 0 6/6 (100%) 4 (1) 4 (1) 0 (0) 39' D 5.7
FC Nantes Kalifa Coulibaly 0 0 0 0/0 0 (0) 0 (0) 0 (0) 1' F -
FC Nantes Samuel Moutoussamy 0 0 0 1/1 (100%) 0 (0) 0 (0) 0 (0) 1' M -
Club / Nom / But / Passe décisive / Tacle / Passe réussie / Total Duel gagné / Duel au sol / Duel aérien / Temps de jeu / Poste / Note du match donné par expert
FC Nantes Ludovic Blas 1 0 1 29/35 (83%) 9 (7) 7 (5) 2 (2) 89' F 8.7
FC Nantes Andrei Girotto 1 0 1 64/72 (89%) 11 (7) 7 (3) 4 (4) 90' M 7.6
FC Nantes Pedro Chirivella 0 0 1 67/75 (89%) 3 (2) 2 (1) 1 (1) 90' M 7.2
FC Nantes Nicolas Pallois 0 0 1 56/64 (88%) 3 (2) 2 (1) 1 (1) 90' D 7.1
FC Nantes Moses Simon 0 0 0 21/29 (72%) 11 (6) 10 (5) 1 (1) 89' F 6.6
FC Nantes Randal Kolo Muani 0 1 2 8/10 (80%) 22 (7) 14 (5) 8 (2) 90' F 6.6
FC Nantes Roli Pereira De Sa 0 0 1 37/40 (93%) 9 (3) 9 (3) 0 (0) 69' M 6.6
FC Nantes Jean-Charles Castelletto 0 0 0 50/53 (94%) 5 (3) 4 (2) 1 (1) 90' D 6.5
FC Nantes Fábio 0 0 7 28/41 (68%) 15 (8) 15 (8) 0 (0) 90' D 6.4
FC Nantes Alban Lafont 0 0 0 13/27 (48%) 0 (0) 0 (0) 0 (0) 90' G 6.3
FC Nantes Dennis Appiah 0 0 0 3/6 (50%) 3 (0) 3 (0) 0 (0) 21' D 6.3
FC Nantes Sébastien Corchia 0 1 0 6/6 (100%) 4 (1) 4 (1) 0 (0) 39' D 5.7
FC Nantes Kalifa Coulibaly 0 0 0 0/0 0 (0) 0 (0) 0 (0) 1' F -
FC Nantes Samuel Moutoussamy 0 0 0 1/1 (100%) 0 (0) 0 (0) 0 (0) 1' M -
FC Nantes / Clermont Foot 63
France Kylian Mbappé 1 1 0 32/38 (84%) 11 (4) 10 (4) 1 (0) 90' F 8.0
France Dayot Upamecano 0 0 1 53/59 (90%) 2 (2) 1 (1) 1 (1) 90' D 7.4
France Kurt Zouma 0 0 1 40/45 (89%) 7 (7) 1 (1) 6 (6) 90' D 7.4
France Aurélien Tchouaméni 0 0 2 38/47 (81%) 8 (6) 6 (4) 2 (2) 90' M 7.3
France Karim Benzema 1 0 0 20/22 (91%) 1 (0) 1 (0) 0 (0) 34' F 7.3
France Hugo Lloris 0 0 0 21/28 (75%) 0 (0) 0 (0) 0 (0) 90' G 7.2
France Lucas Digne 0 1 2 34/42 (81%) 6 (3) 5 (2) 1 (1) 90' M 7.2
France Antoine Griezmann 0 0 2 32/39 (82%) 6 (3) 4 (2) 2 (1) 67' F 7.0
France Léo Dubois 0 0 1 33/39 (85%) 2 (2) 1 (1) 1 (1) 45' M 7.0
France Jules Koundé 0 0 1 53/62 (85%) 2 (2) 1 (1) 1 (1) 57' D 6.9
France Benjamin Pavard 0 0 0 23/25 (92%) 3 (1) 1 (0) 2 (1) 45' D 6.8
France Kingsley Coman 0 0 0 17/22 (77%) 2 (2) 2 (2) 0 (0) 33' F 6.8
France Moussa Diaby 0 0 0 16/17 (94%) 3 (1) 3 (1) 0 (0) 56' F 6.7
France Adrien Rabiot 0 0 1 40/46 (87%) 4 (2) 3 (1) 1 (1) 86' M 6.5
France Mattéo Guendouzi 0 0 0 14/18 (78%) 4 (2) 3 (1) 1 (1) 23' M 6.5
France Jordan Veretout 0 0 0 0/1 (0%) 0 (0) 0 (0) 0 (0) 8' M 6.4
FC Nantes Quentin Merlin 0 0 0 20/21 (95%) 1 (0) 0 (0) 1 (0) 32' F 7.2
FC Nantes Kalifa Coulibaly 0 0 1 5/8 (63%) 13 (8) 4 (2) 9 (6) 58' F 7.0
FC Nantes Pedro Chirivella 0 0 3 70/77 (91%) 10 (6) 9 (5) 1 (1) 90' M 7.0
FC Nantes Andrei Girotto 0 0 4 27/30 (90%) 12 (6) 9 (4) 3 (2) 90' D 6.9
FC Nantes Marcus Coco 0 0 0 14/17 (82%) 9 (4) 8 (4) 1 (0) 77' M 6.9
FC Nantes Alban Lafont 0 0 0 15/20 (75%) 1 (1) 0 (0) 1 (1) 90' G 6.8
FC Nantes Ludovic Blas 0 0 0 39/43 (91%) 6 (2) 6 (2) 0 (0) 90' M 6.8
FC Nantes Samuel Moutoussamy 0 0 0 40/43 (93%) 1 (0) 1 (0) 0 (0) 77' M 6.6
FC Nantes Willem Geubbels 0 0 0 4/5 (80%) 2 (2) 1 (1) 1 (1) 13' F 6.6
FC Nantes Fábio 0 0 2 16/21 (76%) 12 (6) 12 (6) 0 (0) 58' D 6.4
FC Nantes Sébastien Corchia 0 0 1 5/6 (83%) 4 (2) 4 (2) 0 (0) 42' D 6.4
FC Nantes Wylan Cyprien 0 0 2 10/11 (91%) 3 (2) 3 (2) 0 (0) 13' M 6.4
FC Nantes Jean-Charles Castelletto 0 0 2 14/15 (93%) 5 (2) 5 (2) 0 (0) 90' D 6.3
FC Nantes Osman Bukari 0 0 1 13/13 (100%) 7 (2) 7 (2) 0 (0) 32' M 6.1
FC Nantes Randal Kolo Muani 1 0 3 21/26 (81%) 17 (7) 15 (5) 2 (2) 90' M 6.1
FC Nantes Dennis Appiah 0 0 0 20/21 (95%) 3 (0) 3 (0) 0 (0) 48' D 5.8
Finlande / France
Paris Saint-Germain / FC Nantes
FC Nantes Nicolas Pallois 0 0 4 32/45 (71%) 10 (7) 6 (5) 4 (2) 90' D 7.3
FC Nantes Alban Lafont 0 0 0 10/26 (38%) 0 (0) 0 (0) 0 (0) 90' G 7.2
FC Nantes Andrei Girotto 0 0 1 38/50 (76%) 5 (2) 2 (1) 3 (1) 90' D 7.2
FC Nantes Wylan Cyprien 0 0 1 33/40 (83%) 4 (3) 2 (2) 2 (1) 87' M 7.2
FC Nantes Moses Simon 0 0 1 14/22 (64%) 8 (3) 6 (3) 2 (0) 81' F 7.0
FC Nantes Ludovic Blas 1 0 0 19/23 (83%) 18 (5) 16 (5) 2 (0) 90' F 6.7
FC Nantes Dennis Appiah 0 0 0 1/1 (100%) 1 (1) 0 (0) 1 (1) 9' D 6.6
FC Nantes Quentin Merlin 0 0 1 24/31 (77%) 5 (3) 2 (1) 3 (2) 90' D 6.6
FC Nantes Samuel Moutoussamy 0 0 3 24/31 (77%) 8 (3) 7 (3) 1 (0) 90' M 6.6
FC Nantes Fábio 0 0 9 18/30 (60%) 17 (11) 15 (10) 2 (1) 78' D 6.4
FC Nantes Marcus Coco 0 0 0 0/0 5 (1) 4 (1) 1 (0) 8' F 6.4
FC Nantes Pedro Chirivella 0 0 0 28/37 (76%) 6 (0) 6 (0) 0 (0) 90' M 6.3
FC Nantes Randal Kolo Muani 0 0 1 7/9 (78%) 29 (10) 15 (5) 14 (5) 90' F 6.2
FC Nantes Andrei Girotto 0 0 6 40/47 (85%) 8 (8) 6 (6) 2 (2) 90' M 7.5
FC Nantes Alban Lafont 0 0 0 16/26 (62%) 0 (0) 0 (0) 0 (0) 90' G 7.1
FC Nantes Dennis Appiah 0 0 2 12/16 (75%) 6 (3) 6 (3) 0 (0) 90' D 6.8
FC Nantes Moses Simon 0 0 2 13/14 (93%) 9 (6) 7 (5) 2 (1) 77' M 6.8
FC Nantes Samuel Moutoussamy 0 0 3 33/36 (92%) 11 (4) 8 (3) 3 (1) 90' M 6.8
FC Nantes Ludovic Blas 0 0 1 28/34 (82%) 10 (4) 9 (4) 1 (0) 90' F 6.7
FC Nantes Quentin Merlin 0 0 1 29/34 (85%) 3 (2) 3 (2) 0 (0) 90' D 6.7
FC Nantes Randal Kolo Muani 0 0 0 7/12 (58%) 12 (5) 10 (4) 2 (1) 90' F 6.6
FC Nantes Wylan Cyprien 0 0 0 40/45 (89%) 6 (2) 5 (2) 1 (0) 90' M 6.6
FC Nantes Willem Geubbels 0 0 0 1/3 (33%) 1 (0) 0 (0) 1 (0) 13' F 6.5
FC Nantes Jean-Charles Castelletto 0 0 0 27/29 (93%) 3 (0) 3 (0) 0 (0) 90' D 6.4
FC Nantes Nicolas Pallois 0 0 2 14/17 (82%) 4 (2) 4 (2) 0 (0) 32' D 5.5
FC Nantes / Olympique de Marseille
Saint-Étienne / FC Nantes
......@@ -4,7 +4,6 @@ import game.controllers.*;
import java.io.FileNotFoundException;
import game.Parser;
import game.Player.Position;
public class Game {
......@@ -20,7 +19,7 @@ public class Game {
CardController cardController = CardController.getInstance();
Player p = new Player("Paul Pogba", Position.COURT_FIELD_PLAYER);
Player p = new Player("Paul Pogba", Position.COURT_FIELD_PLAYER, (float)5.0);
Card card1 = cardController.createCard(1, Card.Rarity.COMMON, p);
cardController.createCard(1, Card.Rarity.COMMON, p);
cardController.removeCard(card1);
......@@ -40,9 +39,8 @@ public class Game {
p.displayCards();
//test parser
Parser fnnantesPlayers = new Parser();
try {
fnnantesPlayers.parseTeam("CSV\\2021_46_Nantes.csv");
Parser.parseTeam("CSV\\2021_46_Nantes.csv");
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
......
......@@ -8,7 +8,7 @@ import game.controllers.ClubController;
import game.controllers.PlayerController;
public class Parser {
public void parseTeam(String pathname) throws FileNotFoundException {
public static void parseTeam(String pathname) throws FileNotFoundException {
Scanner fileScanner = new Scanner(new File(pathname));
ClubController clubController = ClubController.getInstance();
PlayerController playerController = PlayerController.getInstance();
......@@ -21,13 +21,15 @@ public class Parser {
String name = lineScanner.next();
String position = lineScanner.findInLine("[A-Z]");//on cherche la prochaine lettre, correspond a la position
float score = Float.parseFloat(lineScanner.next());
Player.Position playposition;
if(position.equals("G")){
playposition= Player.Position.GOAL_KEEPER;
}else{
playposition= Player.Position.COURT_FIELD_PLAYER;
}
Player player = playerController.addPlayer(name,playposition);
Player player = playerController.addPlayer(name,playposition,score);
club.addPlayer(player);
// while (lineScanner.hasNext()) {
......
......@@ -12,14 +12,16 @@ public class Player {
private String name;
private Position position;
private float score;
private HashMap<String, Card> cards;
private int nbCommonCards;
private int nbLessCommonCards;
private int nbRareCards;
public Player(String name, Position position) {
public Player(String name, Position position, float score) {
this.name = name;
this.position = position;
this.score = score;
cards = new HashMap<String, Card>();
}
......
......@@ -19,9 +19,9 @@ public final class PlayerController {
return instance;
}
public Player addPlayer(String name, Player.Position position) {
public Player addPlayer(String name, Player.Position position, float score) {
if (!players.containsKey(name)) {
Player newPlayer = new Player(name,position);
Player newPlayer = new Player(name,position,score);
players.put(name, newPlayer);
return newPlayer;
} else {
......
Supports Markdown
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