Exemplo n.º 1
0
 public Goal(int id, int minutes, Match match, int idPlayer)
 {
     Id = id;
     Minutes = minutes;
     Match = match;
     Player = createPlayer(idPlayer);
 }
Exemplo n.º 2
0
 public Goal(int id, int minutes, Match match, Player player)
 {
     Id = id;
     Minutes = minutes;
     Match = match;
     Player = player;
 }
Exemplo n.º 3
0
        private const int WEIGHT_SAVE = 300;//bidejki toa odreduva koj igrac kolkavi sansi ima sto da postigne
                                            //vaka e po fer, bidejki na pr. gol e gol nezavisno dali igracot na
                                            //koja pozicija igra


        public Participates(int id, Player player, Match match, int ng, int na, int ni, int ns)
        {
            IdParticipate = id;
            Player = player;
            Match = match;
            NumGoals = ng;
            NumAssists = na;
            NumInterrupts = ni;
            NumSaves = ns;

            
        }
Exemplo n.º 4
0
 public FormPlayer(Player player)
 {
     InitializeComponent();
     
     Player = player;
     changeChartView();
     lblFirstName.Text = player.FirstName;
     lblLastName.Text = player.LastName;
     lblPosition.Text = player.Position.Description;
     lblRating.Text = player.Rating.ToString();
     lblTeam.Text = Player.Team.Name;
 }
Exemplo n.º 5
0
 private Player createPlayer(int idPlayer)
 {
     using (OracleConnection connection = new OracleConnection(FormLogin.connString))
     {
         connection.Open();
         String query = "SELECT * FROM player WHERE idPlayer =" + idPlayer;
         OracleCommand command = new OracleCommand(query, connection);
         OracleDataReader reader = command.ExecuteReader();
         reader.Read();
         Player p = new Player(FormLogin.docMain, idPlayer, reader.GetString(1), reader.GetString(2), reader.GetDateTime(3), reader.GetInt32(4), reader.GetInt32(5), reader.GetInt32(6));
         return p;
     }
 }
Exemplo n.º 6
0
        //IDPLAYER	NAME	SURNAME	DATEOFBIRTH	RATING	IDTEAM	IDPOSITION
        public void addPlayer(int id, String firstName, String lastName, DateTime dateOfBirth, double rating, int idTeam, int idPosition)
        {

            Player newPlayer = new Player(id, firstName, lastName, dateOfBirth, rating, this.getTeamById(idTeam), this.getPositionById(idPosition));
            Players.Add(newPlayer);

        }
Exemplo n.º 7
0
 public void addPlayer(Player player)
 {
     Players.Add(player);
 }