Hey guys i want to generate in a grid[4,4] with equal couples of random images(like in double match game), and i don't
know why after i run the code those "random" images are displayed like
[sameImage0][sameImage0][sameImage1][sameImage1]. I want that the same
images are away from each other. I am gonna copy the part of function that
generates those random images and please tell me what's going on?
int cnt = 0;
while (cnt != 16)
{
Random RandomNumber = new Random();
int current = RandomNumber.Next(0, listImages.Count);
if (numbers[current] < 2)
{
numbers[current]++;
randomImages.Add(listImages[current]);
cnt++;
}
}
Thanks a lot in advance!