Hi all,
I've been stuck on this problem for a couple days and not really sure if there's a way to do it but... I'm trying to dynamically name arrays for a game. So if someone types in the console 2 people are playing I want two arrays to be made - one that is named P1 and the second P2. Is this possible and if so, how so? I've tried a couple of ways but I get an error saying that the variable cannot be reused for array types.
for (int i = 0; i < playerNames.Length; i++)
{
String name = "p" + i;
string[] name = new string[];
}
playerNames is just an array of playerNames(i.e. P1,P2,P3,P4,etc.)
Thanks