void SnowTimerTick(object sender, EventArgs e) { _currentSnowFlakes++; if (_currentSnowFlakes >= MaxSnowFlakes) { _snowTimer.Stop(); } // Randomise which image gets used. var randomSnowFlake = RandomNumber.Next(_snowChoices.Count()); var snowFlake = new SnowFlake(_snowChoices[randomSnowFlake]); // Set height and width of phone snowFlake.SetInitialProperties(400, 800); SnowField.Children.Add(snowFlake); }
void SnowTimerTick(object sender, EventArgs e) { _currentSnowFlakes++; if(_currentSnowFlakes >= MaxSnowFlakes) _snowTimer.Stop(); // Randomise which image gets used. var randomSnowFlake = RandomNumber.Next(_snowChoices.Count()); var snowFlake = new SnowFlake(_snowChoices[randomSnowFlake]); // Set height and width of phone snowFlake.SetInitialProperties(400, 800); SnowField.Children.Add(snowFlake); }