I have an 80 PNG image sequence in which I am trying to create an animation for my windows app. The file path is Assets/Star/ and I am trying to figure out how I would make a fo
Just await Task.Delay
to asynchronously wait for a set span of time:
private async void SubmitButton_Click(object sender, RoutedEventArgs e)
{
if (LevelUp)
{
string imagePath = "Assets/Star/";
foreach (Image image in GetImages(imagePath))
{
ShowImage(image);
await Task.Delay(timeToWait);
}
}
}