/// <summary> /// Constructor waarin het Parrent Form meegegeven word /// </summary> public Game(startGame ParentForm) { InitializeComponent(); this.StartGame = ParentForm; if (StartGame.x6SettingDeck()) { MatrixSize = 6; } else { MatrixSize = 4; } naamP1 = Interaction.InputBox("Vul je naam in", "Vul je naam in", "Speler 1", -1, -1); naamP2 = Interaction.InputBox("Vul je naam in", "Vul je naam in", "Speler 2", -1, -1); lblScoreP1.Text = naamP1 + ": " + scoreP1; lblScoreP2.Text = naamP2 + ": " + scoreP2; lblTurn.Text = naamP1 + " is aan de beurt"; lblShowImages.Text = "5"; setPictureBoxes(); setRandomImages(); timerShowImages.Start(); clickTimer.Interval = 1000; clickTimer.Tick += clickTimer_Tick; }
/// <summary> /// constructor voor het maaken van het speelveld /// </summary> public singleGame(startGame ParentForm) { InitializeComponent(); this.StartGame = ParentForm; naam = Interaction.InputBox("Vul je naam in", "Vul je naam in", "speler 1", -1, -1); setPictureBoxes(); setRandomImages(); lblShowImages.Text = "5"; timerShowImages.Start(); clickTimer.Interval = 1000; clickTimer.Tick += clickTimer_Tick; //sp.PlayLooping(); sp.Play(); }