Fix objective name error when no more objective name are availables.

This commit is contained in:
Khopa 2020-05-29 23:43:26 +02:00
parent 59986d74f4
commit 34d46ee28e

View File

@ -68,7 +68,7 @@ class NameGenerator:
def random_objective_name(self):
if len(self.ANIMALS) == 0:
random.choice(ALPHA_MILITARY).upper() + " #" + str(random.randint(0, 100))
return random.choice(ALPHA_MILITARY).upper() + "#" + str(random.randint(0, 100))
else:
animal = random.choice(self.ANIMALS)
self.ANIMALS.remove(animal)