Skip to content

Commit ab709a1

Browse files
name generation bounds fix
1 parent f68ec8b commit ab709a1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Assets/Scripts/Gameplay/Configuration/NameGenerationData.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
using System;
21
using UnityEngine;
32
using Random = UnityEngine.Random;
43

@@ -19,8 +18,8 @@ public class NameGenerationData : ScriptableObject
1918

2019
public string GenerateName()
2120
{
22-
var firstWord = FirstWordList[Random.Range(0, FirstWordList.Length - 1)];
23-
var secondWord = SecondWordList[Random.Range(0, SecondWordList.Length - 1)];
21+
var firstWord = FirstWordList[Random.Range(0, FirstWordList.Length)];
22+
var secondWord = SecondWordList[Random.Range(0, SecondWordList.Length)];
2423

2524
return firstWord + " " + secondWord;
2625
}

0 commit comments

Comments
 (0)