Got RNG working

Got my RNG working for all 3 lvls!

Capture1|690x226

void StartGame()
{
currentScreen = Screen.Password;
Terminal.ClearScreen();
switch(level)
{
case 1:
int index1 = Random.Range(0, level1Passwords.Length);
password = level1Passwords[index1];
break;
case 2:
int index2 = Random.Range(0, level2Passwords.Length);
password = level2Passwords[index2];
break;
case 3:
int index3 = Random.Range(0, level3Passwords.Length);
password = level3Passwords[index3];
break;
default:
Debug.LogError(“INVALID INPUT…”);
break;
}

Privacy & Terms